diff options
author | Eugene Sandulenko | 2019-12-16 14:21:11 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2019-12-16 14:21:11 +0100 |
commit | 9f789b4bde4556636f25f3b1dfd0b859b47ede28 (patch) | |
tree | 9e797533ea50f6ccf70fadf296529a8ddf40e009 /graphics | |
parent | 4c3cea846bf9997ff146d92f64f5d1f1ed57cb69 (diff) | |
download | scummvm-rg350-9f789b4bde4556636f25f3b1dfd0b859b47ede28.tar.gz scummvm-rg350-9f789b4bde4556636f25f3b1dfd0b859b47ede28.tar.bz2 scummvm-rg350-9f789b4bde4556636f25f3b1dfd0b859b47ede28.zip |
GRAPHICS: MACGUI: Optimized drawing of MacMenu
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/macgui/macmenu.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/graphics/macgui/macmenu.cpp b/graphics/macgui/macmenu.cpp index e7ed416893..f98bdadeb2 100644 --- a/graphics/macgui/macmenu.cpp +++ b/graphics/macgui/macmenu.cpp @@ -977,8 +977,10 @@ bool MacMenu::mouseClick(int x, int y) { _contentIsDirty = true; _wm->setFullRefresh(true); - if (_wm->_mode & kWMModalMenuMode) + if (_wm->_mode & kWMModalMenuMode) { + draw(_wm->_screen); eventLoop(); + } return true; } @@ -1124,7 +1126,7 @@ bool MacMenu::mouseRelease(int x, int y) { _activeSubItem = -1; _menustack.clear(); - _wm->setFullRefresh(true); + _wm->setFullRefresh((_wm->_mode & kWMModalMenuMode) ? false : true); return true; } @@ -1233,8 +1235,10 @@ void MacMenu::eventLoop() { draw(_wm->_screen); } - g_system->updateScreen(); - g_system->delayMillis(10); + if (_menuActivated) { + g_system->updateScreen(); + g_system->delayMillis(10); + } } } |