diff options
author | rubidium <rubidium@openttd.org> | 2008-05-17 23:11:06 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2008-05-17 23:11:06 +0000 |
commit | f5681547efc060ab0cc47c36316c4f2aa1217948 (patch) | |
tree | cdbaf12f7c5a7666ecc23983c51dca268e3b58e2 /src/console.cpp | |
parent | c1713c9ab7438386dbda32b4c33e95995882f702 (diff) | |
download | openttd-f5681547efc060ab0cc47c36316c4f2aa1217948.tar.xz |
(svn r13151) -Codechange: use an enum instead of bool as return type of OnKeyPress/OnCTRLStateChange to make it obvious what the return values mean.
Diffstat (limited to 'src/console.cpp')
-rw-r--r-- | src/console.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/console.cpp b/src/console.cpp index 8a01f7786..20464a71f 100644 --- a/src/console.cpp +++ b/src/console.cpp @@ -126,7 +126,7 @@ struct IConsoleWindow : Window if (HandleCaret(&_iconsole_cmdline)) this->SetDirty(); } - virtual bool OnKeyPress(uint16 key, uint16 keycode) + virtual EventState OnKeyPress(uint16 key, uint16 keycode) { switch (keycode) { case WKC_UP: @@ -230,10 +230,10 @@ struct IConsoleWindow : Window IConsoleResetHistoryPos(); this->SetDirty(); } else { - return true; + return ES_NOT_HANDLED; } } - return false; + return ES_HANDLED; } }; |