diff options
author | michi_cc <michi_cc@openttd.org> | 2013-08-05 20:36:32 +0000 |
---|---|---|
committer | michi_cc <michi_cc@openttd.org> | 2013-08-05 20:36:32 +0000 |
commit | 270d8aa639341f8be7fde9aa6e6f5bb6fa894d4f (patch) | |
tree | 17fea95fbb6309e6250ef15b52910e8f5932b9bc /src | |
parent | 1567e32d89d338fcdf7ac47f4d5fb02e1ca8c18a (diff) | |
download | openttd-270d8aa639341f8be7fde9aa6e6f5bb6fa894d4f.tar.xz |
(svn r25670) -Codechange: Pass UCS-4 characters to the edit box key handler.
Diffstat (limited to 'src')
-rw-r--r-- | src/textbuf.cpp | 2 | ||||
-rw-r--r-- | src/textbuf_type.h | 2 | ||||
-rw-r--r-- | src/window.cpp | 2 | ||||
-rw-r--r-- | src/window_gui.h | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/src/textbuf.cpp b/src/textbuf.cpp index c7071565a..58f931f8a 100644 --- a/src/textbuf.cpp +++ b/src/textbuf.cpp @@ -362,7 +362,7 @@ bool Textbuf::HandleCaret() return false; } -HandleKeyPressResult Textbuf::HandleKeyPress(uint16 key, uint16 keycode) +HandleKeyPressResult Textbuf::HandleKeyPress(WChar key, uint16 keycode) { bool edited = false; diff --git a/src/textbuf_type.h b/src/textbuf_type.h index 4d1a926fb..597615990 100644 --- a/src/textbuf_type.h +++ b/src/textbuf_type.h @@ -56,7 +56,7 @@ struct Textbuf { bool DeleteChar(uint16 keycode); bool MovePos(uint16 keycode); - HandleKeyPressResult HandleKeyPress(uint16 key, uint16 keycode); + HandleKeyPressResult HandleKeyPress(WChar key, uint16 keycode); bool HandleCaret(); void UpdateSize(); diff --git a/src/window.cpp b/src/window.cpp index d3d9baadd..bf51fd7ad 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -2378,7 +2378,7 @@ static bool MaybeBringWindowToFront(Window *w) * @return #ES_HANDLED if the key press has been handled and no other * window should receive the event. */ -EventState Window::HandleEditBoxKey(int wid, uint16 key, uint16 keycode) +EventState Window::HandleEditBoxKey(int wid, WChar key, uint16 keycode) { QueryString *query = this->GetQueryString(wid); if (query == NULL) return ES_NOT_HANDLED; diff --git a/src/window_gui.h b/src/window_gui.h index 433ed8729..ce9c062c6 100644 --- a/src/window_gui.h +++ b/src/window_gui.h @@ -488,7 +488,7 @@ public: void UnfocusFocusedWidget(); bool SetFocusedWidget(int widget_index); - EventState HandleEditBoxKey(int wid, uint16 key, uint16 keycode); + EventState HandleEditBoxKey(int wid, WChar key, uint16 keycode); void HandleButtonClick(byte widget); int GetRowFromWidget(int clickpos, int widget, int padding, int line_height = -1) const; |