X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fevents.c;h=fd735bfe3a0e427cf34510e2179d2278a5e245a5;hb=df969973a1da42d3d6e4cce899e0c8b9fd0335a8;hp=1d02e8c238d01295a3a9a643d0dd3e99bd9e26ff;hpb=36fdadd45345a6ce4402fa3bdbb3b12b4cbb62ee;p=rocksndiamonds.git diff --git a/src/events.c b/src/events.c index 1d02e8c2..fd735bfe 100644 --- a/src/events.c +++ b/src/events.c @@ -22,7 +22,7 @@ #include "network.h" -#define DEBUG_EVENTS 1 +#define DEBUG_EVENTS 0 #define DEBUG_EVENTS_BUTTON (DEBUG_EVENTS * 0) #define DEBUG_EVENTS_MOTION (DEBUG_EVENTS * 0) @@ -801,11 +801,7 @@ void HandleTextEvent(TextEvent *event) } #endif - // if (game_status != GAME_MODE_PLAYING && GetKeyModState() != KMOD_None) - /* - if (game_status != GAME_MODE_PLAYING && - (GetKeyModState() & KMOD_TextInput) != KMOD_None) - */ + // only handle key input with text modifier keys pressed if (checkTextInputKeyModState()) { HandleKey(key, KEY_PRESSED); @@ -854,6 +850,7 @@ void HandleKeyEvent(KeyEvent *event) HandleKeyModState(keymod, key_status); #if defined(TARGET_SDL2) + // only handle raw key input without text modifier keys pressed if (!checkTextInputKeyModState()) HandleKey(key, key_status); #else