Repository navigation
fix: read the phone tab strip after a tap's press lets go, and have the shift watch hear it - #5675
Merged
Merged
Conversation
…he shift watch hear it Since #5340 took Leaf's buttons from Web Awesome's native styles, a pressed `.lf-btn` carries `transform: scale(.9875)` while it is `:active`. After a touch tap, Chromium keeps that press on a timer for about 100 ms past the pointer's last event. Two readings in `test_on_a_phone_turning_on_s_tabs_moves_nothing` caught that window: - **The assertion.** `panel_settled` returns inside the press window, so the tab geometry the test reads can include the press's scale. The failing reading is exactly that: the first tab's width goes 44.92 → 44.36 (× 0.9875), and x and y move by half the lost width and height. Whether a read lands in the window depends on timing, which is why CI's onset couldn't be bisected: the runtime speedups in `b3c9842e8..6cd5093` let `panel_settled` return sooner. The test now reads once no control in the panel's head is `:active`. No tab actually moves when the views change. - **The teardown error.** `shift_watch.js` only re-reads the page when something announces a change. When the press lets go on that timer, no event fires, so the verdict read found an unannounced change to the tab's text (`shift watch missed a change to #text in span.lf-fp-tab-words`). The watch now remembers the node a pointer released on and announces the frame where its `:active` match changes, which costs one `matches()` per frame. The header's "Unchanged frames" list names the new source. No product behavior changes; the press feedback stays. Verification: on main, the floating-panel test fails locally every run with the same numbers CI reports, and with this change it passed three runs in a row. Each half fails without the other. The new `test_a_tap_s_press_letting_go_is_heard` reports `shift-watch-missed` without the watch change and passes with it. The shift-watch tests matching press, tap, verdict and complete-readings (42) and the floating panel's phone/tap/touch tests pass. Closes #5653
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.
Since #5340 took Leaf's buttons from Web Awesome's native styles, a pressed
.lf-btncarriestransform: scale(.9875)while it is:active. After a touch tap, Chromium keeps that press on a timer for about 100 ms past the pointer's last event. Two readings intest_on_a_phone_turning_on_s_tabs_moves_nothingcaught that window:panel_settledreturns inside the press window, so the tab geometry the test reads can include the press's scale. The failing reading is exactly that: the first tab's width goes 44.92 → 44.36 (× 0.9875), and x and y move by half the lost width and height. Whether a read lands in the window depends on timing, which is why CI's onset couldn't be bisected: the runtime speedups inb3c9842e8..6cd5093f3letpanel_settledreturn sooner. The test now reads once no control in the panel's foot, where its tabs stand, is:active. No tab actually moves when the views change.shift_watch.jsonly re-reads the page when something announces a change. When the press lets go on that timer, no event fires, so the verdict read found an unannounced change to the tab's text (shift watch missed a change to #text in span.lf-fp-tab-words). The watch now remembers the node a pointer released on and announces the frame where its:activematch changes, which costs onematches()per frame. The header's "Unchanged frames" list names the new source.No product behavior changes; the press feedback stays.
Verification: on main, the floating-panel test fails locally every run with the same numbers CI reports, and with this change it passed three runs in a row. Each half fails without the other. The new
test_a_tap_s_press_letting_go_is_heardreportsshift-watch-missedwithout the watch change and passes with it. The shift-watch tests matching press, tap, verdict and complete-readings (42) and the floating panel's phone/tap/touch tests pass.Closes #5653 — automated triage