[Zope3-checkins] CVS: Zope3/src/zope/app/security/browser - configure.zcml:1.2 permissionwidget.py:1.2

Jim Fulton jim at zope.com
Mon Mar 8 14:40:33 EST 2004


Update of /cvs-repository/Zope3/src/zope/app/security/browser
In directory cvs.zope.org:/tmp/cvs-serv29049/src/zope/app/security/browser

Modified Files:
	configure.zcml permissionwidget.py 
Log Message:
Updated (again) to reflect recent widget-framework changes.


=== Zope3/src/zope/app/security/browser/configure.zcml 1.1 => 1.2 ===
--- Zope3/src/zope/app/security/browser/configure.zcml:1.1	Mon Mar  8 07:07:19 2004
+++ Zope3/src/zope/app/security/browser/configure.zcml	Mon Mar  8 14:40:33 2004
@@ -1,17 +1,17 @@
-<zope:configure 
-   xmlns:zope="http://namespaces.zope.org/zope"
-   xmlns="http://namespaces.zope.org/browser">
+<configure xmlns="http://namespaces.zope.org/zope">
 
-  <page
+  <view
       for="zope.app.security.interfaces.IPermissionField"
-      name="edit"
-      class=".permissionwidget.SinglePermissionWidget"
-      permission="zope.Public" />
+      provides="zope.app.interfaces.form.IInputWidget"
+      type="zope.publisher.interfaces.browser.IBrowserRequest"
+      factory=".permissionwidget.SinglePermissionWidget"
+      />
 
-  <page 
+  <view 
       for="zope.app.security.interfaces.IPermissionField"
-      name="display"
-      class=".permissionwidget.DisplayWidget"
-      permission="zope.Public" />
+      provides="zope.app.interfaces.form.IDisplayWidget"
+      type="zope.publisher.interfaces.browser.IBrowserRequest"
+      factory=".permissionwidget.DisplayWidget"
+      />
 
-</zope:configure>
+</configure>


=== Zope3/src/zope/app/security/browser/permissionwidget.py 1.1 => 1.2 ===
--- Zope3/src/zope/app/security/browser/permissionwidget.py:1.1	Mon Mar  8 07:07:19 2004
+++ Zope3/src/zope/app/security/browser/permissionwidget.py	Mon Mar  8 14:40:33 2004
@@ -15,12 +15,15 @@
 
 $Id$
 """
-from zope.app import zapi
+
 from zope.app.browser.form import widget
-from zope.app.services.servicenames import Translation
+from zope.app.i18n import ZopeMessageIDFactory as _
+from zope.app import zapi
 from zope.app.security.interfaces import IPermission
+from zope.app.services.servicenames import Translation
 from zope.security.checker import CheckerPublic
-from zope.app.i18n import ZopeMessageIDFactory as _
+import zope.app.interfaces.form
+import zope.interface
 
 
 class BaseWidget:
@@ -47,6 +50,8 @@
         return permission_id
 
 class SinglePermissionWidget(BaseWidget, widget.BrowserWidget):
+
+    zope.interface.implements(zope.app.interfaces.form.IInputWidget)
 
     def __call__(self):
         search_name = self.name + ".search"




More information about the Zope3-Checkins mailing list