[Zope3-checkins] SVN: Zope3/branches/3.2/src/zope/app/rotterdam/template Merged 40646 from trunk:

Jim Fulton jim at zope.com
Thu Dec 8 18:25:15 EST 2005


Log message for revision 40647:
  Merged 40646 from trunk:
  
  Fixed a bug that caused work to be done unnecessarily, slowing down
  non-zmi requests about 20%.  This was a case where someone though that
  tal:define was executed after tal:condition.  The condition was trying
  and failing to guard some expensive computation.
  

Changed:
  U   Zope3/branches/3.2/src/zope/app/rotterdam/template.pt
  U   Zope3/branches/3.2/src/zope/app/rotterdam/template_tablelayout.pt

-=-
Modified: Zope3/branches/3.2/src/zope/app/rotterdam/template.pt
===================================================================
--- Zope3/branches/3.2/src/zope/app/rotterdam/template.pt	2005-12-08 23:08:40 UTC (rev 40646)
+++ Zope3/branches/3.2/src/zope/app/rotterdam/template.pt	2005-12-08 23:25:14 UTC (rev 40647)
@@ -121,13 +121,14 @@
       <!-- OnlineHelp with popup support -->
       <!-- note, we reverse the actions list 'cos they're packed to the
            screen from the right -->
-      <div tal:condition="python: macroname == 'view'" id="actions"
-           tal:define="
+      <div tal:condition="python: macroname == 'view'" id="actions">
+        <span 
+            tal:condition="actions"
+            tal:define="
                help_actions context/@@view_get_menu/help_actions|nothing;
-               actions context/@@view_get_menu/zmi_actions">
-        <span tal:condition="actions"
-              tal:omit-tag=""
-					><a href="#"
+               actions context/@@view_get_menu/zmi_actions"
+            tal:omit-tag=""
+	    ><a href="#"
                tal:repeat="info actions"
                tal:attributes="href info/action"
                tal:content="info/title" i18n:translate="">

Modified: Zope3/branches/3.2/src/zope/app/rotterdam/template_tablelayout.pt
===================================================================
--- Zope3/branches/3.2/src/zope/app/rotterdam/template_tablelayout.pt	2005-12-08 23:08:40 UTC (rev 40646)
+++ Zope3/branches/3.2/src/zope/app/rotterdam/template_tablelayout.pt	2005-12-08 23:25:14 UTC (rev 40647)
@@ -121,11 +121,11 @@
                     <!-- OnlineHelp with popup support -->
                     <!-- note, we reverse the actions list 'cos they're packed to the
                              screen from the right -->
-                    <div tal:condition="python: macroname == 'view'" id="action"
-                             tal:define="
-                                     help_actions context/@@view_get_menu/help_actions|nothing;
-                                     actions context/@@view_get_menu/zmi_actions">
-                        <ul>
+                    <div tal:condition="python: macroname == 'view'" id="action">
+                        <ul tal:define="
+                              help_actions context/@@view_get_menu/help_actions|nothing;
+                              actions context/@@view_get_menu/zmi_actions"
+                              >
                             <li tal:condition="actions" tal:repeat="info actions"
                                 ><a href="#"
                                          tal:attributes="href info/action"



More information about the Zope3-Checkins mailing list