[Zope-Checkins] CVS: Zope/lib/python/ZTUtils - SimpleTree.py:1.3.6.1 Tree.py:1.6.6.1

Martijn Pieters mj@zope.com
Thu, 3 Oct 2002 17:09:15 -0400


Update of /cvs-repository/Zope/lib/python/ZTUtils
In directory cvs.zope.org:/tmp/cvs-serv11653/lib/python/ZTUtils

Modified Files:
      Tag: Zope-2_6-branch
	SimpleTree.py Tree.py 
Log Message:
Merge ZTUtils tree fices from trunk, and add appropriate changelog.


=== Zope/lib/python/ZTUtils/SimpleTree.py 1.3 => 1.3.6.1 ===
--- Zope/lib/python/ZTUtils/SimpleTree.py:1.3	Wed Aug 14 18:10:12 2002
+++ Zope/lib/python/ZTUtils/SimpleTree.py	Thu Oct  3 17:09:14 2002
@@ -52,6 +52,9 @@
         node.id = b2a(self.getId(object))
         return node
 
-    def markRoot(self, node):
-        node.tree_pre = self.tree_pre
-        node.baseURL = node.object.REQUEST['BASEPATH1']
+    def tree(self, root, expanded=None, subtree=0):
+        node = TreeMaker.tree(self, root, expanded, subtree)
+        if not subtree:
+            node.tree_pre = self.tree_pre
+            node.baseURL = root.REQUEST['BASEPATH1']
+        return node


=== Zope/lib/python/ZTUtils/Tree.py 1.6 => 1.6.6.1 ===
--- Zope/lib/python/ZTUtils/Tree.py:1.6	Wed Aug 14 18:10:12 2002
+++ Zope/lib/python/ZTUtils/Tree.py	Thu Oct  3 17:09:14 2002
@@ -106,8 +106,6 @@
             node.state = -1 # collapsed
         if not subtree:
             node.depth = 0
-            if hasattr(self, 'markRoot'):
-                self.markRoot(node)
         return node
 
     def node(self, object):
@@ -143,8 +141,8 @@
                            type(0L):1, type(None):1 }.has_key):
     return is_simple(type(ob))
 
-def aqcallback(self, inst, parent, name, value, filter):
-    return filter(self, inst, parent, name, value)
+def aqcallback(self, inst, name, value, filter):
+    return filter(self, inst, name, value)
 
 from binascii import b2a_base64, a2b_base64
 from string import translate, maketrans