Mercurial > libervia-backend
comparison frontends/primitivus/custom_widgets.py @ 186:33e618d385cf
Primitivus: fixed focus in Input dialog
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 18 Aug 2010 17:26:34 +0800 |
parents | 556c2bd7c344 |
children | 879beacb8e16 |
comparison
equal
deleted
inserted
replaced
185:fd2db62ea5eb | 186:33e618d385cf |
---|---|
720 | 720 |
721 def __init__(self, title, instrucions, style=['OK/CANCEL'], default_txt = '', **kwargs): | 721 def __init__(self, title, instrucions, style=['OK/CANCEL'], default_txt = '', **kwargs): |
722 instr_wid = urwid.Text(instrucions+':') | 722 instr_wid = urwid.Text(instrucions+':') |
723 edit_box = AdvancedEdit(edit_text=default_txt) | 723 edit_box = AdvancedEdit(edit_text=default_txt) |
724 GenericDialog.__init__(self, [instr_wid,edit_box], title, style, ok_value=edit_box, **kwargs) | 724 GenericDialog.__init__(self, [instr_wid,edit_box], title, style, ok_value=edit_box, **kwargs) |
725 self._w.base_widget.set_focus('body') | |
725 | 726 |
726 class ConfirmDialog(GenericDialog): | 727 class ConfirmDialog(GenericDialog): |
727 """Dialog with buttons for confirm or cancel an action""" | 728 """Dialog with buttons for confirm or cancel an action""" |
728 | 729 |
729 def __init__(self, title, style=['YES/NO'], **kwargs): | 730 def __init__(self, title, style=['YES/NO'], **kwargs): |