712 def OnActivated(self, event): |
712 def OnActivated(self, event): |
713 if event.GetActive(): |
713 if event.GetActive(): |
714 wx.CallAfter(self._Refresh, TITLE, EDITORTOOLBAR, FILEMENU, EDITMENU, DISPLAYMENU) |
714 wx.CallAfter(self._Refresh, TITLE, EDITORTOOLBAR, FILEMENU, EDITMENU, DISPLAYMENU) |
715 event.Skip() |
715 event.Skip() |
716 |
716 |
|
717 def SelectTab(self, tab): |
|
718 for notebook in [self.LeftNoteBook, self.BottomNoteBook, self.RightNoteBook]: |
|
719 idx = notebook.GetPageIndex(tab) |
|
720 if idx != wx.NOT_FOUND: |
|
721 notebook.SetSelection(idx) |
|
722 return |
|
723 |
717 #------------------------------------------------------------------------------- |
724 #------------------------------------------------------------------------------- |
718 # Saving and restoring frame organization functions |
725 # Saving and restoring frame organization functions |
719 #------------------------------------------------------------------------------- |
726 #------------------------------------------------------------------------------- |
720 |
727 |
721 def GetTabInfos(self, tab): |
728 def GetTabInfos(self, tab): |
1232 if dialog.ShowModal() == wx.ID_OK: |
1239 if dialog.ShowModal() == wx.ID_OK: |
1233 criteria = dialog.GetCriteria() |
1240 criteria = dialog.GetCriteria() |
1234 result = self.Controler.SearchInProject(criteria) |
1241 result = self.Controler.SearchInProject(criteria) |
1235 self.ClearSearchResults() |
1242 self.ClearSearchResults() |
1236 self.SearchResultPanel.SetSearchResults(criteria, result) |
1243 self.SearchResultPanel.SetSearchResults(criteria, result) |
1237 self.BottomNoteBook.SetSelection(self.BottomNoteBook.GetPageIndex(self.SearchResultPanel)) |
1244 self.SelectTab(self.SearchResultPanel) |
1238 |
1245 |
1239 #------------------------------------------------------------------------------- |
1246 #------------------------------------------------------------------------------- |
1240 # Display Menu Functions |
1247 # Display Menu Functions |
1241 #------------------------------------------------------------------------------- |
1248 #------------------------------------------------------------------------------- |
1242 |
1249 |