[Scummvm-cvs-logs] SF.net SVN: scummvm:[55107] scummvm/trunk/engines/hugo
sev at users.sourceforge.net
sev at users.sourceforge.net
Mon Jan 3 20:08:10 CET 2011
Revision: 55107
http://scummvm.svn.sourceforge.net/scummvm/?rev=55107&view=rev
Author: sev
Date: 2011-01-03 19:08:10 +0000 (Mon, 03 Jan 2011)
Log Message:
-----------
HUGO: Added stub for menu commands and implemented menu closing
Modified Paths:
--------------
scummvm/trunk/engines/hugo/menu.cpp
scummvm/trunk/engines/hugo/menu.h
Modified: scummvm/trunk/engines/hugo/menu.cpp
===================================================================
--- scummvm/trunk/engines/hugo/menu.cpp 2011-01-03 18:45:04 UTC (rev 55106)
+++ scummvm/trunk/engines/hugo/menu.cpp 2011-01-03 19:08:10 UTC (rev 55107)
@@ -166,4 +166,43 @@
}
}
+void TopMenu::handleCommand(GUI::CommandSender *sender, uint32 cmd, uint32 data) {
+ switch (cmd) {
+ case kCmdWhat:
+ close();
+ break;
+ case kCmdMusic:
+ close();
+ break;
+ case kCmdSoundFX:
+ close();
+ break;
+ case kCmdLoad:
+ close();
+ break;
+ case kCmdSave:
+ close();
+ break;
+ case kCmdRecall:
+ close();
+ break;
+ case kCmdTurbo:
+ close();
+ break;
+ case kCmdLook:
+ close();
+ break;
+ case kCmdInvent:
+ close();
+ break;
+ default:
+ Dialog::handleCommand(sender, cmd, data);
+ }
+}
+
+void TopMenu::handleMouseUp(int x, int y, int button, int clickCount) {
+ if (y > _h)
+ close();
+}
+
} // End of namespace Hugo
Modified: scummvm/trunk/engines/hugo/menu.h
===================================================================
--- scummvm/trunk/engines/hugo/menu.h 2011-01-03 18:45:04 UTC (rev 55106)
+++ scummvm/trunk/engines/hugo/menu.h 2011-01-03 19:08:10 UTC (rev 55107)
@@ -47,13 +47,9 @@
TopMenu(HugoEngine *vm);
void reflowLayout();
+ void handleCommand(GUI::CommandSender *sender, uint32 cmd, uint32 data);
+ void handleMouseUp(int x, int y, int button, int clickCount);
- /*
- void handleTickle();
- void handleMouseWheel(int x, int y, int direction);
- void handleKeyDown(Common::KeyState state);
- void handleCommand(CommandSender *sender, uint32 cmd, uint32 data);
- */
void loadBmpArr(Common::File &in);
protected:
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