More updates from Morgan Hua

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@33956 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2005-05-05 00:10:29 +00:00
parent 123dc137d3
commit b792147db7
17 changed files with 745 additions and 422 deletions

View File

@@ -97,19 +97,11 @@ class FindService(wx.lib.pydocview.DocService):
def ProcessUpdateUIEvent(self, event):
id = event.GetId()
if id == FindService.FIND_ID:
event.Enable(False)
return True
elif id == FindService.FIND_PREVIOUS_ID:
event.Enable(False)
return True
elif id == FindService.FIND_NEXT_ID:
event.Enable(False)
return True
elif id == FindService.REPLACE_ID:
event.Enable(False)
return True
elif id == FindService.GOTO_LINE_ID:
if (id == FindService.FIND_ID
or id == FindService.FIND_PREVIOUS_ID
or id == FindService.FIND_NEXT_ID
or id == FindService.REPLACE_ID
or id == FindService.GOTO_LINE_ID):
event.Enable(False)
return True
else:
@@ -362,7 +354,7 @@ class FindDialog(wx.Dialog):
findBtn = wx.Button(self, FindService.FINDONE_ID, _("Find Next"))
findBtn.SetDefault()
wx.EVT_BUTTON(self, FindService.FINDONE_ID, self.OnActionEvent)
cancelBtn = wx.Button(self, wx.ID_CANCEL, _("Cancel"))
cancelBtn = wx.Button(self, wx.ID_CANCEL)
wx.EVT_BUTTON(self, wx.ID_CANCEL, self.OnClose)
buttonSizer.Add(findBtn, 0, wx.BOTTOM, HALF_SPACE)
buttonSizer.Add(cancelBtn, 0)
@@ -457,7 +449,7 @@ class FindReplaceDialog(FindDialog):
findBtn = wx.Button(self, FindService.FINDONE_ID, _("Find Next"))
findBtn.SetDefault()
wx.EVT_BUTTON(self, FindService.FINDONE_ID, self.OnActionEvent)
cancelBtn = wx.Button(self, wx.ID_CANCEL, _("Cancel"))
cancelBtn = wx.Button(self, wx.ID_CANCEL)
wx.EVT_BUTTON(self, wx.ID_CANCEL, self.OnClose)
replaceBtn = wx.Button(self, FindService.REPLACEONE_ID, _("Replace"))
wx.EVT_BUTTON(self, FindService.REPLACEONE_ID, self.OnActionEvent)

View File

@@ -7,7 +7,7 @@
# Created: 8/15/03
# CVS-ID: $Id$
# Copyright: (c) 2003-2005 ActiveGrid, Inc.
# License: ASL 2.0 http://apache.org/licenses/LICENSE-2.0
# License: wxWindows License
#----------------------------------------------------------------------------
import wx
import wx.lib.docview