Problem
quadraui ships DoubleClickDetector (quadraui/src/dispatch.rs:870), and TuiBackend already embeds one (tui/backend.rs:129, :235) and emits UiEvent::DoubleClick. src/tui_main/shell_app.rs handles UiEvent::DoubleClick at 8 sites.
At the same time, src/tui_main/mouse.rs threads last_click_time / last_click_pos through handle_mouse (:262-263) and re-detects double-clicks with a hand-rolled 400 ms window at :572, :1958, :2076, :2158.
Two double-click detectors are running on one backend, with independent timing state that can disagree. grep -rn DoubleClickDetector src/ → 0.
Fix
Delete the hand-rolled detection. Route all four sites through the UiEvent::DoubleClick the backend already emits, matching the 8 sites in shell_app.rs that consume it. Drop last_click_time / last_click_pos from handle_mouse's parameter list (it currently takes 33 parameters — this is a small step toward that being tractable).
Check the GTK side for the same pattern while here: src/app.rs:1182-1292 handles double/ctrl click.
Acceptance
- Black-box tests required — double-click word selection in the editor, and on whichever of the four sites (
:1958, :2076, :2158) are user-reachable.
- State in the PR that the new tests fail against unfixed
develop.
- Both backends per the multi-backend rule.
Problem
quadraui ships
DoubleClickDetector(quadraui/src/dispatch.rs:870), andTuiBackendalready embeds one (tui/backend.rs:129,:235) and emitsUiEvent::DoubleClick.src/tui_main/shell_app.rshandlesUiEvent::DoubleClickat 8 sites.At the same time,
src/tui_main/mouse.rsthreadslast_click_time/last_click_posthroughhandle_mouse(:262-263) and re-detects double-clicks with a hand-rolled 400 ms window at:572,:1958,:2076,:2158.Two double-click detectors are running on one backend, with independent timing state that can disagree.
grep -rn DoubleClickDetector src/→ 0.Fix
Delete the hand-rolled detection. Route all four sites through the
UiEvent::DoubleClickthe backend already emits, matching the 8 sites inshell_app.rsthat consume it. Droplast_click_time/last_click_posfromhandle_mouse's parameter list (it currently takes 33 parameters — this is a small step toward that being tractable).Check the GTK side for the same pattern while here:
src/app.rs:1182-1292handles double/ctrl click.Acceptance
:1958,:2076,:2158) are user-reachable.develop.