[client] client: release escape key on focus loss

This prevents the escape key from being treated as held down indefinitely when
losing focus while holding the escape key.
This commit is contained in:
Quantum 2021-07-30 21:16:07 -04:00 committed by Geoffrey McRae
parent 7801575d99
commit 7d78cba38c

View file

@ -93,6 +93,8 @@ void app_handleFocusEvent(bool focused)
if (g_state.keyDown[key]) if (g_state.keyDown[key])
app_handleKeyRelease(key); app_handleKeyRelease(key);
g_state.escapeActive = false;
if (!g_params.showCursorDot) if (!g_params.showCursorDot)
g_state.ds->setPointer(LG_POINTER_NONE); g_state.ds->setPointer(LG_POINTER_NONE);