[Zope3-checkins] CVS: Zope3/src/zope/app/browser/services - event.py:1.1.2.2
Fred L. Drake, Jr.
fred@zope.com
Tue, 24 Dec 2002 02:27:17 -0500
Update of /cvs-repository/Zope3/src/zope/app/browser/services
In directory cvs.zope.org:/tmp/cvs-serv23414
Modified Files:
Tag: NameGeddon-branch
event.py
Log Message:
- fix & clean up imports
- remove unused import
- general cleanup, normalize whitespace
=== Zope3/src/zope/app/browser/services/event.py 1.1.2.1 => 1.1.2.2 ===
--- Zope3/src/zope/app/browser/services/event.py:1.1.2.1 Mon Dec 23 14:31:12 2002
+++ Zope3/src/zope/app/browser/services/event.py Tue Dec 24 02:27:16 2002
@@ -2,33 +2,33 @@
#
# Copyright (c) 2001, 2002 Zope Corporation and Contributors.
# All Rights Reserved.
-#
+#
# This software is subject to the provisions of the Zope Public License,
# Version 2.0 (ZPL). A copy of the ZPL should accompany this distribution.
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
# FOR A PARTICULAR PURPOSE.
-#
+#
##############################################################################
""" Define view component for event service control.
$Id$
"""
-from zope.publisher.browser import BrowserView
-from zope.component.contextdependent import ContextDependent
+from zope.app.pagetemplate.viewpagetemplatefile import ViewPageTemplateFile
from zope.interfaces.event import IEventService
-from Zope.App.PageTemplate import ViewPageTemplateFile
from zope.proxy.introspection import removeAllProxies
+from zope.publisher.browser import BrowserView
+
class Control(BrowserView):
__used_for__ = IEventService
- def index( self, toggleSubscribeOnBind=0):
+ def index(self, toggleSubscribeOnBind=False):
if toggleSubscribeOnBind:
- cntx=removeAllProxies(self.context)
- cntx.subscribeOnBind=not cntx.subscribeOnBind
+ cntx = removeAllProxies(self.context)
+ cntx.subscribeOnBind = not cntx.subscribeOnBind
return self.__control()
-
- __control=ViewPageTemplateFile("control.pt")
+
+ __control = ViewPageTemplateFile("control.pt")