[gnome-builder] python-gi-imports-completion: use namespace icon



commit 68cac7dfa70096a34d918124f60e97c9eb33f2a3
Author: Christian Hergert <chergert redhat com>
Date:   Mon May 23 23:28:55 2016 +0300

    python-gi-imports-completion: use namespace icon

 .../python_gi_imports_completion.py                |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/plugins/python-gi-imports-completion/python_gi_imports_completion.py 
b/plugins/python-gi-imports-completion/python_gi_imports_completion.py
index e5210a0..753a31a 100644
--- a/plugins/python-gi-imports-completion/python_gi_imports_completion.py
+++ b/plugins/python-gi-imports-completion/python_gi_imports_completion.py
@@ -29,6 +29,7 @@ gi.require_version('GIRepository', '2.0')
 gi.require_version('Ide', '1.0')
 
 from gi.repository import GIRepository
+from gi.repository import Gio
 from gi.repository import GLib
 from gi.repository import GObject
 from gi.repository import Gtk
@@ -38,6 +39,8 @@ from gi.repository import Ide
 # 2 minutes
 CACHE_EXPIRE_USEC = 2 * 60 * 1000 * 1000
 
+_NamespaceIcon = Gio.ThemedIcon.new('lang-namespace-symbolic')
+
 class CompletionProvider(Ide.Object,
                          GtkSource.CompletionProvider,
                          Ide.CompletionProvider):
@@ -136,8 +139,8 @@ class CompletionProposal(GObject.Object, GtkSource.CompletionProposal):
     def do_get_text(self):
         return self.complete
 
-    def do_get_icon_name(self):
-        return 'lang-include-symbolic'
+    def do_get_gicon(self):
+        return _NamespaceIcon
 
     def do_hash(self):
         return hash(self.completion)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]