aboutsummaryrefslogtreecommitdiff
path: root/engines/agi/keyboard.cpp
diff options
context:
space:
mode:
authorFilippos Karapetis2009-02-12 15:13:52 +0000
committerFilippos Karapetis2009-02-12 15:13:52 +0000
commit0015657caad6d4824a3b146fb34c4255aeeff72b (patch)
treed5d1b0da7d3799f43a67464c2d6c4c258b90b1cb /engines/agi/keyboard.cpp
parent521cc089110501c456844a4bc5963bd6d8e4df5c (diff)
downloadscummvm-rg350-0015657caad6d4824a3b146fb34c4255aeeff72b.tar.gz
scummvm-rg350-0015657caad6d4824a3b146fb34c4255aeeff72b.tar.bz2
scummvm-rg350-0015657caad6d4824a3b146fb34c4255aeeff72b.zip
Fix for bug #2541237 - "AGI: Restart quits ScummVM"
svn-id: r36279
Diffstat (limited to 'engines/agi/keyboard.cpp')
-rw-r--r--engines/agi/keyboard.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/engines/agi/keyboard.cpp b/engines/agi/keyboard.cpp
index 5525cfef99..d98e58d4d9 100644
--- a/engines/agi/keyboard.cpp
+++ b/engines/agi/keyboard.cpp
@@ -374,7 +374,7 @@ int AgiEngine::waitKey() {
}
debugC(3, kDebugLevelInput, "waiting...");
- while (!shouldQuit()) {
+ while (!(shouldQuit() || restartGame)) {
_gfx->pollTimer(); /* msdos driver -> does nothing */
key = doPollKeyboard();
if (key == KEY_ENTER || key == KEY_ESCAPE || key == BUTTON_LEFT)
@@ -397,7 +397,7 @@ int AgiEngine::waitAnyKey() {
}
debugC(3, kDebugLevelInput, "waiting...");
- while (!shouldQuit()) {
+ while (!(shouldQuit() || restartGame)) {
_gfx->pollTimer(); /* msdos driver -> does nothing */
key = doPollKeyboard();
if (key)