From cd090435587ccfaa675ea2273e8fcdc7649612e3 Mon Sep 17 00:00:00 2001 From: Nessun Kim Date: Thu, 25 Nov 2021 20:12:00 +0900 Subject: [PATCH] Fix hotkey setter to handle backticks and tildes properly --- tabby-core/src/services/hotkeys.util.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tabby-core/src/services/hotkeys.util.ts b/tabby-core/src/services/hotkeys.util.ts index 467432c6..8a35bc8a 100644 --- a/tabby-core/src/services/hotkeys.util.ts +++ b/tabby-core/src/services/hotkeys.util.ts @@ -39,6 +39,10 @@ export function getKeyName (event: KeyEventData): KeyName { key = altKeyName } else if (event.key === 'Shift') { key = 'Shift' + } else if (event.key === '`') { + key = '`' + } else if (event.key === '~') { + key = '~' } else { key = event.code if (REGEX_LATIN_KEYNAME.test(event.key)) { @@ -54,7 +58,6 @@ export function getKeyName (event: KeyEventData): KeyName { Slash: '/', Backslash: '\\', IntlBackslash: '`', - Backquote: '~', // Electron says it's the tilde Minus: '-', Equal: '=', Semicolon: ';',