Skip to content

Player: a key scrub waits for OK — click to confirm where to jump - #809

Merged
GLinnik21 merged 33 commits into
mainfrom
scrub-click-to-confirm
Oct 16, 2026
Merged

GLinnik21 merged 33 commits into
mainfrom
scrub-click-to-confirm

Conversation

@GLinnik21

@GLinnik21 GLinnik21 commented Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator

Follow-up to #767. Trying it on the TV showed that letting go of a held key jumps straight to the new spot. The scrub now asks you to confirm the spot first.

Behaviour

  • Remote keys (LEFT/RIGHT taps and holds, FF/REW): only move the scrub target, which is the knob plus the preview card. Releasing a key, the 450 ms tap debounce and the lost-keyup fallback never seek. The video keeps playing underneath. Playing and paused behave the same.
  • OK / PLAY / PLAYPAUSE: commit the pending target, seek there and play, resuming if playback was paused.
  • BACK: cancels the target, and the knob springs back. Opening the panel, the Skip pill, an offer or a route change also cancels it; none of them commit it.
  • HUD: stays up while a target is pending.
  • Magic Remote drag: releasing still commits, so a playing video stays playing and a paused one stays paused.
  • No undo: after a commit BACK has its ordinary meaning. player: a still from the server's preview thumbnails floats above the knob while scrubbing #767's 5 s jump-back window (ghost tick plus the "BACK · m:ss" chip) is removed, because the owner found it unnecessary once the commit is explicit.
  • Card while moving: while the target moves (hold, key steps, drag), the card keeps the last still that arrived, whatever its distance from the target. The 10 s tolerance and the 400 ms hide apply only once the target settles. On the TV, a fast hold used to drop the card even though stills kept arriving: the hold outruns sequential fetches by about 38 s per still.

What changed

  • Removed: the tap auto-commit machinery (Scrub::commit_at, step_tap_commit, finish_hold, settle_release, take_paused_target). take_target now handles the confirm in both states.
  • Player screen shape: it lost commit_at, so SCREEN_SHAPES_PIN is bumped and the three replay fixtures are re-recorded. make check-replay passes: 3 fixtures, 6 replays, every verdict SAME.
  • Docs: docs/ux-scenario.md §6.4 and §6.6 now describe click-to-confirm.

Verification

The tests were written first and failed before each fix: the card dropping out during a hold, and BACK after a commit seeking back. Host results after the follow-up: screens 1376/0, appkit 313/0, hostsim 790/0, replay SAME, ARM build linked.

Earlier results:

The tests were written first and failed against the release-commits behaviour. Results on the merged tree:

  • make test-crate C=plx_screens: test result: ok. 1385 passed; 0 failed
  • hostsim lib, unfiltered: test result: ok. 790 passed; 0 failed
  • --no-default-features check: clean
  • Module layers: green
  • ARM build: built on the branch before main was merged in

🤖 Generated with Claude Code

dimitrije83 and others added 30 commits October 15, 2026 19:23
…nob-clock growth

Chrome (title, control row, tabs) fades 150 ms out / 150 ms wait / 250 ms in and is not
hit-registered while hidden; card is 216 tall, width from the still's aspect (cap 518), fitted;
radius 12, 1.5 px rim, 0/12/32 shadow; entrance, reshow, exit and swap motion; 10 s tolerance with
a 400 ms hide; knob clock grows 1.25x when no card shows.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
… back to the playhead

Pure parts in appkit::scrub_undo (window deadline and fade, tick rect, chip text and placement,
knob spring) and their wiring in the transport row and HUD draw. Nothing opens the window or
starts the spring from a gesture yet.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…rub waits for OK/PLAY

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…ks the chrome

LEFT/RIGHT on a hidden transport arms the gesture on the playhead but moves
nothing; publishing that seed as TX.scrub_ns faded the title, control row and
tabs out and back. publish() now holds -1 while the gesture is still a reveal.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…nothing else has moved the film

The undo window now closes where the HUD is dismissed (the Timing capsule's
close), when a panel takes the page (Chapters / From Beginning seek from
there), and when the control row's Skip pill is activated; BACK arms the undo
only if the transport was visible at the press.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…a test's doc comment

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…animating its size

