summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2005-04-04 19:14:40 +0000
committerDarkvater <darkvater@openttd.org>2005-04-04 19:14:40 +0000
commit42eae13270ac953dc78c637005c2c86552ada8c3 (patch)
tree8c7e58759162843ddc0c56ac5d2f89a2b625180c
parentead34df653458301e5d12e3ac66fc2904957b2b3 (diff)
downloadopenttd-42eae13270ac953dc78c637005c2c86552ada8c3.tar.xz
(svn r2149) - Fix (Regression): [ 1175877 ] Inputbox of savegamedialog did not have "focus", keyinput went to game. A quick fix for the horrid inputkey-handling.
-rw-r--r--window.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/window.c b/window.c
index becc44d11..5cd58390e 100644
--- a/window.c
+++ b/window.c
@@ -1266,14 +1266,14 @@ static void HandleKeypress(uint32 key)
we.keypress.cont = true;
// check if we have a query string window open before allowing hotkeys
- if(FindWindowById(WC_QUERY_STRING, 0)!=NULL || FindWindowById(WC_SEND_NETWORK_MSG, 0)!=NULL || FindWindowById(WC_CONSOLE, 0)!=NULL)
+ if(FindWindowById(WC_QUERY_STRING, 0)!=NULL || FindWindowById(WC_SEND_NETWORK_MSG, 0)!=NULL || FindWindowById(WC_CONSOLE, 0)!=NULL || FindWindowById(WC_SAVELOAD, 0)!=NULL)
query_open = true;
// Call the event, start with the uppermost window.
for(w=_last_window; w != _windows;) {
--w;
// if a query window is open, only call the event for certain window types
- if(query_open && w->window_class!=WC_QUERY_STRING && w->window_class!=WC_SEND_NETWORK_MSG && w->window_class!=WC_CONSOLE)
+ if(query_open && w->window_class!=WC_QUERY_STRING && w->window_class!=WC_SEND_NETWORK_MSG && w->window_class!=WC_CONSOLE && w->window_class!=WC_SAVELOAD)
continue;
w->wndproc(w, &we);
if (!we.keypress.cont)