diff options
author | yexo <yexo@openttd.org> | 2009-03-11 09:21:11 +0000 |
---|---|---|
committer | yexo <yexo@openttd.org> | 2009-03-11 09:21:11 +0000 |
commit | 2b0b9a6367b993bf437d06236a9cca9025588dd6 (patch) | |
tree | 90bfe71b0685ad9f8fb2a7c2ad7a7ab4b4b1b36a /src/window.cpp | |
parent | 13fb01d07dde0e2749eef2948071d513a4685215 (diff) | |
download | openttd-2b0b9a6367b993bf437d06236a9cca9025588dd6.tar.xz |
(svn r15669) -Change: Key presses that are not handles by an input box are no longer marked as handled but given to other OnKeyPress handlers. This makes the global shortcuts like F1 work again when an input box is open.
Diffstat (limited to 'src/window.cpp')
-rw-r--r-- | src/window.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/window.cpp b/src/window.cpp index a72935021..b2fa9e131 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -1750,8 +1750,7 @@ void HandleKeypress(uint32 raw_key) /* Check if the focused window has a focused editbox */ if (EditBoxInGlobalFocus()) { /* All input will in this case go to the focused window */ - _focused_window->OnKeyPress(key, keycode); - return; + if (_focused_window->OnKeyPress(key, keycode) == Window::ES_HANDLED) return; } /* Call the event, start with the uppermost window. */ |