X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9b3d3bc44bee290fc5b34279adb60156f28689d3..294d195c3cfd9b39b8e1855e9a89dba86bef0082:/utils/wxPython/demo/Main.py diff --git a/utils/wxPython/demo/Main.py b/utils/wxPython/demo/Main.py index 1030ed5d73..b94fd77952 100644 --- a/utils/wxPython/demo/Main.py +++ b/utils/wxPython/demo/Main.py @@ -21,9 +21,7 @@ _useSplitter = true _useNestedSplitter = true _treeList = [ - ('New since last release', ['wxMVCTree', 'wxVTKRenderWindow', - 'FileBrowseButton', 'GenericButtons', - 'wxMask']), + ('New since last release', []), ('Managed Windows', ['wxFrame', 'wxDialog', 'wxMiniFrame']), @@ -53,7 +51,7 @@ _treeList = [ ('wxPython Library', ['Layoutf', 'wxScrolledMessageDialog', 'wxMultipleChoiceDialog', 'wxPlotCanvas', 'wxFloatBar', 'PyShell', 'wxCalendar', 'wxMVCTree', 'wxVTKRenderWindow', - 'FileBrowseButton', 'GenericButtons']), + 'FileBrowseButton', 'GenericButtons', 'wxEditor']), ('Cool Contribs', ['pyTree', 'hangman', 'SlashDot', 'XMLtreeview']), @@ -137,6 +135,7 @@ class wxPythonDemo(wxFrame): tID = wxNewId() self.treeMap = {} self.tree = wxTreeCtrl(splitter, tID) + #self.tree.SetBackgroundColour(wxNamedColour("Pink")) root = self.tree.AddRoot("Overview") firstChild = None for item in _treeList: @@ -274,11 +273,8 @@ class wxPythonDemo(wxFrame): self.window = module.runTest(self, self.nb, self) if self.window: self.nb.AddPage(self.window, 'Demo') - #self.nb.ResizeChildren() + wxYield() self.nb.SetSelection(2) - #self.nb.ResizeChildren() - #if self.window.GetAutoLayout(): - # self.window.Layout() else: self.ovr.Clear() @@ -382,6 +378,11 @@ class MyApp(wxApp): #--------------------------------------------------------------------------- def main(): + try: + demoPath = os.path.split(__file__)[0] + os.chdir(demoPath) + except: + pass app = MyApp(0) app.MainLoop()