[Zope3-checkins] CVS: Zope3/src/zope/app/services -
folder.py:1.13.6.2 menu.py:1.6.4.2 registration.py:1.14.4.2
utility.py:1.16.6.2
Jim Fulton
jim at zope.com
Mon Sep 8 18:15:41 EDT 2003
Update of /cvs-repository/Zope3/src/zope/app/services
In directory cvs.zope.org:/tmp/cvs-serv18062/src/zope/app/services
Modified Files:
Tag: parentgeddon-branch
folder.py menu.py registration.py utility.py
Log Message:
Made a bunch of tests pass. :) Detailed messages will be provided
when merging to the head.
=== Zope3/src/zope/app/services/folder.py 1.13.6.1 => 1.13.6.2 ===
--- Zope3/src/zope/app/services/folder.py:1.13.6.1 Mon Sep 8 14:21:47 2003
+++ Zope3/src/zope/app/services/folder.py Mon Sep 8 17:15:10 2003
@@ -75,11 +75,15 @@
# Disallow the name "Packages"
if name == "Packages":
raise ValueError("Packages is not a valid package name")
+
+ name = super(SiteManagementFolders, self).setObject(name, obj)
# We want out items to be virtually contained in our container
+ # We have to do this after calling the superclass setObject
+ # otherwise, it would be overwritten.
obj.__parent__ = self.__parent__
-
- return super(SiteManagementFolders, self).setObject(name, obj)
+
+ return name
class SMFolderFactory(object):
=== Zope3/src/zope/app/services/menu.py 1.6.4.1 => 1.6.4.2 ===
--- Zope3/src/zope/app/services/menu.py:1.6.4.1 Mon Sep 8 14:21:47 2003
+++ Zope3/src/zope/app/services/menu.py Mon Sep 8 17:15:10 2003
@@ -35,7 +35,7 @@
from zope.app.container.contained import Contained
-class LocalBrowserMenuItem(Persistent, Contained):
+class LocalBrowserMenuItem(Persistent):
"""A persistent browser menu item."""
implements(IBrowserMenuItem)
@@ -106,7 +106,7 @@
return key
-class LocalBrowserMenuService(BaseBrowserMenuService, Persistent):
+class LocalBrowserMenuService(BaseBrowserMenuService, Persistent, Contained):
"""This implementation strongly depends on the semantics of
GlobalBrowserMenuService."""
=== Zope3/src/zope/app/services/registration.py 1.14.4.1 => 1.14.4.2 ===
--- Zope3/src/zope/app/services/registration.py:1.14.4.1 Mon Sep 8 14:21:47 2003
+++ Zope3/src/zope/app/services/registration.py Mon Sep 8 17:15:10 2003
@@ -474,6 +474,7 @@
registry = self._bindings[name]
except KeyError:
registry = RegistrationStack(self)
+ registry.__parent__ = self
self._bindings[name] = registry
self._p_changed = 1
return registry
=== Zope3/src/zope/app/services/utility.py 1.16.6.1 => 1.16.6.2 ===
--- Zope3/src/zope/app/services/utility.py:1.16.6.1 Mon Sep 8 14:21:47 2003
+++ Zope3/src/zope/app/services/utility.py Mon Sep 8 17:15:10 2003
@@ -32,7 +32,7 @@
from zope.proxy import removeAllProxies
from zope.app.container.contained import Contained
-class LocalUtilityService(Persistent):
+class LocalUtilityService(Persistent, Contained):
implements(ILocalUtilityService, IRegistry, ISimpleService)
@@ -129,7 +129,7 @@
stack = utilities.getRegistered(interface)
if stack is None:
- stack = RegistrationStack()
+ stack = RegistrationStack(self)
utilities.register(interface, stack)
return stack
More information about the Zope3-Checkins
mailing list