A font size is never tweened (gfx/tokens.rs): the 25..30 px steps opened a
bold face per size, and 30 is not a rung. Motion::clock_grow is now a 0..1
progress; clock_faces crossfades the resting CAPTION clock with BODY (28, the
rung nearest 1.25x; its bold face is already open for the control row),
baseline-anchored, on the same 150/200 ms ramps. ClockWarm prewarms the
elapsed clock at BODY too.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
- player_hud: one `bar_x(pos, dur)` helper replaces the `knob_x` closure in
  draw_scrub_preview and the open-coded clamp in draw_undo.
- player_hud: draw_hud gates the title block and the control row on one
  `if chrome { .. }` instead of an empty branch plus a second gate.
- scrub_preview::draw: match `Some((old, t))` once, name `boxed` once.
- scrub_undo::Chip: drop the duplicate `text` String; measure the CString.
- screens/player: transport_reset and step_tap_commit use `Scrub::cancel`.
- media/route: `cur_part_id` is pub, replacing the `part_id` wrapper.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
A key scrub never commits by itself: release, the 450 ms tap debounce and the
lost-keyup net leave the target pending; OK / PLAY / PLAYPAUSE take it; BACK or
anything else taking the page cancels it. Tests encode that for a playing and a
paused film; a drag's release still commits. PlayerScreen::raise_for_offer is a
behaviour-neutral forwarder so the Skip-offer case compiles.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
LEFT/RIGHT taps, holds and FF/REW only move the scrub target, playing or paused.
Releasing a held key, the lost-keyup net and the 450 ms tap debounce end the key
gesture and seek nothing; the film plays on with the transport held up. OK / PLAY /
PLAYPAUSE take the target (the paused-target path, generalised): one SeekTo, the film
plays on, the 5 s undo window opens. BACK drops it; a panel/capsule over the page,
UP/DOWN off the scrubber, a Skip offer, the control row's press and a teardown cancel
it - never commit it. A pointer drag still commits on release (CommitSeek).

Removed: Scrub::commit_at, Scrub::paused, step_tap_commit, finish_hold, the paused-only
tick retire, input::TAP_COMMIT_MS; the player SHAPE loses scrub.commit_at (pin bumped).
docs/ux-scenario.md 6.4/6.6 describe the rule.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
PlayerScreen's recorded shape lost scrub.commit_at (click-to-confirm), so the screen
shape pin moved and the committed recordings could not load. Re-recorded with
tests/focusfp.sh --rec + tools/plxnative-rec rerecord (anchors preserved); make
check-replay: 3 fixtures, 6 replays, 0 failures, every difference counter 0.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…e stills keep arriving

Co-Authored-By: Claude Opus 5.5 <[email protected]>
GLinnik21 and others added 3 commits October 16, 2026 14:04
…0 s tolerance is for a settled one

A hold at SCRUB_MAX slews the target ~38 s per still fetched, so the newest arrived still was
always outside STILL_TOLERANCE_MS and the card hid 400 ms into every fast hold. The staleness
clock now restarts on every target move and only runs out once the target has settled.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
A committed scrub is final. BACK afterwards is BACK's ordinary meaning; BACK during a live
or pending target still cancels it. Removed: the 5 s window, the ghost tick and the
'BACK - m:ss' chip (and its LineExtents plumbing out of draw_playbar), the close-undo
bookkeeping (capsule dismissal, panel, Skip pill, UP-hide, teardown), Scrub::origin_ns and
begin_gesture. The knob spring is the survivor, now appkit::knob_spring. docs/ux-scenario.md
6.4/6.6 updated.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@GLinnik21
GLinnik21 merged commit 7c1fa29 into main Oct 16, 2026
26 of 28 checks passed
@GLinnik21
GLinnik21 deleted the scrub-click-to-confirm branch October 16, 2026 11:47
@fingers986

fingers986 commented Oct 17, 2026 •

Copy link
Copy Markdown

The video should pause during seeking.
Currently on nightly build 20161017, the video continues playing while seeking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants