From 65dde6472057bcf52117303bb2aaf72b00a03caf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Sat, 5 May 2012 09:30:41 +0200 Subject: [PATCH] Improve hack of glitch in position of widgets in notebook By calling display when switching tabs, it loose the value of focused widget because value is reset before the focus-out is proceed. issue2571 review353001 --- tryton/gui/window/view_form/view/form.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tryton/gui/window/view_form/view/form.py b/tryton/gui/window/view_form/view/form.py index 3ed74f4b18..5f5e69b584 100644 --- a/tryton/gui/window/view_form/view/form.py +++ b/tryton/gui/window/view_form/view/form.py @@ -30,6 +30,7 @@ class ViewForm(ParserView): for notebook in notebooks: def switch(notebook, page, page_num): if page_num not in display_done.setdefault(notebook, []): + notebook.grab_focus() display_done[notebook].append(page_num) self.display() notebook.connect('switch-page', switch)