Mercurial > libervia-desktop-kivy
diff cagou/core/widgets_handler.py @ 362:e1f56257cabc
core (widgets handler): use widget set in set_widget as selected_widget if selected_widget is None
author | Goffi <goffi@goffi.org> |
---|---|
date | Mon, 27 Jan 2020 21:17:08 +0100 |
parents | 8b6621cc142c |
children | 9c6fe392d623 |
line wrap: on
line diff
--- a/cagou/core/widgets_handler.py Sat Jan 18 23:12:52 2020 +0100 +++ b/cagou/core/widgets_handler.py Mon Jan 27 21:17:08 2020 +0100 @@ -613,6 +613,8 @@ WidgetsHandlerLayout.count += 1 if wid is None: wid = self.default_widget + if G.host.selected_widget is None: + G.host.selected_widget = wid wrapper = WHWrapper(_wid_idx=WidgetsHandlerLayout.count) log.debug("WHWrapper created ({})".format(wrapper._wid_idx)) wrapper.set_widget(wid)