[Zope3-checkins] CVS: Zope3/src/zope/app/browser/services/utility -
__init__.py:1.10.6.1
Jim Fulton
jim at zope.com
Mon Sep 8 15:22:01 EDT 2003
Update of /cvs-repository/Zope3/src/zope/app/browser/services/utility
In directory cvs.zope.org:/tmp/cvs-serv20092/src/zope/app/browser/services/utility
Modified Files:
Tag: parentgeddon-branch
__init__.py
Log Message:
Checking in work in progress on parentgeddon-branch so Fred can help
me to get the tests passing. Specific log entries will be provided
when we merge this into the head.
=== Zope3/src/zope/app/browser/services/utility/__init__.py 1.10 => 1.10.6.1 ===
--- Zope3/src/zope/app/browser/services/utility/__init__.py:1.10 Mon Aug 18 14:55:26 2003
+++ Zope3/src/zope/app/browser/services/utility/__init__.py Mon Sep 8 14:21:31 2003
@@ -18,7 +18,7 @@
from zope.app.browser.component.interfacewidget import InterfaceWidget
from zope.app.browser.services.registration import AddComponentRegistration
from zope.app.form.widget import CustomWidget
-from zope.app.interfaces.container import IZopeContainer
+from zope.app.interfaces.container import IRemoveSource
from zope.app.interfaces.services.registration import ActiveStatus
from zope.app.interfaces.services.registration import RegisteredStatus
from zope.app.interfaces.services.registration import UnregisteredStatus
@@ -151,16 +151,16 @@
conf.status = UnregisteredStatus
parent = zapi.getParent(conf)
name = zapi.getName(conf)
- container = zapi.getAdapter(parent, IZopeContainer)
- del container[name]
+ remover = zapi.getAdapter(parent, IRemoveSource)
+ remover.removeObject(name)
# 2) Delete the service objects
for path, obj in services.items():
parent = zapi.getParent(obj)
name = zapi.getName(obj)
- container = zapi.getAdapter(parent, IZopeContainer)
- del container[name]
-
+ remover = zapi.getAdapter(parent, IRemoveSource)
+ remover.removeObject(name)
+
s = _("Deleted: ${utility_names}")
s.mapping = {'utility_names': ", ".join(todo)}
return s
More information about the Zope3-Checkins
mailing list