]> git.saurik.com Git - wxWidgets.git/commitdiff
testing for top-level objects only
authorRoman Rolinsky <rolinsky@femagsoft.com>
Fri, 9 Sep 2005 09:35:07 +0000 (09:35 +0000)
committerRoman Rolinsky <rolinsky@femagsoft.com>
Fri, 9 Sep 2005 09:35:07 +0000 (09:35 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35441 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/wx/tools/XRCed/CHANGES.txt
wxPython/wx/tools/XRCed/tree.py

index 0e6603c071dfaa8933cc263f74f296558000a40b..99c5cc8f0a3bfef99bafb1cd80cd096d141cfb75 100644 (file)
@@ -1,3 +1,9 @@
+0.1.6-5
+-------
+
+Testing limited to top-level objects because of references
+problem until a nice solution is found.
+
 0.1.6-4
 -------
 
index 55bbca94b5a8fa3f09b13fe158f07814eb45def4..408c8fb5721f4ddc76b646879856c2ea356d5dd3 100644 (file)
@@ -719,6 +719,9 @@ class XML_Tree(wxTreeCtrl):
         if g.panel.IsModified():
             self.Apply(xxx, item)       # apply changes
         treeObj = xxx.treeObject()
+        if self.GetItemParent(item) != self.root:
+            wxLogMessage('Only top-level objects can be tested')
+            return
         if treeObj.className not in ['wxFrame', 'wxPanel', 'wxDialog',
                                      'wxMenuBar', 'wxToolBar', 'wxWizard',
                                      'wxWizardPageSimple']:
@@ -810,7 +813,6 @@ class XML_Tree(wxTreeCtrl):
         next = elem.nextSibling
         encd = self.rootObj.params['encoding'].value()
         if not encd: encd = None
-        self.dom.writexml(open('ttt.xrc','w'), encoding=encd)
         self.dom.writexml(memFile, encoding=encd)
         # Put back in place
         # Remove temporary name or restore changed