libtextworker 0.1.4
Cross-platform, free and open library for Python projects
|
Static Public Attributes | |
bool | |
A file system event handler derived from watchdog's FileSystemEventHandler. On both wx and Tk, a new event will be generated. Set the Target attribute which the handler sends the event to. Or, if you use this for your own widget, derive this class like any other classes you use for that widget, and set TargetIsSelf = True instead of Target. This class does not use __init__. Currently only one target is supported. Example usage: ```python from watchdog.observers import Observer (...) def on_close(evt): # On window close observer.stop() observer.join() evt.Skip() def func(evt): # Do anything with evt.path! wind = wx.(...) # A wxWindow wind.Bind("put your wanted event here", func) path = os.path.expanduser('~/') evt_handler = FSEventHandler() evt_handler.Target = wind observer = Observer() observer.schedule(evt_handler, path, recursive=True) observer.start() ```
Definition at line 55 of file dirctrl.py.