aboutsummaryrefslogtreecommitdiff
path: root/engines/touche
diff options
context:
space:
mode:
authorJohannes Schickel2014-02-14 20:09:14 +0100
committerJohannes Schickel2014-02-14 20:09:14 +0100
commit94f7d01882543c5e173a456f7a865c05ce81dd81 (patch)
treee6324c0cafea34778094688eb7e51bfc995f9057 /engines/touche
parent4e290bf47533d6ec8f45dfdecb229ec06fea0a75 (diff)
downloadscummvm-rg350-94f7d01882543c5e173a456f7a865c05ce81dd81.tar.gz
scummvm-rg350-94f7d01882543c5e173a456f7a865c05ce81dd81.tar.bz2
scummvm-rg350-94f7d01882543c5e173a456f7a865c05ce81dd81.zip
TOUCHE: Use keycodes for hotkey handling.
Diffstat (limited to 'engines/touche')
-rw-r--r--engines/touche/menu.cpp10
-rw-r--r--engines/touche/touche.cpp4
2 files changed, 7 insertions, 7 deletions
diff --git a/engines/touche/menu.cpp b/engines/touche/menu.cpp
index 85ca519f05..045b594aed 100644
--- a/engines/touche/menu.cpp
+++ b/engines/touche/menu.cpp
@@ -569,29 +569,29 @@ int ToucheEngine::displayQuitDialog() {
quitLoop = true;
switch (_language) {
case Common::FR_FRA:
- if (event.kbd.ascii == 'o' || event.kbd.ascii == 'O') {
+ if (event.kbd.keycode == Common::KEYCODE_o) {
ret = 1;
}
break;
case Common::DE_DEU:
- if (event.kbd.ascii == 'j' || event.kbd.ascii == 'J') {
+ if (event.kbd.keycode == Common::KEYCODE_j) {
ret = 1;
}
break;
case Common::ES_ESP:
- if (event.kbd.ascii == 's' || event.kbd.ascii == 'S') {
+ if (event.kbd.keycode == Common::KEYCODE_s) {
ret = 1;
}
break;
case Common::PL_POL:
- if (event.kbd.ascii == 's' || event.kbd.ascii == 'S' || event.kbd.ascii == 't' || event.kbd.ascii == 'T') {
+ if (event.kbd.keycode == Common::KEYCODE_s || event.kbd.keycode == Common::KEYCODE_t) {
ret = 1;
}
break;
default:
// According to cyx, the Italian version uses the same
// keys as the English one.
- if (event.kbd.ascii == 'y' || event.kbd.ascii == 'Y') {
+ if (event.kbd.keycode == Common::KEYCODE_y) {
ret = 1;
}
break;
diff --git a/engines/touche/touche.cpp b/engines/touche/touche.cpp
index b3e3ca5b50..eb7010a824 100644
--- a/engines/touche/touche.cpp
+++ b/engines/touche/touche.cpp
@@ -416,13 +416,13 @@ void ToucheEngine::processEvents(bool handleKeyEvents) {
this->getDebugger()->onFrame();
}
} else {
- if (event.kbd.ascii == 't') {
+ if (event.kbd.keycode == Common::KEYCODE_t) {
++_talkTextMode;
if (_talkTextMode == kTalkModeCount) {
_talkTextMode = 0;
}
displayTextMode(-(92 + _talkTextMode));
- } else if (event.kbd.ascii == ' ') {
+ } else if (event.kbd.keycode == Common::KEYCODE_SPACE) {
updateKeyCharTalk(2);
}
}