Mercurial > libervia-backend
diff frontends/primitivus/xmlui.py @ 192:879beacb8e16
Primitivus: major changes in SelectableText, menu can now be used with mouse, TabsContainer show wich tab is selected
- SelectableText is a WidgetWrap of urwid.Text, and manage attributes and complexe combination like urwid.Text (list of tuples (attribute,text))
- Menu now use a ColumnsRoller, and can't anymore be displayed on 2 rows, avoiding potential bug when display MenuBox
- Mouse can be used in menu. Right click on MenuBox make it disappear
- Tab container now display which tab is selected by putting a 'title' attribute on the corresponding button
/!\ as SelectableText is heavily used, there can be regressions
author | Goffi <goffi@goffi.org> |
---|---|
date | Thu, 19 Aug 2010 21:11:22 +0800 |
parents | 9ee4a1d0d7fb |
children | 3198bfd66daa |
line wrap: on
line diff
--- a/frontends/primitivus/xmlui.py Wed Aug 18 22:34:35 2010 +0800 +++ b/frontends/primitivus/xmlui.py Thu Aug 19 21:11:22 2010 +0800 @@ -232,7 +232,7 @@ ctrl = self.ctrl_list[ctrl_name] if isinstance(ctrl['control'], custom_widgets.List): data.append((ctrl_name, ctrl['control'].getSelectedValue())) - if isinstance(ctrl['control'], urwid.CheckBox): + elif isinstance(ctrl['control'], urwid.CheckBox): data.append((ctrl_name, "true" if ctrl['control'].get_state() else "false")) else: data.append((ctrl_name, ctrl['control'].get_edit_text()))