aboutsummaryrefslogtreecommitdiff
path: root/engines/mortevielle
diff options
context:
space:
mode:
authorPaul Gilbert2012-01-22 09:16:41 +1100
committerStrangerke2012-04-06 08:20:44 +0200
commit02f2088d43adc2514895fd845bc9dce17fd1a36b (patch)
treeed488e9a7f49030c424971f75151749e3b395181 /engines/mortevielle
parentf875622ef63ab86ba248ada0c917bd6b97c80736 (diff)
downloadscummvm-rg350-02f2088d43adc2514895fd845bc9dce17fd1a36b.tar.gz
scummvm-rg350-02f2088d43adc2514895fd845bc9dce17fd1a36b.tar.bz2
scummvm-rg350-02f2088d43adc2514895fd845bc9dce17fd1a36b.zip
MORTEVIELLE: Added extra quit checks to event loops
Diffstat (limited to 'engines/mortevielle')
-rw-r--r--engines/mortevielle/actions.cpp2
-rw-r--r--engines/mortevielle/alert.cpp2
-rw-r--r--engines/mortevielle/mor2.cpp2
-rw-r--r--engines/mortevielle/mortevielle.h1
-rw-r--r--engines/mortevielle/ques.cpp2
5 files changed, 9 insertions, 0 deletions
diff --git a/engines/mortevielle/actions.cpp b/engines/mortevielle/actions.cpp
index 9c1a6b738c..7e5143328d 100644
--- a/engines/mortevielle/actions.cpp
+++ b/engines/mortevielle/actions.cpp
@@ -1053,6 +1053,8 @@ L2:
tou = '\0';
do {
mov_mouse(f, tou);
+ CHECK_QUIT;
+
/* if keypressed then read(kbd,tou);*/
read_pos_mouse(x, y, c);
x = x * (3 - res);
diff --git a/engines/mortevielle/alert.cpp b/engines/mortevielle/alert.cpp
index 6a380b2155..3895bad7fd 100644
--- a/engines/mortevielle/alert.cpp
+++ b/engines/mortevielle/alert.cpp
@@ -195,6 +195,8 @@ int do_alert(Common::String str_, int n) {
do {
dumi = '\377';
mov_mouse(dum, dumi);
+ CHECK_QUIT0;
+
cx = x_s;
cy = y_s;
test = (cy > 95) && (cy < 105);
diff --git a/engines/mortevielle/mor2.cpp b/engines/mortevielle/mor2.cpp
index 1c27ef3f04..10fe6e9937 100644
--- a/engines/mortevielle/mor2.cpp
+++ b/engines/mortevielle/mor2.cpp
@@ -628,6 +628,8 @@ void tfleche() {
do {
mov_mouse(qust, touch);
+ CHECK_QUIT;
+
if (g_vm->getMouseClick())
rect = (x_s < 256 * res) && (y_s < 176) && (y_s > 12);
tinke();
diff --git a/engines/mortevielle/mortevielle.h b/engines/mortevielle/mortevielle.h
index 4c755a1f5e..75aaeda580 100644
--- a/engines/mortevielle/mortevielle.h
+++ b/engines/mortevielle/mortevielle.h
@@ -85,6 +85,7 @@ public:
extern MortevielleEngine *g_vm;
#define CHECK_QUIT if (g_vm->shouldQuit()) { return; }
+#define CHECK_QUIT0 if (g_vm->shouldQuit()) { return 0; }
} // End of namespace Mortevielle
diff --git a/engines/mortevielle/ques.cpp b/engines/mortevielle/ques.cpp
index e7ae1b30ec..a223e4956f 100644
--- a/engines/mortevielle/ques.cpp
+++ b/engines/mortevielle/ques.cpp
@@ -109,6 +109,8 @@ namespace Mortevielle {
g_vm->setMouseClick(false);
tesok = false;
mov_mouse(func, key);
+ CHECK_QUIT0;
+
k = 1;
while (coor[k].etat && ! dans_rect(coor[k])) k = k + 1;
if (coor[k].etat) {