mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-17 09:16:11 +03:00
Fixed accidentally consuming ALL shift+<key> releases 😅
This commit is contained in:
@ -1273,9 +1273,6 @@ pub fn keyCallback(
|
|||||||
|
|
||||||
if (selection == null) break :adjust_selection;
|
if (selection == null) break :adjust_selection;
|
||||||
|
|
||||||
// Silently consume key releases.
|
|
||||||
if (event.action != .press and event.action != .repeat) return .consumed;
|
|
||||||
|
|
||||||
var sel = selection.?;
|
var sel = selection.?;
|
||||||
|
|
||||||
const viewport_end = screen.viewport + terminal.Screen.RowIndexTag.viewport.maxLen(&screen) - 1;
|
const viewport_end = screen.viewport + terminal.Screen.RowIndexTag.viewport.maxLen(&screen) - 1;
|
||||||
@ -1362,6 +1359,10 @@ pub fn keyCallback(
|
|||||||
},
|
},
|
||||||
else => { break :adjust_selection; },
|
else => { break :adjust_selection; },
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Silently consume key releases.
|
||||||
|
if (event.action != .press and event.action != .repeat) return .consumed;
|
||||||
|
|
||||||
// If the selection endpoint is outside of the current viewpoint, scroll it in to view.
|
// If the selection endpoint is outside of the current viewpoint, scroll it in to view.
|
||||||
if (sel.end.y < screen.viewport) {
|
if (sel.end.y < screen.viewport) {
|
||||||
try self.io.terminal.scrollViewport(.{
|
try self.io.terminal.scrollViewport(.{
|
||||||
|
Reference in New Issue
Block a user