projects
/
wxWidgets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed comment bug [ 1390056 ] Wrong Documentation for TransferFromWindow
[wxWidgets.git]
/
wxPython
/
demo
/
Main.py
diff --git
a/wxPython/demo/Main.py
b/wxPython/demo/Main.py
index 27fc39e2312d8acc70b0efa7cae9ae3a9db72036..d0711e384f9a3206bd3a37cd5cead146872f94a3 100644
(file)
--- a/
wxPython/demo/Main.py
+++ b/
wxPython/demo/Main.py
@@
-50,6
+50,10
@@
_treeList = [
'FoldPanelBar',
'GIFAnimationCtrl',
'HyperLinkCtrl',
'FoldPanelBar',
'GIFAnimationCtrl',
'HyperLinkCtrl',
+ 'MultiSplitterWindow',
+ 'Throbber',
+ 'GetMouseState',
+ 'FloatCanvas',
]),
# managed windows == things with a (optional) caption you can close
]),
# managed windows == things with a (optional) caption you can close
@@
-80,7
+84,6
@@
_treeList = [
# dialogs from libraries
('More Dialogs', [
'ImageBrowser',
# dialogs from libraries
('More Dialogs', [
'ImageBrowser',
- 'MultipleChoiceDialog',
'ScrolledMessageDialog',
]),
'ScrolledMessageDialog',
]),
@@
-159,11
+162,11
@@
_treeList = [
'HtmlWindow',
'HyperLinkCtrl',
'IntCtrl',
'HtmlWindow',
'HyperLinkCtrl',
'IntCtrl',
- 'MediaCtrl',
'MVCTree',
'MaskedEditControls',
'MaskedNumCtrl',
'MVCTree',
'MaskedEditControls',
'MaskedNumCtrl',
- 'MimeTypesManager',
+ 'MediaCtrl',
+ 'MultiSplitterWindow',
'PyCrust',
'PyPlot',
'PyShell',
'PyCrust',
'PyPlot',
'PyShell',
@@
-230,7
+233,9
@@
_treeList = [
'DrawXXXList',
'FileHistory',
'FontEnumerator',
'DrawXXXList',
'FileHistory',
'FontEnumerator',
+ 'GLCanvas',
'Joystick',
'Joystick',
+ 'MimeTypesManager',
'MouseGestures',
'OGL',
'PrintFramework',
'MouseGestures',
'OGL',
'PrintFramework',
@@
-240,11
+245,6
@@
_treeList = [
'Unicode',
]),
'Unicode',
]),
- # need libs not coming with the demo
- ('Samples using an external library', [
- 'GLCanvas',
- ]),
-
('Check out the samples dir too', [
]),
('Check out the samples dir too', [
]),
@@
-801,7
+801,8
@@
class DemoModules:
def LoadDict(self, modID):
if self.name != __name__:
source = self.modules[modID][1]
def LoadDict(self, modID):
if self.name != __name__:
source = self.modules[modID][1]
- description = self.modules[modID][3]
+ #description = self.modules[modID][3]
+ description = self.modules[modID][2]
try:
self.modules[modID][0] = {}
try:
self.modules[modID][0] = {}
@@
-937,7
+938,7
@@
class DemoErrorPanel(wx.Panel):
self.box = wx.BoxSizer(wx.VERTICAL)
# Main Label
self.box = wx.BoxSizer(wx.VERTICAL)
# Main Label
- self.box.Add(wx.StaticText(self, -1, "An error has occured while trying to run the demo")
+ self.box.Add(wx.StaticText(self, -1, "An error has occur
r
ed while trying to run the demo")
, 0, wx.ALIGN_CENTER | wx.TOP, 10)
# Exception Information
, 0, wx.ALIGN_CENTER | wx.TOP, 10)
# Exception Information
@@
-1209,6
+1210,7
@@
class wxPythonDemo(wx.Frame):
self.SetMenuBar(self.mainmenu)
self.finddata = wx.FindReplaceData()
self.SetMenuBar(self.mainmenu)
self.finddata = wx.FindReplaceData()
+ self.finddata.SetFlags(wx.FR_DOWN)
if 0:
# This is another way to set Accelerators, in addition to
if 0:
# This is another way to set Accelerators, in addition to
@@
-1404,7
+1406,7
@@
class wxPythonDemo(wx.Frame):
# o The RunTest() for all samples must now return a window that can
# be palced in a tab in the main notebook.
# o The RunTest() for all samples must now return a window that can
# be palced in a tab in the main notebook.
- # o If an error occurs (or has occured before) an error tab is created.
+ # o If an error occurs (or has occur
r
ed before) an error tab is created.
if module is not None:
wx.LogMessage("Running demo module...")
if module is not None:
wx.LogMessage("Running demo module...")
@@
-1526,9
+1528,7
@@
class wxPythonDemo(wx.Frame):
self.nb.SetSelection(1)
self.finddlg = wx.FindReplaceDialog(self, self.finddata, "Find",
self.nb.SetSelection(1)
self.finddlg = wx.FindReplaceDialog(self, self.finddata, "Find",
- wx.FR_NOUPDOWN |
- wx.FR_NOMATCHCASE |
- wx.FR_NOWHOLEWORD)
+ wx.FR_NOMATCHCASE | wx.FR_NOWHOLEWORD)
self.finddlg.Show(True)
self.finddlg.Show(True)
@@
-1541,13
+1541,22
@@
class wxPythonDemo(wx.Frame):
self.nb.SetSelection(1)
end = editor.GetLastPosition()
textstring = editor.GetRange(0, end).lower()
self.nb.SetSelection(1)
end = editor.GetLastPosition()
textstring = editor.GetRange(0, end).lower()
- start = editor.GetSelection()[1]
findstring = self.finddata.GetFindString().lower()
findstring = self.finddata.GetFindString().lower()
- loc = textstring.find(findstring, start)
+ backward = not (self.finddata.GetFlags() & wx.FR_DOWN)
+ if backward:
+ start = editor.GetSelection()[0]
+ loc = textstring.rfind(findstring, 0, start)
+ else:
+ start = editor.GetSelection()[1]
+ loc = textstring.find(findstring, start)
if loc == -1 and start != 0:
# string not found, start at beginning
if loc == -1 and start != 0:
# string not found, start at beginning
- start = 0
- loc = textstring.find(findstring, start)
+ if backward:
+ start = end
+ loc = textstring.rfind(findstring, 0, start)
+ else:
+ start = 0
+ loc = textstring.find(findstring, start)
if loc == -1:
dlg = wx.MessageDialog(self, 'Find String Not Found',
'Find String Not Found in Demo File',
if loc == -1:
dlg = wx.MessageDialog(self, 'Find String Not Found',
'Find String Not Found in Demo File',