Repository navigation
Fix delayed clipboard card selection - #108
Open
loudsun1997 wants to merge 2 commits into
Open
loudsun1997 wants to merge 2 commits into
loudsun1997 wants to merge 2 commits into
Conversation
This branch has not been deployed
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.
Single-clicking a clipboard card waits for the double-click recognizer before updating selection. Native event comparisons measured about 359–361 ms before the selection callback. Selecting on the first click is valid for both a single click and the first half of a double-click, so selection can happen immediately and the second click can still paste.
Implementation and justification
Reproducible validation
swift test: all 10 unit tests pass, including three selection regressions. These assert selected IDs and the flag controlling scrolling.bash scripts/check_card_interactions.sh: all 13 native gesture scenarios pass, including original-handler comparisons and quick Shift/Command release. The checked-in probe measured 360.7 ms for the original single click versus 2.4–4.8 ms for updated selection callbacks; earlier runs measured about 359 ms versus 2–18 ms.bash scripts/check_bar_navigation.sh: all 10 integration checks pass using the real strip, cards, and store with disposable fixture history. It verifies actual scroll offsets stay unchanged after a click, navigation reveals an offscreen card, right-edge alignment works, and the native context menu opens and dismisses without changing selection.Both GUI probes open their own windows and exit on failure. The gesture probe uses recording callbacks; the strip probe redirects its home/application-support directory and does not start clipboard polling, the app delegate, or global hotkeys.
Coverage boundaries and manual review
The native probes post synthetic events with explicit click counts and measure callbacks/scroll positions, not physical mouse classification or total frame-rendering latency. Strip navigation invokes the same store method used by the key handler, without exercising physical key routing. The integration probe opens and dismisses context menus without invoking their actions.
Physical text/image/file drag-and-drop, context-menu actions, external-app paste, physical key routing, macOS 14/26 runtime behavior, and Intel runtime behavior still need separate checks. Intel compilation does not establish Intel interaction behavior. The integration probe covers the strip rather than the complete production window/hotkey/paste pipeline.
The checked-in rationale, reproduction commands, results, and full-app checklist capture these distinctions. No visual styling changes; the UI changes affect interaction timing and scrolling.