[Zope3-checkins] CVS: Zope3/src/zope/app/services - menu.py:1.8
Jim Fulton
cvs-admin at zope.org
Wed Dec 3 00:42:05 EST 2003
Update of /cvs-repository/Zope3/src/zope/app/services
In directory cvs.zope.org:/tmp/cvs-serv19258/src/zope/app/services
Modified Files:
menu.py
Log Message:
Added extra data to browser menu items to accomidate the needs of
add menus.
Changed menu item data to use objects rather than tuples to store the
data,
=== Zope3/src/zope/app/services/menu.py 1.7 => 1.8 ===
--- Zope3/src/zope/app/services/menu.py:1.7 Sun Sep 21 13:32:54 2003
+++ Zope3/src/zope/app/services/menu.py Wed Dec 3 00:41:34 2003
@@ -58,6 +58,11 @@
# See zope.app.interfaces.publisher.browser.IBrowserMenuItem
filter_string = u''
+ # XXX the filter should probably be some kind of descriptor.
+ # There's nothing here to hook this up.
+ filter = None
+
+ extra = None
class LocalBrowserMenu(OrderedContainer):
"""A persistent browser menu that can store menu item objects."""
@@ -86,12 +91,7 @@
interfaces = list(providedBy(object).flattened())
for menuitem in self.values():
if menuitem.interface in interfaces or object is None:
- result.append(
- (menuitem.action,
- menuitem.title,
- menuitem.description,
- menuitem.filter_string or None,
- menuitem.permission))
+ result.append(menuitem)
return result
More information about the Zope3-Checkins
mailing list