[Zope3-checkins] SVN: Zope3/trunk/src/zope/app/ generate
object-created events in a couple of places they were missing
Fred L. Drake, Jr.
fdrake at gmail.com
Wed Aug 18 15:06:18 EDT 2004
Log message for revision 27172:
generate object-created events in a couple of places they were missing
Changed:
U Zope3/trunk/src/zope/app/registration/registration.py
U Zope3/trunk/src/zope/app/site/service.py
-=-
Modified: Zope3/trunk/src/zope/app/registration/registration.py
===================================================================
--- Zope3/trunk/src/zope/app/registration/registration.py 2004-08-18 14:24:00 UTC (rev 27171)
+++ Zope3/trunk/src/zope/app/registration/registration.py 2004-08-18 19:06:18 UTC (rev 27172)
@@ -19,6 +19,8 @@
from persistent import Persistent
import zope.cachedescriptors.property
+import zope.event
+
from zope.interface import implements
from zope.exceptions import DuplicationError
from zope.proxy import removeAllProxies, getProxiedObject
@@ -31,6 +33,7 @@
from zope.app.container.contained import setitem, contained, uncontained
from zope.app.copypastemove import ObjectCopier
from zope.app.dependable.interfaces import IDependable, DependencyError
+from zope.app.event import objectevent
from zope.app.component.localservice import getLocalServices
from zope.app.location import inside
from zope.app.module.interfaces import IModuleManager
@@ -846,6 +849,7 @@
rm = RegistrationManager()
rm.__parent__ = self
rm.__name__ = 'RegistrationManager'
+ zope.event.notify(objectevent.ObjectCreatedEvent(rm))
self[rm.__name__] = rm
def __delitem__(self, name):
Modified: Zope3/trunk/src/zope/app/site/service.py
===================================================================
--- Zope3/trunk/src/zope/app/site/service.py 2004-08-18 14:24:00 UTC (rev 27171)
+++ Zope3/trunk/src/zope/app/site/service.py 2004-08-18 19:06:18 UTC (rev 27172)
@@ -29,6 +29,7 @@
from transaction import get_transaction
from zodbcode.module import PersistentModuleRegistry
+import zope.event
import zope.interface
from zope.component.exceptions import ComponentLookupError
@@ -40,6 +41,7 @@
from zope.app.container.constraints import ItemTypePrecondition
from zope.app.container.contained import Contained
from zope.app.container.interfaces import IContainer
+from zope.app.event import objectevent
from zope.app.registration.interfaces import IRegistry
from zope.app.traversing.interfaces import IContainmentRoot
from zope.app.traversing.api import getPath
@@ -80,7 +82,9 @@
PersistentModuleRegistry.__init__(self)
self.subSites = ()
self._setNext(site)
- self['default'] = SiteManagementFolder()
+ folder = SiteManagementFolder()
+ zope.event.notify(objectevent.ObjectCreatedEvent(folder))
+ self['default'] = folder
def _setNext(self, site):
"""Find set the next service manager
More information about the Zope3-Checkins
mailing list