diff options
author | Ian Ward <ian@excess.org> | 2011-11-13 21:45:40 -0500 |
---|---|---|
committer | Ian Ward <ian@excess.org> | 2011-11-13 21:45:40 -0500 |
commit | 921532b62fd49f3523b5897fbf727bdcf41baba7 (patch) | |
tree | 2771a091cf474458a48c6cca09ffa78da99cd161 | |
parent | 006bdeefd968818da02d05216142b6088febd2c1 (diff) | |
download | urwid-921532b62fd49f3523b5897fbf727bdcf41baba7.tar.gz |
mark PollingListWalker as deprecated, it needs to go away soon.
-rw-r--r-- | CHANGELOG | 2 | ||||
-rw-r--r-- | urwid/listbox.py | 8 |
2 files changed, 9 insertions, 1 deletions
@@ -15,6 +15,8 @@ Urwid 1.0.1 * Disable curses_display external event loop support, screen resizing and gpm events are not properly supported + * Mark PollingListWalker as deprecated + Urwid 1.0.0 diff --git a/urwid/listbox.py b/urwid/listbox.py index cbe09c4..8bc92d4 100644 --- a/urwid/listbox.py +++ b/urwid/listbox.py @@ -40,13 +40,19 @@ class ListWalker(object): def _modified(self): signals.emit_signal(self, "modified") - + class PollingListWalker(object): # NOT ListWalker subclass def __init__(self, contents): """ contents -- list to poll for changes + + This class is deprecated. Use SimpleListWalker instead. """ + import warnings + warnings.warn("PollingListWalker is deprecated, " + "use SimpleListWalker instead.", DeprecationWarning) + self.contents = contents if not type(contents) == list and not hasattr( contents, '__getitem__' ): |