macos: ignore modifier changes while IM is active

Fixes #4634
This commit is contained in:
Mitchell Hashimoto
2025-01-05 13:30:33 -08:00
parent 143c01edcb
commit ed221f32fe

View File

@ -945,6 +945,9 @@ extension Ghostty {
default: return default: return
} }
// If we're in the middle of a preedit, don't do anything with mods.
if hasMarkedText() { return }
// The keyAction function will do this AGAIN below which sucks to repeat // The keyAction function will do this AGAIN below which sucks to repeat
// but this is super cheap and flagsChanged isn't that common. // but this is super cheap and flagsChanged isn't that common.
let mods = Ghostty.ghosttyMods(event.modifierFlags) let mods = Ghostty.ghosttyMods(event.modifierFlags)