# HG changeset patch # User Goffi # Date 1387641352 -3600 # Node ID c270867a80f9db4e654c988b09745742fe0820c8 # Parent 287ff3e1edd1e784a6613638608927b4614370b5 updated deprecated FlowWidget use diff -r 287ff3e1edd1 -r c270867a80f9 urwid_satext/sat_widgets.py --- a/urwid_satext/sat_widgets.py Sat Dec 21 16:51:14 2013 +0100 +++ b/urwid_satext/sat_widgets.py Sat Dec 21 16:55:52 2013 +0100 @@ -160,8 +160,9 @@ return return super(ModalEdit, self).keypress(size, key) -class SurroundedText(urwid.FlowWidget): +class SurroundedText(urwid.Widget): """Text centered on a repeated character (like a Divider, but with a text in the center)""" + _sizing = frozenset(['flow']) def __init__(self,text,car=utf8decode('─')): self.text=text @@ -456,9 +457,10 @@ return idx+=1 -class List(urwid.FlowWidget): +class List(urwid.Widget): """FlowWidget list, same arguments as GenericList, with an additional one 'max_height'""" signals = ['click','change'] + _sizing = frozenset(['flow']) def __init__(self, options, style=[], max_height=5, align='left', option_type = SelectableText, on_click=None, on_change=None, user_data=None): self.genericList = GenericList(options, style, align, option_type, on_click, on_change, user_data) @@ -832,7 +834,8 @@ ## CONTAINERS ## -class ColumnsRoller(urwid.FlowWidget): +class ColumnsRoller(urwid.Widget): + _sizing = frozenset(['flow']) def __init__(self, widget_list = None, focus_column=0): self.widget_list = widget_list or []