Repository navigation
fix(annotate): Undo ring stops when held and drains again after - #3071
Merged
Merged
Conversation
…tdown The ring was rebuilt in poll after a hover handler had already re-run the view, and poll did not report the rebuild as a change, so the view kept the previous ring: held rings drained on and resumed ones stood frozen until the chip left.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Annotate Undo countdown ring now stops when you point at the capsule and drains again when you move away, instead of running on and then freezing.
The ring around the Undo button shows how long is left to take a send back. Pointing at the capsule pauses that countdown.
❌ Before
✅ After
The ring is rebuilt whenever the countdown pauses or resumes. That rebuild happened in the next frame's update step, which didn't tell the view to redraw. The pointer had already redrawn the view, so the screen always drew the previous ring.
📊 Proof
A new motion test plays a send at 60 fps, points at the capsule, then moves away. It checks that the ring moves by about the same step each frame, holds still with no frames while it's held, and redraws nothing at rest, with and without Reduce Motion. It fails without the fix ("a held ring moved -1.6").
👀 Read:
capture_capsule/mod.rs, where the ring now syncs with the rest of the live state andpollcounts a rebuilt ring as a change. The rest is routine.🔍 Seen in real use · reproduced in a headless motion test · no static rendering change, so goldens are unchanged
Checks run
scripts/check capture_capsule: 148 passedcargo clippy --locked --bin hex -- -D warnings: cleanpython3 scripts/code-shape.py: passes (only existing warnings)