mirror of
https://github.com/zoriya/v10.git
synced 2026-08-16 02:45:09 +00:00
Extend seek-to-live-edge with a live-window playhead guard: while playing (!paused && !seeking && readyState>0), reposition currentTime to the live edge (holdback) when it falls outside the sliding window [windowStart, windowEnd] (0.1s tolerance). Covers a paused-too-long playhead the window slid past (caught on the playing resume) and playback that fell behind on poor network (caught on the effect's window-update re-fire, since timeupdate stops once a stall freezes currentTime). In-window pause and DVR scrub-back are untouched. The one-time initial seek is preserved (latched) and the guard reuses the same liveEdgeStart, keeping the live playhead position single-owned. repositionPolicy is a behavior-scoped seam (default 'window-exit'); the edge-only 'on-resume' branch is inert, reserved for a future live-edge-only-mode use-case. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>