Procházet zdrojové kódy

fix cursor not advancing after pausing then playing (#22)

fixes #22

fix by conde2, similar to line 786 (in handlePlaybackEvent)
sschmid před 4 roky
rodič
revize
ba5f9725d4
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      src/Playback/PlaybackManager.ts

+ 1 - 1
src/Playback/PlaybackManager.ts

@@ -333,7 +333,7 @@ export class PlaybackManager implements IPlaybackParametersListener {
     }
 
     public async play(): Promise<void> {
-        if (this.cursorIterator !== undefined && this.cursorIterator.EndReached) {
+        if (this.cursorIterator !== undefined && this.cursorIterator.EndReached && this.currentTimestamp.gte(this.cursorIterator.CurrentEnrolledTimestamp)) {
             console.log("End reached, resetting");
             this.reset();
         }