From 04f1e58db9ef9dd87bb4a829d000b02da0304c3b Mon Sep 17 00:00:00 2001 From: fgsfds Date: Fri, 12 Apr 2019 15:09:51 +0300 Subject: [PATCH] fix key repeat in GUI --- src/game/g_window.pas | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/game/g_window.pas b/src/game/g_window.pas index df44683..95e2c4d 100644 --- a/src/game/g_window.pas +++ b/src/game/g_window.pas @@ -61,7 +61,7 @@ uses g_console, e_input, g_options, g_game, g_basic, g_textures, e_sound, g_sound, g_menu, ENet, g_net, g_map, g_gfx, g_monsters, xprofiler, - g_touch; + g_touch, g_gui; const @@ -513,7 +513,12 @@ begin if g_dbg_input then e_LogWritefln('Input Debug: keysym, press=%s, scancode=%s', [down, key]); e_KeyUpDown(key, down); - g_Console_ProcessBind(key, down) + g_Console_ProcessBind(key, down); + end + else if gConsoleShow or (g_ActiveWindow <> nil) then + begin + // key repeat in menus and shit + KeyPress(key); end; end; -- 2.29.2