fix: suppress transient pause during seek in bridge mode

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
HoneyandClaude Sonnet 4.6 committed 2026-05-13 10:46:12 +02:00
1 parent 74a452c037
commit d87abd2e9e
1 file changed
+2
+2
View File
@@ -593,6 +593,7 @@ export function seekTo(e) {
if (fill) { fill.style.transition = 'none'; fill.style.width = (pos * 100) + '%'; } if (fill) { fill.style.transition = 'none'; fill.style.width = (pos * 100) + '%'; }
S._scrubbing = true; S._scrubbing = true;
if (HAS_BRIDGE) { if (HAS_BRIDGE) {
_setSkipping();
_nsBridge('seekTo', Math.round(pos * _lastDurationMs)); _nsBridge('seekTo', Math.round(pos * _lastDurationMs));
const done = () => { S._scrubbing = false; requestAnimationFrame(() => { if (fill) fill.style.transition = ''; }); }; const done = () => { S._scrubbing = false; requestAnimationFrame(() => { if (fill) fill.style.transition = ''; }); };
setTimeout(done, 500); setTimeout(done, 500);
@@ -626,6 +627,7 @@ function _initBarScrub(bar, fill, onMove) {
fill.style.width = (pos * 100) + '%'; fill.style.width = (pos * 100) + '%';
const dur = _dur(); const dur = _dur();
if (HAS_BRIDGE) { if (HAS_BRIDGE) {
_setSkipping();
_nsBridge('seekTo', Math.round(pos * _lastDurationMs)); _nsBridge('seekTo', Math.round(pos * _lastDurationMs));
S._scrubbing = false; S._scrubbing = false;
requestAnimationFrame(() => { fill.style.transition = ''; }); requestAnimationFrame(() => { fill.style.transition = ''; });