Merge pull request #1206 from AronHK/keybind

Fix alt-tab, round 2
This commit is contained in:
Ajay Ramachandran
2022-02-24 12:46:41 -05:00
committed by GitHub

View File

@@ -1987,7 +1987,7 @@ function addPageListeners(): void {
function addHotkeyListener(): void {
document.addEventListener("keydown", hotkeyListener);
document.addEventListener("keyup", (e) => pressedKeys.delete(e.key));
document.addEventListener("focus", (e) => pressedKeys.clear());
window.addEventListener("focus", (e) => pressedKeys.clear());
}
function hotkeyListener(e: KeyboardEvent): void {