fix(video): release scrub chrome hold

close #1340
This commit is contained in:
edde746
2026-06-14 18:34:12 +02:00
parent b23ba4c839
commit 5e2bd4efa8
8 changed files with 122 additions and 5 deletions
@@ -89,9 +89,6 @@ extension _PlexVideoControlsPlaybackInputMethods on _PlexVideoControlsState {
/// Throttled seek for timeline slider - executes immediately then throttles to 200ms
void _throttledSeek(Duration position) {
// Hold before the transcoding early-return so a slow scrub never loses
// the controls to auto-hide mid-drag (idempotent while held).
widget.chromeController.hold(PlayerChromeHold.scrub);
if (widget.isTranscoding) return;
_seekThrottle([position]);
}
@@ -100,6 +97,13 @@ extension _PlexVideoControlsPlaybackInputMethods on _PlexVideoControlsState {
void _finalizeSeek(Duration position) {
_seekThrottle.cancel();
unawaited(_seekToPosition(position));
}
void _holdTimelineScrub() {
widget.chromeController.hold(PlayerChromeHold.scrub);
}
void _releaseTimelineScrub() {
widget.chromeController.release(PlayerChromeHold.scrub);
}