[virt-tools-list] [PATCH virt-manager 2/2] virtManager, create: set the model for autocompletion earlier

Giuseppe Scrivano gscrivan at redhat.com
Fri Jul 4 13:06:18 UTC 2014


it fixes this error:

(virt-manager:11676): Gtk-CRITICAL **: gtk_tree_model_get_iter_first: assertion 'GTK_IS_TREE_MODEL (tree_model)' failed

Signed-off-by: Giuseppe Scrivano <gscrivan at redhat.com>
---
 virtManager/create.py | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/virtManager/create.py b/virtManager/create.py
index 636f48e..f8c5936 100644
--- a/virtManager/create.py
+++ b/virtManager/create.py
@@ -300,6 +300,7 @@ class vmmCreate(vmmGObjectUI):
         entry.set_completion(completion)
         completion.set_text_column(1)
         completion.set_inline_completion(True)
+        completion.set_model(os_variant_model)
 
         # Archtecture
         # [value, label]
@@ -861,9 +862,6 @@ class vmmCreate(vmmGObjectUI):
         # Add action option
         self._add_os_row(model, label=_("Show all OS options"), action=True)
 
-        completion = self.widget("install-os-version-entry").get_completion()
-        completion.set_model(model)
-
     def populate_media_model(self, model, urls):
         model.clear()
         if urls is not None:
-- 
1.9.3




More information about the virt-tools-list mailing list