[Zope-Checkins] CVS: Zope/lib/python/ThreadedAsync -
LoopCallback.py:1.10.10.1
Jim Fulton
cvs-admin at zope.org
Tue Nov 25 15:18:15 EST 2003
Update of /cvs-repository/Zope/lib/python/ThreadedAsync
In directory cvs.zope.org:/tmp/cvs-serv24052/lib/python/ThreadedAsync
Modified Files:
Tag: Zope-2_8-devel-branch
LoopCallback.py
Log Message:
merged everything but ZODB and ZEO from zodb33-devel-branch
=== Zope/lib/python/ThreadedAsync/LoopCallback.py 1.10 => 1.10.10.1 ===
--- Zope/lib/python/ThreadedAsync/LoopCallback.py:1.10 Thu Oct 2 18:14:01 2003
+++ Zope/lib/python/ThreadedAsync/LoopCallback.py Tue Nov 25 15:17:44 2003
@@ -37,6 +37,16 @@
_looping = None
_loop_callbacks = []
+def remove_loop_callback(callback):
+ """Remove a callback function registered earlier.
+
+ This is useful if loop() was never called.
+ """
+ for i in range(len(_loop_callbacks)):
+ if _loop_callbacks[i][0] == callback:
+ del _loop_callbacks[i]
+ return
+
def register_loop_callback(callback, args=(), kw=None):
"""Register callback function to be called when mainloop starts
More information about the Zope-Checkins
mailing list