]> git.saurik.com Git - wxWidgets.git/commitdiff
some bugs in the demo fixed
authorRobin Dunn <robin@alldunn.com>
Fri, 22 Apr 2005 14:30:03 +0000 (14:30 +0000)
committerRobin Dunn <robin@alldunn.com>
Fri, 22 Apr 2005 14:30:03 +0000 (14:30 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@33826 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/demo/SplitTree.py
wxPython/demo/TreeCtrl.py

index 0a73acdacbdbe9e6c179671b5957468c99b8b1b8..0f7b4da9e4db647624a6ef6e0242c4557ef3144a 100644 (file)
@@ -105,7 +105,7 @@ class TestPanel(wx.Panel):
 
         valueWindow = TestValueWindow(splitter, style=wx.NO_BORDER)
 
-        splitter.SplitVertically(tree, valueWindow, 150)
+        wx.CallAfter(splitter.SplitVertically, tree, valueWindow, 150)
         scroller.SetTargetWindow(tree)
         scroller.EnableScrolling(False, False)
 
index 13137d648d4f94c106d328f4c8f476dc73a646d7..f36a659521a7faf104a3aece41f2fec2ea39c394 100644 (file)
@@ -146,7 +146,8 @@ class TestTreeCtrlPanel(wx.Panel):
         if item:
             self.log.WriteText("OnLeftDClick: %s\n" % self.tree.GetItemText(item))
             parent = self.tree.GetItemParent(item)
-            self.tree.SortChildren(parent)
+            if parent.IsOk():
+                self.tree.SortChildren(parent)
         event.Skip()