Skip to content

Keep mask playback state accurate after play rejection - #35

Open
rudycelekli wants to merge 4 commits into
D3voz:mainfrom
rudycelekli:fix/editor-mask-playback
Open

rudycelekli wants to merge 4 commits into
D3voz:mainfrom
rudycelekli:fix/editor-mask-playback

Conversation

@rudycelekli

Copy link
Copy Markdown

The mask review switches its button to Pause immediately after calling video.play(). If playback is rejected, the rejected promise goes unhandled and the UI claims the video is playing.

Track playback through native play/pause events, handle play rejection with a retryable error, and discard errors from superseded attempts or an expired review. Frame stepping still pauses playback.

Validation: mounted React regression fails before the fix because rejected playback leaves Pause visible. Afterward it verifies the error, successful retry, pause, pending-play state, and an obsolete rejection arriving after a newer successful attempt. npm test passes 127 tests and TypeScript. The media API is controlled in jsdom; native codec/GPU behavior was not qualified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant