Fix Cmd+Shift+key combos being swallowed for unbound keys (#1959)
Use charactersIgnoringModifiers instead of characters when redispatching Cmd-modified key events in performKeyEquivalent. Cmd-modified keys don't produce text characters, so event.characters returns an empty string for Cmd+Shift combos, preventing Ghostty from encoding them as kitty protocol sequences. charactersIgnoringModifiers returns the actual key character (e.g. "k" for Cmd+Shift+K) while modifiers are preserved in modifierFlags. Fixes #1718 Co-authored-by: CHE-3 <schumannzheng@gmail.com> Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
e0e0e35279
commit
eb248a1cdb
1 changed files with 1 additions and 1 deletions
|
|
@ -5110,7 +5110,7 @@ class GhosttyNSView: NSView, NSUserInterfaceValidations {
|
|||
if let lastPerformKeyEvent {
|
||||
self.lastPerformKeyEvent = nil
|
||||
if lastPerformKeyEvent == event.timestamp {
|
||||
equivalent = event.characters ?? ""
|
||||
equivalent = event.charactersIgnoringModifiers ?? ""
|
||||
break
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue