From 2460fefec8558bcb8bb5517a50b28fbf0b0054e2 Mon Sep 17 00:00:00 2001 From: Adrian Siekierka Date: Sun, 19 Mar 2023 09:00:50 +0100 Subject: [PATCH] hotfix --- src/sdl/frontend.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/sdl/frontend.c b/src/sdl/frontend.c index b880938..09cc6ff 100644 --- a/src/sdl/frontend.c +++ b/src/sdl/frontend.c @@ -617,8 +617,8 @@ int main(int argc, char **argv) { scode = event.key.keysym.scancode; kcode = event.key.keysym.sym; if (zzt_kmod_get() & ZZT_KMOD_CTRL) { - if (!(kcode >= 97 && kcode <= 122)) break; - kcode -= 96; + if (!((kcode >= 97 && kcode <= 122) || (kcode >= 65 && kcode <= 90))) break; + kcode &= 0x1F; scode = 0; } @@ -648,8 +648,8 @@ int main(int argc, char **argv) { scode = event.key.keysym.scancode; kcode = event.key.keysym.sym; if (zzt_kmod_get() & ZZT_KMOD_CTRL) { - if (!(kcode >= 97 && kcode <= 122)) break; - kcode -= 96; + if (!((kcode >= 97 && kcode <= 122) || (kcode >= 65 && kcode <= 90))) break; + kcode &= 0x1F; scode = 0; }