Trees | Indices | Help |
|
---|
|
object --+ | WeakEvent
Usage:
>>> myEvent = Event() # a, b >>> callback1 = lambda a, b: dostuff(a, b) >>> callback2 = lambda a, b: otherstuff(a, b) >>> callback3 = self.callback3 >>> myEvent += callback1 >>> myEvent += callback2 >>> myEvent(a, b) # calls both callbacks >>> myEvent -= callback1 >>> myEvent -= callback2 >>> myEvent(a, b) # no callbacks; does nothing
note: keep a ref somewhere, even to self.whatever, or it will be unlinked; see Reffer
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from |
|
|||
_listeners | |||
_names | |||
_stacks | |||
enabled | |||
name | |||
Inherited from |
|
x.__init__(...) initializes x; see help(type(x)) for signature
|
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Fri Dec 15 19:07:38 2017 | http://epydoc.sourceforge.net |