dabo Commit
Revision 6204
Date: 2010-11-22 18:50:26 -0800 (Mon, 22 Nov 2010)
Author: Ed
Trac: http://trac.dabodev.com/changeset/6204
Changed:
U trunk/demo/samples/games/bubblet/BubbletForm.py
Log:
Fixed this to use the new menu item references instead of depending on the
caption text.
Diff:
Modified: trunk/demo/samples/games/bubblet/BubbletForm.py
===================================================================
--- trunk/demo/samples/games/bubblet/BubbletForm.py 2010-11-23 02:50:01 UTC
(rev 6203)
+++ trunk/demo/samples/games/bubblet/BubbletForm.py 2010-11-23 02:50:26 UTC
(rev 6204)
@@ -64,12 +64,10 @@
# Add the menu items
mb = self.MenuBar
- fm = mb.getMenu(_("File"))
- quitPos = fm.getItemIndex(_("Quit"))
+ fm = mb.fileMenu
+ quitItem = mb.quitMenuItem
+ quitPos = fm.getItemIndex(quitItem)
if quitPos is None:
- # Win/Lin
- quitPos = fm.getItemIndex(_("Exit"))
- if quitPos is None:
quitPos = len(fm.Children)
fm.insert(quitPos, _("&ScreenShot"), HotKey="Ctrl+S",
OnHit=self.saveScreenShot)
fm.insert(quitPos, _("&Reset Statistics"), HotKey="Ctrl+R",
OnHit=self.onResetStats)
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message:
http://leafe.com/archives/byMID/[email protected]