Typos fixed and other tweaks

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@20516 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2003-05-07 00:55:07 +00:00
parent 2f511ce8d0
commit f632c16831
6 changed files with 21 additions and 8 deletions

View File

@@ -81,6 +81,8 @@ check the source for this sample to see how to implement them.
self.SetMenuBar(menuBar)
# Menu events
EVT_MENU_HIGHLIGHT_ALL(self, self.OnMenuHighlight)
EVT_MENU(self, 101, self.Menu101)
EVT_MENU(self, 102, self.Menu102)
EVT_MENU(self, 103, self.Menu103)
@@ -105,8 +107,19 @@ check the source for this sample to see how to implement them.
EVT_MENU(self, 503, self.TestRemove)
EVT_MENU(self, 505, self.TestRemove2)
# Methods
def OnMenuHighlight(self, event):
# Show how to get menu item imfo from this event handler
id = event.GetMenuId()
item = self.GetMenuBar().FindItemById(id)
text = item.GetText()
help = item.GetHelp()
#print text, help
event.Skip() # but in this case just call Skip so the default is done
def Menu101(self, event):
self.log.write('Welcome to Mercury\n')