Skip to content

Commit

Permalink
HOPKINS: Fix problem with some keys (A, Z, Q, M on Azerty keyboards)
Browse files Browse the repository at this point in the history
  • Loading branch information
Strangerke committed Nov 21, 2012
1 parent cbbc928 commit 42bafc5
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions engines/hopkins/events.cpp
Expand Up @@ -211,19 +211,24 @@ void EventsManager::pollEvents() {
return;
case Common::EVENT_LBUTTONDOWN:
souris_b = 1;
break;
return;
case Common::EVENT_RBUTTONDOWN:
souris_b = 2;
break;
return;
case Common::EVENT_LBUTTONUP:
case Common::EVENT_RBUTTONUP:
souris_b = 0;
return;

default:
break;
}
}

for (char chr = 'A'; chr <= 'Z'; chr++)
keyState[chr] = false;

for (char chr = '0'; chr <= '9'; chr++)
keyState[chr] = false;
}

void EventsManager::handleKey(Common::Event &event) {
Expand Down Expand Up @@ -271,8 +276,10 @@ int EventsManager::keywin() {
if (keyState['.'])
foundChar = '.';
else if (keyState[8])
// BACKSPACE
foundChar = 8;
else if (keyState[13])
// ENTER
foundChar = 13;
else if (keyState[' '])
foundChar = ' ';
Expand Down

0 comments on commit 42bafc5

Please sign in to comment.