summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/bridge_gui.cpp2
-rw-r--r--src/console_gui.cpp2
-rw-r--r--src/error_gui.cpp2
-rw-r--r--src/fios_gui.cpp2
-rw-r--r--src/highscore_gui.cpp2
-rw-r--r--src/misc_gui.cpp2
-rw-r--r--src/network/network_chat_gui.cpp2
-rw-r--r--src/network/network_content_gui.cpp2
-rw-r--r--src/network/network_gui.cpp2
-rw-r--r--src/newgrf_gui.cpp2
-rw-r--r--src/news_gui.cpp2
-rw-r--r--src/window_gui.h3
12 files changed, 13 insertions, 12 deletions
diff --git a/src/bridge_gui.cpp b/src/bridge_gui.cpp
index 04a6e3760..61c477aea 100644
--- a/src/bridge_gui.cpp
+++ b/src/bridge_gui.cpp
@@ -241,7 +241,7 @@ public:
}
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
const uint8 i = keycode - '1';
if (i < 9 && i < this->bridges->Length()) {
diff --git a/src/console_gui.cpp b/src/console_gui.cpp
index 33e2ed1c5..dc9a0cb79 100644
--- a/src/console_gui.cpp
+++ b/src/console_gui.cpp
@@ -236,7 +236,7 @@ struct IConsoleWindow : Window
if (_iconsole_cmdline.HandleCaret()) this->SetDirty();
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
if (_focused_window != this) return ES_NOT_HANDLED;
diff --git a/src/error_gui.cpp b/src/error_gui.cpp
index ccbc18850..b498cff63 100644
--- a/src/error_gui.cpp
+++ b/src/error_gui.cpp
@@ -300,7 +300,7 @@ public:
if (_window_system_initialized) ShowFirstError();
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
if (keycode != WKC_SPACE) return ES_NOT_HANDLED;
delete this;
diff --git a/src/fios_gui.cpp b/src/fios_gui.cpp
index c3ef3b717..9551bb843 100644
--- a/src/fios_gui.cpp
+++ b/src/fios_gui.cpp
@@ -618,7 +618,7 @@ public:
}
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
if (keycode == WKC_ESC) {
delete this;
diff --git a/src/highscore_gui.cpp b/src/highscore_gui.cpp
index 9b832e3f5..d79afe4eb 100644
--- a/src/highscore_gui.cpp
+++ b/src/highscore_gui.cpp
@@ -63,7 +63,7 @@ struct EndGameHighScoreBaseWindow : Window {
delete this;
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
/* All keys are 'handled' by this window but we want to make
* sure that 'quit' still works correctly. Not handling the
diff --git a/src/misc_gui.cpp b/src/misc_gui.cpp
index b10c037f6..87847ba70 100644
--- a/src/misc_gui.cpp
+++ b/src/misc_gui.cpp
@@ -1027,7 +1027,7 @@ struct QueryWindow : public Window {
}
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
/* ESC closes the window, Enter confirms the action */
switch (keycode) {
diff --git a/src/network/network_chat_gui.cpp b/src/network/network_chat_gui.cpp
index 09d39b037..5fa311ba1 100644
--- a/src/network/network_chat_gui.cpp
+++ b/src/network/network_chat_gui.cpp
@@ -491,7 +491,7 @@ struct NetworkChatWindow : public Window {
}
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
EventState state = ES_NOT_HANDLED;
if (keycode == WKC_TAB) {
diff --git a/src/network/network_content_gui.cpp b/src/network/network_content_gui.cpp
index 358187cc2..3297b0071 100644
--- a/src/network/network_content_gui.cpp
+++ b/src/network/network_content_gui.cpp
@@ -800,7 +800,7 @@ public:
}
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
switch (keycode) {
case WKC_UP:
diff --git a/src/network/network_gui.cpp b/src/network/network_gui.cpp
index be028355e..7d2e47dbc 100644
--- a/src/network/network_gui.cpp
+++ b/src/network/network_gui.cpp
@@ -799,7 +799,7 @@ public:
this->SetDirty();
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
EventState state = ES_NOT_HANDLED;
diff --git a/src/newgrf_gui.cpp b/src/newgrf_gui.cpp
index 6ba2ade70..287ed0939 100644
--- a/src/newgrf_gui.cpp
+++ b/src/newgrf_gui.cpp
@@ -1235,7 +1235,7 @@ struct NewGRFWindow : public Window, NewGRFScanCallback {
this->SetWidgetDisabledState(WID_NS_PRESET_SAVE, has_missing);
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
if (!this->editable) return ES_NOT_HANDLED;
diff --git a/src/news_gui.cpp b/src/news_gui.cpp
index 89448edea..5639001b7 100644
--- a/src/news_gui.cpp
+++ b/src/news_gui.cpp
@@ -449,7 +449,7 @@ struct NewsWindow : Window {
}
}
- virtual EventState OnKeyPress(uint16 key, uint16 keycode)
+ virtual EventState OnKeyPress(WChar key, uint16 keycode)
{
if (keycode == WKC_SPACE) {
/* Don't continue. */
diff --git a/src/window_gui.h b/src/window_gui.h
index 820d90e2b..433ed8729 100644
--- a/src/window_gui.h
+++ b/src/window_gui.h
@@ -19,6 +19,7 @@
#include "widget_type.h"
#include "core/smallvec_type.hpp"
#include "core/smallmap_type.hpp"
+#include "string_type.h"
/**
* Flags to describe the look of the frame
@@ -593,7 +594,7 @@ public:
* @return #ES_HANDLED if the key press has been handled and no other
* window should receive the event.
*/
- virtual EventState OnKeyPress(uint16 key, uint16 keycode) { return ES_NOT_HANDLED; }
+ virtual EventState OnKeyPress(WChar key, uint16 keycode) { return ES_NOT_HANDLED; }
virtual EventState OnHotkey(int hotkey);