--- nfo/projects/netfraggle/bin/fraggleViewport.py 2004/08/25 21:40:54 1.6 +++ nfo/projects/netfraggle/bin/fraggleViewport.py 2004/08/25 23:46:05 1.8 @@ -5,6 +5,7 @@ import fraggleDialogPrefs import fraggleCtlPreferences +import fraggleDialogs def create(parent): return fraggleViewport(parent) @@ -14,6 +15,9 @@ [wxID_FRAGGLEVIEWPORTMENU1FPREFS, wxID_FRAGGLEVIEWPORTMENU1ITEMS1, ] = map(lambda _init_coll_menu1_Items: wxNewId(), range(2)) +[wxID_FRAGGLEVIEWPORTMENU2CONT, wxID_FRAGGLEVIEWPORTMENU2ABOUT, +] = map(lambda _init_coll_menu1_Items: wxNewId(), range(2)) + class fraggleViewport(wxMDIParentFrame): def _init_coll_menu1_Items(self, parent): # generated method, don't edit @@ -28,10 +32,24 @@ EVT_MENU(self, wxID_FRAGGLEVIEWPORTMENU1FPREFS, self.OnMenu1items0Menu) EVT_MENU(self, wxID_FRAGGLEVIEWPORTMENU1ITEMS1, self.OnMenu1items1Menu) + def _init_coll_menu2_Items(self, parent): + # generated method, don't edit + + parent.Append(helpString='Contents', + id=wxID_FRAGGLEVIEWPORTMENU2CONT, item='Contents', + kind=wxITEM_NORMAL) + parent.Append(helpString='About', + id=wxID_FRAGGLEVIEWPORTMENU2ABOUT, item='About', + kind=wxITEM_NORMAL) + + EVT_MENU(self, wxID_FRAGGLEVIEWPORTMENU2CONT, self.OnMenu2items0Menu) + EVT_MENU(self, wxID_FRAGGLEVIEWPORTMENU2ABOUT, self.OnMenu2items1Menu) + def _init_coll_menuBar1_Menus(self, parent): # generated method, don't edit - parent.Append(menu=self.menu1, title='File') + parent.Append(menu=self.menu1, title='&File') + parent.Append(menu=self.menu2, title='&help') def _init_utils(self): # generated method, don't edit @@ -40,6 +58,8 @@ self.menu1 = wxMenu(title='') self._init_coll_menu1_Items(self.menu1) + self.menu2 = wxMenu(title='') + self._init_coll_menu2_Items(self.menu2) self._init_coll_menuBar1_Menus(self.menuBar1) @@ -76,3 +96,16 @@ self.Destroy() event.Skip() + + def OnMenu2items0Menu(self, event): + try: + self.dialogPrefs.ShowModal() + finally: + pass + event.Skip() + + def OnMenu2items1Menu(self, event): + #self.Destroy() + #event.Skip() + fraggleDialogs.AboutDialog() +