Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions src/Surface.zig
Original file line number Diff line number Diff line change
Expand Up @@ -4749,6 +4749,18 @@ pub fn cursorPosCallback(
}
}

// The ctrl/super link-activation chord reserves the whole click for
// the terminal (link activation / smart-select; see
// mouseButtonCallback), so a drag while it is held must not leak
// button-motion reports to a mouse-grabbing program either. Mirror the
// shift override above: only suppress while a button is pressed so pure
// movement reports are unaffected. Part of manaflow-ai/cmux#5128.
if (self.mouse.mods.equal(input.ctrlOrSuper(.{}))) {
for (self.mouse.click_state) |state| {
if (state != .release) break :report;
}
}

// We use the first mouse button we find pressed in order to report
// since the spec (afaict) does not say...
const button: ?input.MouseButton = button: for (self.mouse.click_state, 0..) |state, i| {
Expand Down
Loading