aboutsummaryrefslogtreecommitdiff
path: root/engines/agi/keyboard.cpp
diff options
context:
space:
mode:
authorFilippos Karapetis2011-09-26 04:23:03 +0300
committerFilippos Karapetis2011-09-26 04:23:03 +0300
commit40703426c971f92f1397a34b780ba9a72586711b (patch)
tree9810cd943de344030b338929f9c7ee7ba96cda9f /engines/agi/keyboard.cpp
parent62c8d825608c8aa4b4e0b52629e6b34adb26111d (diff)
downloadscummvm-rg350-40703426c971f92f1397a34b780ba9a72586711b.tar.gz
scummvm-rg350-40703426c971f92f1397a34b780ba9a72586711b.tar.bz2
scummvm-rg350-40703426c971f92f1397a34b780ba9a72586711b.zip
AGI: Fix for bug #3018770 - "AGI: PQ1: Flickering newspaper"
Diffstat (limited to 'engines/agi/keyboard.cpp')
-rw-r--r--engines/agi/keyboard.cpp15
1 files changed, 11 insertions, 4 deletions
diff --git a/engines/agi/keyboard.cpp b/engines/agi/keyboard.cpp
index 4ac08492ae..6d6d55ed24 100644
--- a/engines/agi/keyboard.cpp
+++ b/engines/agi/keyboard.cpp
@@ -180,10 +180,17 @@ int AgiEngine::handleController(int key) {
if (!(getFeatures() & GF_AGIMOUSE)) {
// Handle mouse button events
if (key == BUTTON_LEFT) {
- v->flags |= fAdjEgoXY;
- v->parm1 = WIN_TO_PIC_X(_mouse.x);
- v->parm2 = WIN_TO_PIC_Y(_mouse.y);
- return true;
+ if (getGameID() == GID_PQ1 && _game.vars[vCurRoom] == 116) {
+ // Special handling for mouse clicks in the newspaper
+ // screen of PQ1. Fixes bug #3018770.
+ d = 3; // fake a right arrow key (next page)
+ } else {
+ // Click-to-walk mouse interface
+ v->flags |= fAdjEgoXY;
+ v->parm1 = WIN_TO_PIC_X(_mouse.x);
+ v->parm2 = WIN_TO_PIC_Y(_mouse.y);
+ return true;
+ }
}
}