[Zope-Checkins] SVN: Zope/trunk/ Make use of the new zope.container and zope.site packages.
Hanno Schlichting
plone at hannosch.info
Wed Feb 4 17:32:38 EST 2009
Log message for revision 96098:
Make use of the new zope.container and zope.site packages.
Changed:
U Zope/trunk/doc/CHANGES.txt
U Zope/trunk/lib/python/OFS/CopySupport.py
U Zope/trunk/lib/python/OFS/ObjectManager.py
U Zope/trunk/lib/python/OFS/OrderSupport.py
U Zope/trunk/lib/python/OFS/subscribers.py
U Zope/trunk/lib/python/Products/BTreeFolder2/BTreeFolder2.py
U Zope/trunk/lib/python/Products/Five/browser/adding.py
U Zope/trunk/lib/python/Products/Five/browser/configure.zcml
U Zope/trunk/lib/python/Products/Five/component/__init__.py
U Zope/trunk/lib/python/Products/Five/component/browser.py
U Zope/trunk/lib/python/Products/Five/component/configure.zcml
U Zope/trunk/lib/python/Products/Five/component/makesite.txt
U Zope/trunk/lib/python/Products/Five/doc/directives.txt
U Zope/trunk/lib/python/Products/Five/doc/event.txt
U Zope/trunk/lib/python/Products/Five/eventconfigure.py
U Zope/trunk/lib/python/Products/Five/tests/event.txt
U Zope/trunk/lib/python/Testing/ZopeTestCase/functional.py
U Zope/trunk/lib/python/webdav/Resource.py
-=-
Modified: Zope/trunk/doc/CHANGES.txt
===================================================================
--- Zope/trunk/doc/CHANGES.txt 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/doc/CHANGES.txt 2009-02-04 22:32:38 UTC (rev 96098)
@@ -9,8 +9,10 @@
Restructuring
+ - Make use of the new zope.container and zope.site packages.
+
- Updated to newer versions of zope packages. Removed long deprecated
- defaultSkin, layer and skin ZCML directives.
+ layer and skin ZCML directives.
- Disabled the XML export on the UI level - the export functionality
however is still available on the Python level.
Modified: Zope/trunk/lib/python/OFS/CopySupport.py
===================================================================
--- Zope/trunk/lib/python/OFS/CopySupport.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/OFS/CopySupport.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -48,8 +48,8 @@
from zope.interface import implements
from zope.event import notify
from zope.lifecycleevent import ObjectCopiedEvent
-from zope.app.container.contained import ObjectMovedEvent
-from zope.app.container.contained import notifyContainerModified
+from zope.container.contained import ObjectMovedEvent
+from zope.container.contained import notifyContainerModified
from OFS.event import ObjectWillBeMovedEvent
from OFS.event import ObjectClonedEvent
Modified: Zope/trunk/lib/python/OFS/ObjectManager.py
===================================================================
--- Zope/trunk/lib/python/OFS/ObjectManager.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/OFS/ObjectManager.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -52,10 +52,10 @@
from zope.interface import implements
from zope.component.interfaces import ComponentLookupError
from zope.event import notify
-from zope.app.container.contained import ObjectAddedEvent
-from zope.app.container.contained import ObjectRemovedEvent
-from zope.app.container.contained import notifyContainerModified
-from zope.app.container.interfaces import IContainer
+from zope.container.contained import ObjectAddedEvent
+from zope.container.contained import ObjectRemovedEvent
+from zope.container.contained import notifyContainerModified
+from zope.container.interfaces import IContainer
from zope.interface import implements
from OFS.CopySupport import CopyContainer
Modified: Zope/trunk/lib/python/OFS/OrderSupport.py
===================================================================
--- Zope/trunk/lib/python/OFS/OrderSupport.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/OFS/OrderSupport.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -24,7 +24,7 @@
from App.class_init import InitializeClass
from DocumentTemplate.sequence import sort
from zope.interface import implements
-from zope.app.container.contained import notifyContainerModified
+from zope.container.contained import notifyContainerModified
from OFS.interfaces import IOrderedContainer as IOrderedContainer
from OFS.ObjectManager import ObjectManager
Modified: Zope/trunk/lib/python/OFS/subscribers.py
===================================================================
--- Zope/trunk/lib/python/OFS/subscribers.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/OFS/subscribers.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -29,8 +29,8 @@
import zope.component
import zope.interface
import zope.location.interfaces
-from zope.app.container.contained import dispatchToSublocations
-from zope.app.container.interfaces import IObjectMovedEvent
+from zope.container.contained import dispatchToSublocations
+from zope.container.interfaces import IObjectMovedEvent
from zope.lifecycleevent.interfaces import IObjectCopiedEvent
deprecatedManageAddDeleteClasses = []
Modified: Zope/trunk/lib/python/Products/BTreeFolder2/BTreeFolder2.py
===================================================================
--- Zope/trunk/lib/python/Products/BTreeFolder2/BTreeFolder2.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/BTreeFolder2/BTreeFolder2.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -43,9 +43,9 @@
from Products.ZCatalog.Lazy import LazyMap
from ZODB.POSException import ConflictError
from zope.event import notify
-from zope.app.container.contained import ObjectAddedEvent
-from zope.app.container.contained import ObjectRemovedEvent
-from zope.app.container.contained import notifyContainerModified
+from zope.container.contained import ObjectAddedEvent
+from zope.container.contained import ObjectRemovedEvent
+from zope.container.contained import notifyContainerModified
LOG = getLogger('BTreeFolder2')
Modified: Zope/trunk/lib/python/Products/Five/browser/adding.py
===================================================================
--- Zope/trunk/lib/python/Products/Five/browser/adding.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/browser/adding.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -30,6 +30,11 @@
from zope.component import queryMultiAdapter
from zope.component import queryUtility
from zope.component.interfaces import IFactory
+from zope.container.constraints import checkFactory, checkObject
+from zope.container.i18n import ZopeMessageFactory as _
+from zope.container.interfaces import IContainerNamesContainer
+from zope.container.interfaces import INameChooser
+
from zope.event import notify
from zope.interface import implements
from zope.publisher.interfaces import IPublishTraverse
@@ -37,10 +42,7 @@
from zope.exceptions.interfaces import UserError
from zope.lifecycleevent import ObjectCreatedEvent
-from zope.app.container.constraints import checkFactory, checkObject
-from zope.app.container.i18n import ZopeMessageFactory as _
-from zope.app.container.interfaces import IAdding, INameChooser
-from zope.app.container.interfaces import IContainerNamesContainer
+from zope.app.container.interfaces import IAdding
from zope.app.publisher.browser.menu import getMenu
from zExceptions import BadRequest
Modified: Zope/trunk/lib/python/Products/Five/browser/configure.zcml
===================================================================
--- Zope/trunk/lib/python/Products/Five/browser/configure.zcml 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/browser/configure.zcml 2009-02-04 22:32:38 UTC (rev 96098)
@@ -72,7 +72,7 @@
<adapter
for="OFS.interfaces.IObjectManager"
factory=".adding.ObjectManagerNameChooser"
- provides="zope.app.container.interfaces.INameChooser"
+ provides="zope.container.interfaces.INameChooser"
/>
<!-- Menu access -->
Modified: Zope/trunk/lib/python/Products/Five/component/__init__.py
===================================================================
--- Zope/trunk/lib/python/Products/Five/component/__init__.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/component/__init__.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -29,8 +29,8 @@
from ZPublisher.BeforeTraverse import unregisterBeforeTraverse
# Hook up custom component architecture calls
-import zope.app.component.hooks
-zope.app.component.hooks.setHooks()
+from zope.site.hooks import setHooks
+setHooks()
def findSite(obj, iface=ISite):
"""Find a site by walking up the object hierarchy, supporting both
Modified: Zope/trunk/lib/python/Products/Five/component/browser.py
===================================================================
--- Zope/trunk/lib/python/Products/Five/component/browser.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/component/browser.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -21,7 +21,7 @@
from zope.component.globalregistry import base
from zope.component.persistentregistry import PersistentComponents
-from zope.app.component.hooks import clearSite
+from zope.site.hooks import setSite
class ObjectManagerSiteView(BrowserView):
@@ -59,6 +59,6 @@
# it can't be found anymore. So, for the rest of this request
# (which will be over in about 20 CPU cycles), already clear
# the local site from the thread local.
- clearSite()
+ setSite()
self.context.setSiteManager(None)
Modified: Zope/trunk/lib/python/Products/Five/component/configure.zcml
===================================================================
--- Zope/trunk/lib/python/Products/Five/component/configure.zcml 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/component/configure.zcml 2009-02-04 22:32:38 UTC (rev 96098)
@@ -6,12 +6,12 @@
<subscriber
for="zope.location.interfaces.ISite
zope.app.publication.interfaces.IBeforeTraverseEvent"
- handler="zope.app.component.site.threadSiteSubscriber"
+ handler="zope.site.site.threadSiteSubscriber"
/>
<subscriber
for="zope.app.publication.interfaces.IEndRequestEvent"
- handler="zope.app.component.site.clearThreadSiteSubscriber"
+ handler="zope.site.site.clearThreadSiteSubscriber"
/>
<browser:page
Modified: Zope/trunk/lib/python/Products/Five/component/makesite.txt
===================================================================
--- Zope/trunk/lib/python/Products/Five/component/makesite.txt 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/component/makesite.txt 2009-02-04 22:32:38 UTC (rev 96098)
@@ -18,7 +18,7 @@
Enable local component lookup hooks:
- >>> from zope.app.component.hooks import setHooks
+ >>> from zope.site.hooks import setHooks
>>> setHooks()
Modified: Zope/trunk/lib/python/Products/Five/doc/directives.txt
===================================================================
--- Zope/trunk/lib/python/Products/Five/doc/directives.txt 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/doc/directives.txt 2009-02-04 22:32:38 UTC (rev 96098)
@@ -32,11 +32,6 @@
Redefine a permission in included ZCML as another one.
-skin
-----
-
-Declare a skin, consisting of layers.
-
utility
-------
@@ -73,11 +68,6 @@
Declare the name of the view that should be used for the default when viewing
the object; i.e. when the object is traversed to without a view.
-defaultSkin
------------
-
-Declare the default skin used.
-
editform
--------
@@ -88,11 +78,6 @@
Create an add form based on a schema.
-layer
------
-
-Declare a layer.
-
menu
----
Modified: Zope/trunk/lib/python/Products/Five/doc/event.txt
===================================================================
--- Zope/trunk/lib/python/Products/Five/doc/event.txt 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/doc/event.txt 2009-02-04 22:32:38 UTC (rev 96098)
@@ -131,7 +131,7 @@
...
<subscriber
for="Products.CoolProduct.interfaces.ICoolDocument
- zope.app.container.interfaces.IObjectAddedEvent"
+ zope.container.interfaces.IObjectAddedEvent"
handler="Products.CoolProduct.CoolDocument.addedCoolDocument"
/>
...
@@ -214,7 +214,7 @@
...
<subscriber
for="Products.CoolProduct.interfaces.ICoolDocument
- zope.app.container.interfaces.IObjectMovedEvent"
+ zope.container.interfaces.IObjectMovedEvent"
handler="Products.CoolProduct.CoolDocument.movedCoolDocument"
/>
...
Modified: Zope/trunk/lib/python/Products/Five/eventconfigure.py
===================================================================
--- Zope/trunk/lib/python/Products/Five/eventconfigure.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/eventconfigure.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -12,7 +12,7 @@
#
##############################################################################
"""
-Use 'structured monkey patching' to enable zope.app.container event sending for
+Use 'structured monkey patching' to enable zope.container event sending for
Zope 2 objects.
$Id$
Modified: Zope/trunk/lib/python/Products/Five/tests/event.txt
===================================================================
--- Zope/trunk/lib/python/Products/Five/tests/event.txt 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Products/Five/tests/event.txt 2009-02-04 22:32:38 UTC (rev 96098)
@@ -56,7 +56,7 @@
printed events will be in their "natural" order::
>>> from zope.component.interfaces import IObjectEvent, IRegistrationEvent
- >>> from zope.app.container.interfaces import IObjectMovedEvent
+ >>> from zope.container.interfaces import IObjectMovedEvent
>>> from zope.lifecycleevent.interfaces import IObjectCopiedEvent
>>> from OFS.interfaces import IObjectWillBeMovedEvent
>>> from OFS.interfaces import IObjectClonedEvent
Modified: Zope/trunk/lib/python/Testing/ZopeTestCase/functional.py
===================================================================
--- Zope/trunk/lib/python/Testing/ZopeTestCase/functional.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/Testing/ZopeTestCase/functional.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -31,8 +31,8 @@
'''
from AccessControl.SecurityManagement import getSecurityManager
from AccessControl.SecurityManagement import setSecurityManager
- from zope.app.component.hooks import getSite
- from zope.app.component.hooks import setSite
+ from zope.site.hooks import getSite
+ from zope.site.hooks import setSite
def wrapped_func(*args, **kw):
sm, site = getSecurityManager(), getSite()
Modified: Zope/trunk/lib/python/webdav/Resource.py
===================================================================
--- Zope/trunk/lib/python/webdav/Resource.py 2009-02-04 22:29:46 UTC (rev 96097)
+++ Zope/trunk/lib/python/webdav/Resource.py 2009-02-04 22:32:38 UTC (rev 96098)
@@ -47,8 +47,8 @@
from zope.interface import implements
from zope.event import notify
from zope.lifecycleevent import ObjectCopiedEvent
-from zope.app.container.contained import ObjectMovedEvent
-from zope.app.container.contained import notifyContainerModified
+from zope.container.contained import ObjectMovedEvent
+from zope.container.contained import notifyContainerModified
from webdav.Lockable import LockableItem
from webdav.Lockable import wl_isLockable
More information about the Zope-Checkins
mailing list