aboutsummaryrefslogtreecommitdiff
path: root/src/app/input/terminal.rs
diff options
context:
space:
mode:
authorMichael Hackner <mhackner@gmail.com>2026-08-13 08:00:32 -0700
committerGitHub <noreply@github.com>2026-08-13 18:00:32 +0300
commitf76d7df549e95e1699651f59916e9a38f0f58985 (patch)
treec8e50a75fd32e68d63b8e0386de7e791cb727fb4 /src/app/input/terminal.rs
parentb7dca4bb2a2cf488407ae051b40782f03fcabc62 (diff)
fix: keep tab and sidebar clicks when the terminal reports a stray drag (#2736)
* fix: keep tab and sidebar clicks when the terminal reports a stray drag This works around a Ghostty bug that causes herdr tabs to be unclickable in fullscreen mode. Ghostty on macOS in native fullscreen emits one motion report after a fresh press in the strip where the menu bar reveals, with the row shifted to near the bottom of the grid. The cause is upstream: macOS delivers one mouse event whose y is nearly a window height away from the real pointer, and Ghostty reports it as it arrives (iTerm2 and Terminal.app report the same clicks correctly). Herdr treated the stray report as a real drag and lost the click two ways: it opened a tab reorder with no drop target, making the release a no-op, and it handed the release to the pane under the bogus coordinates. Now, a press on the tab bar or sidebar owns the gesture until release, and a tab drag only starts once the pointer is over a real drop target. refs #796 * fix: scope chrome mouse gestures to their input source * fix: preserve chrome drag input source * fix: preserve concurrent chrome presses --------- Co-authored-by: Ogulcan Celik <ogulcancelik@gmail.com>
Diffstat (limited to 'src/app/input/terminal.rs')
-rw-r--r--src/app/input/terminal.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/app/input/terminal.rs b/src/app/input/terminal.rs
index bc9b2a59..12d09e6a 100644
--- a/src/app/input/terminal.rs
+++ b/src/app/input/terminal.rs
@@ -358,6 +358,7 @@ impl App {
pub(crate) fn release_input_source_headless(&mut self, source_id: crate::app::InputSourceId) {
// Pending URL clicks survive this call; see clear_input_source.
+ self.state.clear_chrome_gesture(source_id);
for pressed in self.take_pressed_keys_for_source(source_id) {
let release = pressed
.key
@@ -368,6 +369,7 @@ impl App {
pub(crate) async fn release_input_source(&mut self, source_id: crate::app::InputSourceId) {
// Pending URL clicks survive this call; see clear_input_source.
+ self.state.clear_chrome_gesture(source_id);
for pressed in self.take_pressed_keys_for_source(source_id) {
let release = pressed
.key