Revert "fix(ui): enforce must-watch seek lock after the seek settles"
This reverts commit 9de0615e0f.
This commit is contained in:
@@ -116,12 +116,6 @@
|
|||||||
|
|
||||||
const onSeeked = () => {
|
const onSeeked = () => {
|
||||||
isSeeking = false;
|
isSeeking = false;
|
||||||
// Re-enforce once the seek settles: setting currentTime during `seeking`
|
|
||||||
// doesn't always stick (HLS re-buffering can win the in-flight seek), so
|
|
||||||
// snap back here if the player still ended up ahead.
|
|
||||||
if (player.currentTime > furthestSeconds + seekTolerance) {
|
|
||||||
player.currentTime = furthestSeconds;
|
|
||||||
}
|
|
||||||
hasBlockedThisSeek = false;
|
hasBlockedThisSeek = false;
|
||||||
lastValidTime = player.currentTime;
|
lastValidTime = player.currentTime;
|
||||||
};
|
};
|
||||||
@@ -132,14 +126,6 @@
|
|||||||
const current = player.currentTime;
|
const current = player.currentTime;
|
||||||
const delta = current - lastValidTime;
|
const delta = current - lastValidTime;
|
||||||
|
|
||||||
// Backstop: a forward jump beyond normal playback that slipped past the
|
|
||||||
// `seeking`/`seeked` handlers. Clamp back so playback can't continue ahead.
|
|
||||||
if (delta >= 2 && current > furthestSeconds + seekTolerance) {
|
|
||||||
player.currentTime = furthestSeconds;
|
|
||||||
lastValidTime = furthestSeconds;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (delta > 0 && delta < 2) {
|
if (delta > 0 && delta < 2) {
|
||||||
playedSeconds += delta;
|
playedSeconds += delta;
|
||||||
furthestSeconds = Math.max(furthestSeconds, current);
|
furthestSeconds = Math.max(furthestSeconds, current);
|
||||||
|
|||||||
Reference in New Issue
Block a user