[Scummvm-cvs-logs] SF.net SVN: scummvm:[34281] scummvm/trunk/backends/events/default/ default-events.cpp
lordhoto at users.sourceforge.net
lordhoto at users.sourceforge.net
Tue Sep 2 15:27:27 CEST 2008
Revision: 34281
http://scummvm.svn.sourceforge.net/scummvm/?rev=34281&view=rev
Author: lordhoto
Date: 2008-09-02 13:27:26 +0000 (Tue, 02 Sep 2008)
Log Message:
-----------
Applied my patch from -devel, which reenables GMM opening via F6.
Modified Paths:
--------------
scummvm/trunk/backends/events/default/default-events.cpp
Modified: scummvm/trunk/backends/events/default/default-events.cpp
===================================================================
--- scummvm/trunk/backends/events/default/default-events.cpp 2008-09-02 13:22:12 UTC (rev 34280)
+++ scummvm/trunk/backends/events/default/default-events.cpp 2008-09-02 13:27:26 UTC (rev 34281)
@@ -393,7 +393,7 @@
#endif
// Global Main Menu
// FIXME: F6 is not the best trigger, it conflicts with some games!!!
- if (event.kbd.keycode == Common::KEYCODE_F6)
+ if (event.kbd.keycode == Common::KEYCODE_F6) {
if (g_engine && !g_engine->isPaused()) {
Common::Event menuEvent;
menuEvent.type = Common::EVENT_MAINMENU;
@@ -409,7 +409,21 @@
//pushEvent(menuEvent);
event = menuEvent;
+
+ // FIXME: Since now we do not push another MAINMENU event onto
+ // our event stack, the GMM would never open, so we have to do
+ // that here. Of course when the engine would handle MAINMENU
+ // as an event now and open up the GMM itself it would open the
+ // menu twice.
+ if (g_engine && !g_engine->isPaused())
+ g_engine->mainMenuDialog();
+
+ if (_shouldQuit)
+ event.type = Common::EVENT_QUIT;
+ else if (_shouldRTL)
+ event.type = Common::EVENT_RTL;
}
+ }
break;
case Common::EVENT_KEYUP:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list