From aba6b02b5b2bf7cb822e2d35023d2927622d007f Mon Sep 17 00:00:00 2001 From: Strangerke Date: Fri, 11 Oct 2013 08:10:43 +0200 Subject: AVALANCHE: Fix two blocking loops not checking shouldQuit() --- engines/avalanche/menu.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/avalanche') diff --git a/engines/avalanche/menu.cpp b/engines/avalanche/menu.cpp index 1f7006a424..f722b128cc 100644 --- a/engines/avalanche/menu.cpp +++ b/engines/avalanche/menu.cpp @@ -676,7 +676,7 @@ void Menu::update() { // TODO: Optimize it ASAP!!! It really needs it... _menuBar.chooseMenuItem(cursorPos.x); do _vm->updateEvents(); - while (_vm->_holdLeftMouse); + while (_vm->_holdLeftMouse && !_vm->shouldQuit()); while (!_vm->shouldQuit()) { do { @@ -698,7 +698,7 @@ void Menu::update() { // TODO: Optimize it ASAP!!! It really needs it... _activeMenuItem.lightUp(cursorPos); _vm->_graphics->refreshScreen(); - } while (!_vm->_holdLeftMouse); + } while (!_vm->_holdLeftMouse && !_vm->shouldQuit()); if (_vm->_holdLeftMouse) { if (cursorPos.y > 21) { -- cgit v1.2.3