From 913e455446ad3d4fcbe42cbc126b499619351078 Mon Sep 17 00:00:00 2001 From: David Steinacher Date: Tue, 10 Dec 2024 13:31:11 -0700 Subject: [PATCH] revert seekbar changes to current develop state --- src/ts/components/seekbar.ts | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/ts/components/seekbar.ts b/src/ts/components/seekbar.ts index 80a96b0d3..6fcfab9de 100644 --- a/src/ts/components/seekbar.ts +++ b/src/ts/components/seekbar.ts @@ -242,10 +242,17 @@ export class SeekBar extends Component { uimanager.onControlsShow.subscribe(() => { this.isUiShown = true; + if (!player.isLive() && !this.smoothPlaybackPositionUpdater.isActive()) { + playbackPositionHandler(null, true); + this.smoothPlaybackPositionUpdater.start(); + } }); uimanager.onControlsHide.subscribe(() => { this.isUiShown = false; + if (this.smoothPlaybackPositionUpdater.isActive()) { + this.smoothPlaybackPositionUpdater.clear(); + } }); let isPlaying = false; @@ -323,12 +330,12 @@ export class SeekBar extends Component { scrubbing = false; }; - let onPlayerSeeked = (event: PlayerEventBase = null, forceUpdate: boolean = false ) => { + let onPlayerSeeked = (event: PlayerEventBase = null) => { isPlayerSeeking = false; this.setSeeking(false); // update playback position when a seek has finished - playbackPositionHandler(event, forceUpdate); + playbackPositionHandler(event, true); }; let restorePlayingState = function () {