changeset dcb400550f63 in tryton:default
details: https://hg.tryton.org/tryton?cmd=changeset;node=dcb400550f63
description:
        Use idle_add to set active on combobox from match selected of dropdown

        Without this delay, it generates warnings when the selection is done 
with the
        mouse or a SIGABRT when it is done with the keyboard.

        issue8115
        review46781002
diffstat:

 tryton/common/selection.py |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 463422070600 -r dcb400550f63 tryton/common/selection.py
--- a/tryton/common/selection.py        Tue Feb 26 15:41:03 2019 +0100
+++ b/tryton/common/selection.py        Tue Feb 26 15:42:26 2019 +0100
@@ -186,7 +186,7 @@
         model = entry.get_model()
         for i, values in enumerate(model):
             if values[1] == value:
-                entry.set_active(i)
+                gobject.idle_add(entry.set_active, i)
                 break
 
     def get_popdown_value(self, entry, index=1):

Reply via email to