[Zope3-checkins] CVS: Zope3/src/zope/app/content - configure.zcml:1.28.2.1 folder.py:1.15.2.3

Jim Fulton jim at zope.com
Fri Sep 12 16:46:57 EDT 2003


Update of /cvs-repository/Zope3/src/zope/app/content
In directory cvs.zope.org:/tmp/cvs-serv29614/src/zope/app/content

Modified Files:
      Tag: parentgeddon-branch
	configure.zcml folder.py 
Log Message:
merged Folder and RootFolder

=== Zope3/src/zope/app/content/configure.zcml 1.28 => 1.28.2.1 ===
--- Zope3/src/zope/app/content/configure.zcml:1.28	Tue Sep  2 16:46:46 2003
+++ Zope3/src/zope/app/content/configure.zcml	Fri Sep 12 16:46:26 2003
@@ -50,13 +50,6 @@
    />
 
 <adapter
-   for="zope.app.interfaces.content.folder.IRootFolder"
-   provides="zope.app.interfaces.file.IDirectoryFactory"
-   factory="zope.app.content.folder.RootDirectoryFactory"
-   permission="zope.ManageContent"
-   />
-
-<adapter
    for="zope.app.interfaces.content.folder.IFolder"
    provides="zope.app.interfaces.file.IFileFactory"
    factory="zope.app.content.image.FileFactory"
@@ -111,20 +104,6 @@
    factory="zope.app.container.copypastemove.PasteNamesChooser"
    />
 
-<!-- XXX Do we really need RootFolder? -->
-
-<content class="zope.app.content.folder.RootFolder">
-
-  <implements interface="zope.app.interfaces.container.IContentContainer" />
-
-  <require like_class="zope.app.content.folder.Folder" />
-
-  <implements
-     interface="zope.app.interfaces.annotation.IAttributeAnnotatable"
-     />
-
-</content>
-
 <permission
     id="zope.AddImages"
     title="[add-images-permission] Add Images"
@@ -427,8 +406,6 @@
 <fssync:adapter class=".image.Image" factory=".fssync.FileAdapter" />
 
 <fssync:adapter class=".folder.Folder" factory=".folder.FolderAdapter" />
-
-<fssync:adapter class=".folder.RootFolder" factory=".folder.FolderAdapter" />
 
 <fssync:adapter class=".zpt.ZPTPage" factory=".fssync.ZPTPageAdapter" />
 


=== Zope3/src/zope/app/content/folder.py 1.15.2.2 => 1.15.2.3 ===
--- Zope3/src/zope/app/content/folder.py:1.15.2.2	Fri Sep 12 15:15:22 2003
+++ Zope3/src/zope/app/content/folder.py	Fri Sep 12 16:46:26 2003
@@ -19,7 +19,7 @@
 from zope.app.interfaces.services.service import ISite
 from zope.app.services.servicecontainer import ServiceManagerContainer
 from zope.exceptions import DuplicationError
-from zope.interface import implements
+from zope.interface import implements, directlyProvides
 from zope.app.container.contained import Contained, contained, uncontained
 
 class Folder(Persistent, ServiceManagerContainer, Contained):
@@ -100,10 +100,13 @@
         uncontained(self.data[name], self)
         del self.data[name]
 
-class RootFolder(Folder):
-    """The standard Zope root Folder implementation."""
+RootFolder = Folder
+
+def rootFolder():
+    f = Folder()
+    directlyProvides(f, IRootFolder)
+    return f
 
-    implements(IRootFolder)
 
 
 class RootDirectoryFactory:




More information about the Zope3-Checkins mailing list