[Zope3-checkins] SVN: Zope3/trunk/ Bring back the xmltree with
virtual host support
Roger Ineichen
roger at projekt01.ch
Wed Mar 23 22:01:44 EST 2005
Log message for revision 29656:
Bring back the xmltree with virtual host support
Added tests for virtual host
Register the StaticTree skin again as a alternative skin for older browser without XMLHttp support
Changed:
U Zope3/trunk/doc/TODO.txt
U Zope3/trunk/src/zope/app/rotterdam/configure.zcml
D Zope3/trunk/src/zope/app/rotterdam/navigation_macros_tablelayout.pt
U Zope3/trunk/src/zope/app/rotterdam/tests/output/test1.xml
U Zope3/trunk/src/zope/app/rotterdam/tests/output/test5.xml
A Zope3/trunk/src/zope/app/rotterdam/tests/output/test6.xml
A Zope3/trunk/src/zope/app/rotterdam/tests/output/test7.xml
A Zope3/trunk/src/zope/app/rotterdam/tests/output/test8.xml
U Zope3/trunk/src/zope/app/rotterdam/tests/test_xmlnavigationviews.py
U Zope3/trunk/src/zope/app/rotterdam/xmlobject.py
U Zope3/trunk/src/zope/app/rotterdam/xmltree.js
U Zope3/trunk/src/zope/app/rotterdam/zope3_tablelayout.css
U Zope3/trunk/src/zope/app/tree/browser/configure.zcml
U Zope3/trunk/src/zope/app/tree/browser/navigation_macros.pt
-=-
Modified: Zope3/trunk/doc/TODO.txt
===================================================================
--- Zope3/trunk/doc/TODO.txt 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/doc/TODO.txt 2005-03-24 03:01:44 UTC (rev 29656)
@@ -103,13 +103,21 @@
issue for Metadata, I think the Metadata views should also make use
of the form framwork, there are still implemented as normal pages.
-216: Close this issue, the preview is working correctly.
+216: Close or reject this issue, the preview is working correctly. We need a
+ presentation skin for to fix this. It's not possible to use the index.html
+ views as a enduser UI without the ZMI. If somebody don't think so, take a
+ look at the index.html for images or files. There is no way right now
+ to use index.html views in the Rotterdam skin with only zope.View permissions
+ on objects.
+ This is a feature not a issue and needs a additional presentation skin.
243: This seems a old issue which was done for the 3.0 release, ri
-328 + 333: Replaced the xmltree with the static tree, don't close
- this is only not relevant for the 3.1 release since we use the
- static tree, ri
+288: I think we can ignore this issue since we don't know in which browser
+ this happen, ri
+328: Added virtual host support to the xml tree. Paul and Godefroid
+ will fix the issue 333, ri
+
378: It's not a bug, he just tries to use a Object field without the
CustomWidgetFactory, ri
Modified: Zope3/trunk/src/zope/app/rotterdam/configure.zcml
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/configure.zcml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/configure.zcml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -72,22 +72,6 @@
file="mi.gif"
layer="zope.app.rotterdam.rotterdam" />
- <browser:pages
- for="zope.app.container.interfaces.IReadContainer"
- permission="zope.View"
- class=".xmlobject.ReadContainerXmlObjectView">
- <browser:page name="children.xml" attribute="children" />
- <browser:page name="singleBranchTree.xml" attribute="singleBranchTree" />
- </browser:pages>
-
- <browser:page
- name="singleBranchTree.xml"
- for="zope.interface.interface.Interface"
- permission="zope.View"
- class=".xmlobject.XmlObjectView"
- attribute="singleBranchTree"
- />
-
<!-- below overrides the standard_macros by Rotterdam Skin -->
<browser:page
for="*"
@@ -97,20 +81,12 @@
layer="zope.app.rotterdam.rotterdam"
allowed_interface="zope.interface.common.mapping.IItemMapping"
/>
- <!-- use a table driven layout since the left navigation is cuts long names
+
<browser:page
for="*"
name="skin_macros"
permission="zope.View"
layer="zope.app.rotterdam.rotterdam"
- template="template.pt"
- />
- -->
- <browser:page
- for="*"
- name="skin_macros"
- permission="zope.View"
- layer="zope.app.rotterdam.rotterdam"
template="template_tablelayout.pt"
/>
@@ -128,23 +104,45 @@
layer="zope.app.rotterdam.rotterdam"
template="dialog_macros.pt" />
- <!-- use the static tree since the xmltree has to many issues -->
<browser:page
for="*"
- name="navigation_macros"
+ name="popup_macros"
permission="zope.View"
layer="zope.app.rotterdam.rotterdam"
- template="navigation_macros_tablelayout.pt"
+ template="popup_macros.pt"
/>
-
+
+ <!-- xmltree navigation -->
<browser:page
for="*"
- name="popup_macros"
+ name="navigation_macros"
permission="zope.View"
layer="zope.app.rotterdam.rotterdam"
- template="popup_macros.pt"
+ template="navigation_macros.pt"
/>
+ <browser:pages
+ for="zope.app.container.interfaces.IReadContainer"
+ permission="zope.View"
+ class=".xmlobject.ReadContainerXmlObjectView">
+ <browser:page
+ name="children.xml"
+ attribute="children"
+ />
+ <browser:page
+ name="singleBranchTree.xml"
+ attribute="singleBranchTree"
+ />
+ </browser:pages>
+
+ <browser:page
+ name="singleBranchTree.xml"
+ for="zope.interface.interface.Interface"
+ permission="zope.View"
+ class=".xmlobject.XmlObjectView"
+ attribute="singleBranchTree"
+ />
+
<browser:view
for="zope.schema.interfaces.ISourceText"
provides="zope.app.form.interfaces.IInputWidget"
Deleted: Zope3/trunk/src/zope/app/rotterdam/navigation_macros_tablelayout.pt
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/navigation_macros_tablelayout.pt 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/navigation_macros_tablelayout.pt 2005-03-24 03:01:44 UTC (rev 29656)
@@ -1,98 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"
- i18n:domain="zope">
-<body>
-
- <!-- Java scripts for the navigation tree - none! -->
-
- <metal:tree define-macro="navigation_tree_js">
- </metal:tree>
-
- <!-- Box containing the actual navigation tree -->
-
- <metal:tree define-macro="navigation_tree_box">
- <div class="box" id="navigationTree">
- <h4 i18n:translate="">Navigation</h4>
- <div class="treebody">
-<tal:block define="root context/@@virtualhost_cookie_tree;
- result root/getFlatDicts;
- nodeDictList python:result[0];
- maxDepth python:result[1]">
-
-<table cellspacing="0" cellpadding="0">
-<tr>
- <td width="16">
- <img src="" tal:define="icon root/context/@@zmi_icon | nothing"
- tal:replace="structure icon" />
- </td>
- <td class="list-item"
- tal:attributes="colspan python:maxDepth+2">
- <a href=""
- tal:attributes="href
- string:${root/context/@@absolute_url}/@@SelectedManagementView.html"
- tal:content="root/getId() | string:[top]"></a>
- </td>
-</tr>
-</table>
-
-<table cellspacing="0" cellpadding="0" tal:repeat="nodeInfo nodeDictList">
-<tr tal:define="node nodeInfo/node">
- <td style="width:16px" tal:repeat="state nodeInfo/row-state">
- <img tal:attributes="src context/++resource++tree_images/vline.png"
- tal:condition="state" alt="|" border="0" />
- <img src="" width="16" height="16"
- tal:condition="not:state"
- tal:attributes="src context/++resource++tree_images/shim.gif" />
- </td>
- <td style="width:16px">
- <a href=""
- tal:attributes="href string:/?tree-state=${nodeInfo/tree-state}"
- tal:condition="node/hasChildren">
- <tal:block condition="not:nodeInfo/last-level-node">
- <img tal:attributes="src context/++resource++tree_images/plus_vline.png"
- tal:condition="not:node/expanded" alt="+" border="0" />
- <img tal:attributes="src context/++resource++tree_images/minus_vline.png"
- tal:condition="node/expanded" alt="-" border="0" />
- </tal:block>
- <tal:block condition="nodeInfo/last-level-node">
- <img tal:attributes="src context/++resource++tree_images/plus.png"
- tal:condition="not:node/expanded" alt="+" border="0" />
- <img tal:attributes="src context/++resource++tree_images/minus.png"
- tal:condition="node/expanded" alt="-" border="0" />
- </tal:block>
- </a>
- <tal:block condition="not:node/hasChildren">
- <img tal:attributes="src context/++resource++tree_images/tline.png"
- tal:condition="not:nodeInfo/last-level-node" alt="" border="0" />
- <img tal:attributes="src context/++resource++tree_images/lline.png"
- tal:condition="nodeInfo/last-level-node" alt="" border="0" />
- </tal:block>
- </td>
-
- <td align="left" style="width:16px"
- tal:define="object nocall:node/context;
- icon object/@@zmi_icon | nothing">
- <img src="" tal:replace="structure icon" />
- <img src="" width="16" height="16"
- tal:condition="not:icon"
- tal:attributes="src context/++resource++tree_images/shim.gif" />
- </td>
-
- <td class="list-item"
- tal:attributes="colspan python:maxDepth-len(nodeInfo['row-state'])+1">
- <a href=""
- tal:attributes="href
- string:${node/context/@@absolute_url}/@@SelectedManagementView.html"
- tal:content="node/context/zope:name">
- node/id
- </a>
- </td>
-</tr>
-</table>
-</tal:block>
-
- </div>
- </div>
- </metal:tree>
-</body>
-</html>
Modified: Zope3/trunk/src/zope/app/rotterdam/tests/output/test1.xml
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/tests/output/test1.xml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/tests/output/test1.xml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -1 +1 @@
-<?xml version="1.0" ?><children><collection name="" length="2" icon_url="" isroot=""><collection name="folder1" length="2" icon_url=""></collection><collection name="folder2" length="1" icon_url=""/><collection name="++etc++site" length="1" icon_url=""/></collection></children>
+<?xml version="1.0" ?><children><collection name="[top]" baseURL="http://127.0.0.1/" length="2" icon_url="" isroot=""><collection name="folder1" length="2" icon_url=""></collection><collection name="folder2" length="1" icon_url=""/><collection name="++etc++site" length="1" icon_url=""/></collection></children>
Modified: Zope3/trunk/src/zope/app/rotterdam/tests/output/test5.xml
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/tests/output/test5.xml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/tests/output/test5.xml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -1 +1 @@
-<?xml version="1.0" ?><children><collection name="" length="2" icon_url="" isroot=""><collection name="folder1" length="2" icon_url=""><collection name="folder1_1" length="2" icon_url=""><collection name="folder1_1_1" length="1" icon_url=""></collection><collection name="folder1_1_2" length="0" icon_url=""/><item name="++etc++site" icon_url="" /></collection><collection name="folder1_2" length="1" icon_url=""/><item name="++etc++site" icon_url="" /></collection><collection name="folder2" length="1" icon_url=""/><collection name="++etc++site" length="1" icon_url=""/></collection></children>
+<?xml version="1.0" ?><children><collection name="[top]" baseURL="http://127.0.0.1/" length="2" icon_url="" isroot=""><collection name="folder1" length="2" icon_url=""><collection name="folder1_1" length="2" icon_url=""><collection name="folder1_1_1" length="1" icon_url=""></collection><collection name="folder1_1_2" length="0" icon_url=""/><item name="++etc++site" icon_url="" /></collection><collection name="folder1_2" length="1" icon_url=""/><item name="++etc++site" icon_url="" /></collection><collection name="folder2" length="1" icon_url=""/><collection name="++etc++site" length="1" icon_url=""/></collection></children>
Added: Zope3/trunk/src/zope/app/rotterdam/tests/output/test6.xml
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/tests/output/test6.xml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/tests/output/test6.xml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -0,0 +1 @@
+<?xml version="1.0" ?><children><collection name="[subsite]" baseURL="http://127.0.0.1/" length="2" icon_url="" isroot=""></collection></children>
Property changes on: Zope3/trunk/src/zope/app/rotterdam/tests/output/test6.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: Zope3/trunk/src/zope/app/rotterdam/tests/output/test7.xml
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/tests/output/test7.xml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/tests/output/test7.xml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -0,0 +1 @@
+<?xml version="1.0" ?><children><collection name="[subsite]" baseURL="http://127.0.0.1/" length="2" icon_url="" isroot=""><collection name="subfolder1" length="0" icon_url=""></collection><collection name="subfolder2" length="1" icon_url=""/><collection name="++etc++site" length="1" icon_url=""/></collection></children>
\ No newline at end of file
Property changes on: Zope3/trunk/src/zope/app/rotterdam/tests/output/test7.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Added: Zope3/trunk/src/zope/app/rotterdam/tests/output/test8.xml
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/tests/output/test8.xml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/tests/output/test8.xml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -0,0 +1 @@
+<?xml version="1.0" ?><children><collection name="[subsite]" baseURL="http://127.0.0.1/" length="2" icon_url="" isroot=""><collection name="subfolder1" length="0" icon_url=""/><collection name="subfolder2" length="1" icon_url=""><collection name="subfolder2_1" length="0" icon_url=""></collection><item name="++etc++site" icon_url="" /></collection><collection name="++etc++site" length="1" icon_url=""/></collection></children>
\ No newline at end of file
Property changes on: Zope3/trunk/src/zope/app/rotterdam/tests/output/test8.xml
___________________________________________________________________
Name: svn:eol-style
+ native
Modified: Zope3/trunk/src/zope/app/rotterdam/tests/test_xmlnavigationviews.py
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/tests/test_xmlnavigationviews.py 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/tests/test_xmlnavigationviews.py 2005-03-24 03:01:44 UTC (rev 29656)
@@ -26,13 +26,16 @@
from zope.app.testing import ztapi
from zope.app.traversing.api import traverse
from zope.app.container.interfaces import IReadContainer
+from zope.app.component.site import LocalSiteManager
+from zope.app.component.testing import PlacefulSetup
+from zope.app.folder.folder import Folder
from zope.app.rotterdam.tests import util
from zope.app.rotterdam.xmlobject import ReadContainerXmlObjectView
from zope.app.rotterdam.xmlobject import XmlObjectView
-from zope.app.component.testing import PlacefulSetup
+
class File(object):
pass
@@ -78,7 +81,46 @@
treeView = XmlObjectView(self.file1, TestRequest()).singleBranchTree
check_xml(treeView(), util.read_output('test5.xml'))
+ def test_virtualhost_support(self):
+ # we have to add a virtual host subsite
+ folder1 = self.rootFolder['folder1']
+ subsite = Folder()
+ sm = LocalSiteManager(folder1)
+ subsite.setSiteManager(sm)
+ folder1['subsite'] = subsite
+
+ # add some more folder to the subsite
+ subfolder1 = Folder()
+ subsite['subfolder1'] = subfolder1
+ subfolder2 = Folder()
+ subfolder2_1 = Folder()
+ subfolder2['subfolder2_1'] = subfolder2_1
+ subsite['subfolder2'] = subfolder2
+
+ # set the virtualhost on the request
+ request = TestRequest()
+ request._vh_root = subsite
+
+ # test virtual host root
+ vh = request.getVirtualHostRoot()
+ self.assertEquals(vh, subsite)
+
+ rcxov = ReadContainerXmlObjectView
+ treeView = rcxov(subsite, request).singleBranchTree
+ check_xml(treeView(), util.read_output('test6.xml'))
+
+ rcxov = ReadContainerXmlObjectView
+ treeView = rcxov(subfolder1, request).singleBranchTree
+ check_xml(treeView(), util.read_output('test7.xml'))
+
+ rcxov = ReadContainerXmlObjectView
+ treeView = rcxov(subfolder2_1, request).singleBranchTree
+ check_xml(treeView(), util.read_output('test8.xml'))
+
+
+
+
def test_suite():
loader = TestLoader()
return loader.loadTestsFromTestCase(TestXmlObject)
Modified: Zope3/trunk/src/zope/app/rotterdam/xmlobject.py
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/xmlobject.py 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/xmlobject.py 2005-03-24 03:01:44 UTC (rev 29656)
@@ -15,16 +15,19 @@
$Id$
"""
+from rfc822 import formatdate, time
+from xml.sax.saxutils import quoteattr
+from zope.interface import Interface
+from zope.proxy import sameProxiedObjects
+from zope.security.interfaces import Unauthorized, Forbidden
+
+from zope.app import zapi
from zope.app.publisher.browser import BrowserView
-from zope.app import zapi
from zope.app.container.interfaces import IReadContainer
from zope.app.traversing.api import getParents, getParent, traverse
-from zope.interface import Interface
-from zope.security.interfaces import Unauthorized, Forbidden
-from rfc822 import formatdate, time
-from xml.sax.saxutils import quoteattr
+
def setNoCacheHeaders(response):
"""Ensure that the tree isn't cached"""
response.setHeader('Pragma', 'no-cache')
@@ -40,8 +43,31 @@
quotedArgs = [ quoteattr(str(arg)) for arg in args[:-1] ]
quotedArgsWithCData = quotedArgs + [cData]
return format%tuple(quotedArgsWithCData)
+
+def getParentsFromContextToObject(context, obj):
+ """Returns a list starting with the given context's parent followed by
+ each of its parents till we reach the object.
+
+ """
+ if sameProxiedObjects(context, obj):
+ return []
+
+ parents = []
+ w = context
+
+ while 1:
+ w = w.__parent__
+ if sameProxiedObjects(w, obj):
+ parents.append(w)
+ break
+ if w is None:
+ break
+ parents.append(w)
+ return parents
+
+
class ReadContainerXmlObjectView(BrowserView):
"""Provide a xml interface for dynamic navigation tree in UI"""
@@ -113,7 +139,25 @@
"""
result = ''
oldItem = self.context
- for item in getParents(self.context):
+
+ vh = self.request.getVirtualHostRoot()
+ if vh:
+ vhrootView = zapi.getMultiAdapter(
+ (vh, self.request), name='absolute_url')
+ baseURL = vhrootView() + '/'
+ try:
+ rootName = '[' + vh.__name__ + ']'
+ except:
+ # we got the containment root itself as the virtual host
+ # and there is no name.
+ rootName = '[top]'
+ parents = getParentsFromContextToObject(self.context, vh)
+ else:
+ rootName = '[top]'
+ baseURL = self.request.getApplicationURL()+'/'
+ parents = getParents(self.context)
+
+ for item in parents:
# skip skin if present
#if item == oldItem:
# continue
@@ -152,9 +196,9 @@
# do not forget root folder
iconUrl = self.getIconUrl(oldItem)
- result = (xmlEscapeWithCData('<collection name="" length=%s '
+ result = (xmlEscapeWithCData('<collection name=%s baseURL=%s length=%s '
'icon_url=%s isroot="">%s</collection>',
- len(oldItem), iconUrl, result))
+ rootName, baseURL, len(oldItem), iconUrl, result))
self.request.response.setHeader('Content-Type', 'text/xml')
setNoCacheHeaders(self.request.response)
Modified: Zope3/trunk/src/zope/app/rotterdam/xmltree.js
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/xmltree.js 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/xmltree.js 2005-03-24 03:01:44 UTC (rev 29656)
@@ -97,7 +97,8 @@
with (this) {
loadingNode = createLoadingNode();
domNode.appendChild(loadingNode);
- var url = baseurl + path + XML_CHILDREN_VIEW;
+ //var url = baseurl + path + XML_CHILDREN_VIEW;
+ var url = path + XML_CHILDREN_VIEW;
loadtreexml(url, this);
}
}
@@ -408,10 +409,12 @@
var navTreeNode = new navigationTreeNode(newelem);
var elemPath;
var elemTitle;
- //XXX should not hardcode root folder title string
if (source.getAttribute('isroot') != null) {
- elemTitle = '[top]';
- elemPath = basePath;
+ elemTitle = source.getAttribute('name');
+ //elemPath = basePath;
+ // set base url for virtual host support
+ baseurl = source.getAttribute('baseURL');
+ elemPath = source.getAttribute('baseURL');
newelem.style.marginLeft = '0px';
navigationTree = navTreeNode;
docNavTree.appendChild(newelem);
@@ -427,9 +430,7 @@
var icon_url = source.getAttribute('icon_url');
- var targetUrl = baseurl;
- targetUrl = targetUrl + elemPath;
- targetUrl = targetUrl + CONTENT_VIEW;
+ var targetUrl = elemPath + CONTENT_VIEW;
var expandElem = createPresentationNodes(elemTitle, targetUrl, icon_url, length);
newelem.appendChild(expandElem);
Modified: Zope3/trunk/src/zope/app/rotterdam/zope3_tablelayout.css
===================================================================
--- Zope3/trunk/src/zope/app/rotterdam/zope3_tablelayout.css 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/rotterdam/zope3_tablelayout.css 2005-03-24 03:01:44 UTC (rev 29656)
@@ -239,6 +239,46 @@
}
+/* Styles for xmltree
+*/
+
+#navtreecontents {
+ padding-right: 35px;
+}
+
+#navtreecontents a {
+ cursor: pointer;
+ height: 20px;
+}
+
+#navtreecontents loading {
+ display: block;
+ padding-left: 31px;
+ height: 18px;
+}
+
+#navtreecontents expand {
+ background-repeat: no-repeat;
+ padding-left: 14px;
+ display: inline;
+ cursor: pointer;
+}
+
+#navtreecontents icon {
+ background-repeat: no-repeat;
+ padding-left: 20px;
+ display: inline;
+ cursor: auto;
+}
+
+#navtreecontents collection {
+ display: block;
+ margin-left: 10px;
+/* border: red solid 1pt; */
+ height: auto;
+}
+
+
/* Structural elements
*/
Modified: Zope3/trunk/src/zope/app/tree/browser/configure.zcml
===================================================================
--- Zope3/trunk/src/zope/app/tree/browser/configure.zcml 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/tree/browser/configure.zcml 2005-03-24 03:01:44 UTC (rev 29656)
@@ -39,9 +39,7 @@
/>
</browser:pages>
- <!-- Set up the skin -->
- <!-- disable the StaticTree skin since Rotterdam uses it and
- depend on this package.
+ <!-- Set up the 'StaticTree' skin -->
<browser:layer name="statictree" />
<browser:skin
@@ -55,6 +53,5 @@
layer="statictree"
template="navigation_macros.pt"
/>
- -->
</configure>
Modified: Zope3/trunk/src/zope/app/tree/browser/navigation_macros.pt
===================================================================
--- Zope3/trunk/src/zope/app/tree/browser/navigation_macros.pt 2005-03-23 19:42:50 UTC (rev 29655)
+++ Zope3/trunk/src/zope/app/tree/browser/navigation_macros.pt 2005-03-24 03:01:44 UTC (rev 29656)
@@ -14,14 +14,13 @@
<metal:tree define-macro="navigation_tree_box">
<div class="box" id="navigationTree">
<h4 i18n:translate="">Navigation</h4>
+ <div class="treebody">
+<tal:block define="root context/@@virtualhost_cookie_tree;
+ result root/getFlatDicts;
+ nodeDictList python:result[0];
+ maxDepth python:result[1]">
-
-<table cellspacing="0" cellpadding="0"
- tal:define="root context/@@root_cookie_tree;
- result root/getFlatDicts;
- nodeDictList python:result[0];
- maxDepth python:result[1]">
-
+<table cellspacing="0" cellpadding="0">
<tr>
<td width="16">
<img src="" tal:define="icon root/context/@@zmi_icon | nothing"
@@ -36,10 +35,10 @@
tal:content="root/getId() | string:[top]"></a>
</td>
</tr>
+</table>
-<tr tal:repeat="nodeInfo nodeDictList">
-<tal:block tal:define="node nodeInfo/node">
-
+<table cellspacing="0" cellpadding="0" tal:repeat="nodeInfo nodeDictList">
+<tr tal:define="node nodeInfo/node">
<td style="width:16px" tal:repeat="state nodeInfo/row-state">
<img tal:attributes="src context/++resource++tree_images/vline.png"
tal:condition="state" alt="|" border="0" />
@@ -91,13 +90,11 @@
node/id
</a>
</td>
-
-</tal:block>
</tr>
-
</table>
+</tal:block>
-
+ </div>
</div>
</metal:tree>
</body>
More information about the Zope3-Checkins
mailing list