aboutsummaryrefslogtreecommitdiff
path: root/engines/parallaction/input.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/parallaction/input.cpp')
-rw-r--r--engines/parallaction/input.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/engines/parallaction/input.cpp b/engines/parallaction/input.cpp
index 4904e63df6..3bedebb7f3 100644
--- a/engines/parallaction/input.cpp
+++ b/engines/parallaction/input.cpp
@@ -212,6 +212,8 @@ int Input::updateGameInput() {
int Input::updateInput() {
+ int oldMode = _inputMode;
+
int event = kEvNone;
readInput();
@@ -225,6 +227,13 @@ int Input::updateInput() {
break;
}
+ // when mode changes, then consider any input consumed
+ // for the current frame
+ if (oldMode != _inputMode) {
+ _mouseButtons = kEvNone;
+ _hasKeyPressEvent = false;
+ }
+
return event;
}