mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-08 12:37:05 +03:00
Add option to disable scrolling to edit
This commit is contained in:
@@ -1249,5 +1249,8 @@
|
|||||||
},
|
},
|
||||||
"segmentFetchFailureWarning": {
|
"segmentFetchFailureWarning": {
|
||||||
"message": "Warning: The server hasn't responded with segments yet. There might actually be segments on this video already submitted but you just haven't recieved them due to issues with the server."
|
"message": "Warning: The server hasn't responded with segments yet. There might actually be segments on this video already submitted but you just haven't recieved them due to issues with the server."
|
||||||
|
},
|
||||||
|
"allowScrollingToEdit": {
|
||||||
|
"message": "Allow Scrolling To Edit Times"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -278,6 +278,18 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div data-type="toggle" data-sync="allowScrollingToEdit">
|
||||||
|
<div class="switch-container">
|
||||||
|
<label class="switch">
|
||||||
|
<input id="allowScrollingToEdit" type="checkbox" checked>
|
||||||
|
<span class="slider round"></span>
|
||||||
|
</label>
|
||||||
|
<label class="switch-label" for="allowScrollingToEdit">
|
||||||
|
__MSG_allowScrollingToEdit__
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div data-type="toggle" data-sync="audioNotificationOnSkip">
|
<div data-type="toggle" data-sync="audioNotificationOnSkip">
|
||||||
<div class="switch-container">
|
<div class="switch-container">
|
||||||
<label class="switch">
|
<label class="switch">
|
||||||
|
|||||||
@@ -320,6 +320,7 @@ class SponsorTimeEditComponent extends React.Component<SponsorTimeEditProps, Spo
|
|||||||
}
|
}
|
||||||
|
|
||||||
changeTimesWhenScrolling(index: number, e: React.WheelEvent, sponsorTime: SponsorTime): void {
|
changeTimesWhenScrolling(index: number, e: React.WheelEvent, sponsorTime: SponsorTime): void {
|
||||||
|
if (!Config.config.allowScrollingToEdit) return;
|
||||||
let step = 0;
|
let step = 0;
|
||||||
// shift + ctrl = 1
|
// shift + ctrl = 1
|
||||||
// ctrl = 0.1
|
// ctrl = 0.1
|
||||||
|
|||||||
@@ -69,6 +69,7 @@ interface SBConfig {
|
|||||||
showSegmentNameInChapterBar: boolean;
|
showSegmentNameInChapterBar: boolean;
|
||||||
useVirtualTime: boolean;
|
useVirtualTime: boolean;
|
||||||
showSegmentFailedToFetchWarning: boolean;
|
showSegmentFailedToFetchWarning: boolean;
|
||||||
|
allowScrollingToEdit: boolean;
|
||||||
|
|
||||||
// Used to cache calculated text color info
|
// Used to cache calculated text color info
|
||||||
categoryPillColors: {
|
categoryPillColors: {
|
||||||
@@ -204,6 +205,7 @@ const Config: SBObject = {
|
|||||||
showSegmentNameInChapterBar: true,
|
showSegmentNameInChapterBar: true,
|
||||||
useVirtualTime: true,
|
useVirtualTime: true,
|
||||||
showSegmentFailedToFetchWarning: true,
|
showSegmentFailedToFetchWarning: true,
|
||||||
|
allowScrollingToEdit: true,
|
||||||
|
|
||||||
categoryPillColors: {},
|
categoryPillColors: {},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user