File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -67,6 +67,7 @@ interface SBConfig {
6767 showCategoryGuidelines : boolean ;
6868 showCategoryWithoutPermission : boolean ;
6969 showSegmentNameInChapterBar : boolean ;
70+ useVirtualTime : boolean ;
7071
7172 // Used to cache calculated text color info
7273 categoryPillColors : {
@@ -200,6 +201,7 @@ const Config: SBObject = {
200201 showCategoryGuidelines : true ,
201202 showCategoryWithoutPermission : false ,
202203 showSegmentNameInChapterBar : true ,
204+ useVirtualTime : true ,
203205
204206 categoryPillColors : { } ,
205207
Original file line number Diff line number Diff line change @@ -711,7 +711,8 @@ function getVirtualTime(): number {
711711 const virtualTime = lastTimeFromWaitingEvent ?? ( lastKnownVideoTime . videoTime ?
712712 ( performance . now ( ) - lastKnownVideoTime . preciseTime ) * video . playbackRate / 1000 + lastKnownVideoTime . videoTime : null ) ;
713713
714- if ( ! isSafari ( ) && virtualTime && Math . abs ( virtualTime - video . currentTime ) < 0.6 && video . currentTime !== 0 ) {
714+ if ( Config . config . useVirtualTime && ! isSafari ( ) && virtualTime
715+ && Math . abs ( virtualTime - video . currentTime ) < 0.6 && video . currentTime !== 0 ) {
715716 return virtualTime ;
716717 } else {
717718 return video . currentTime ;
You can’t perform that action at this time.
0 commit comments