diff options
author | bdenis <borenko@rambler.ru> | 2013-05-03 20:57:54 +0400 |
---|---|---|
committer | bdenis <borenko@rambler.ru> | 2013-05-03 20:57:54 +0400 |
commit | ecba3290ba6c788fb4a24e25b890390d420a74dd (patch) | |
tree | adaf6f90337316f1e80cf3bba593c39576ebf750 | |
parent | 917c0b3b1b3a24c4a683e296ac1042f3ded5730b (diff) |
Bug fixed. See http://trac-plugins.gajim.org/ticket/55
Version changed.
-rw-r--r-- | appindicator_integration/manifest.ini | 2 | ||||
-rw-r--r-- | appindicator_integration/plugin.py | 11 |
2 files changed, 8 insertions, 5 deletions
diff --git a/appindicator_integration/manifest.ini b/appindicator_integration/manifest.ini index bd9397e..781c237 100644 --- a/appindicator_integration/manifest.ini +++ b/appindicator_integration/manifest.ini @@ -1,7 +1,7 @@ [info] name: Appindicator integration short_name: appindicator_integration -version: 0.1.4 +version: 0.1.5 description: This plugin integrates Gajim with the appindicator. You must have python-appindicator (and Gajim obviously) installed to enable this plugin. Rewriten from Ubuntu Ayatana Integration plugin homepage: http://trac-plugins.gajim.org/wiki/AppindicatorSupportPlugin diff --git a/appindicator_integration/plugin.py b/appindicator_integration/plugin.py index b12df3b..9b5b76d 100644 --- a/appindicator_integration/plugin.py +++ b/appindicator_integration/plugin.py @@ -7,6 +7,7 @@ Rewriten from Ubuntu Ayatana Integration plugin :license: GPLv3 """ # Python +import os import time import gobject #GTK @@ -175,16 +176,18 @@ class AppindicatorIntegrationPlugin(GajimPlugin): if gajim.config.get("show_avatars_in_roster"): pixbuf = gtkgui_helpers.get_avatar_pixbuf_from_cache(jid) if pixbuf not in (None, "ask"): - icon = pixbuf + icon = gtk.Image() + icon.set_from_pixbuf(pixbuf) else: - file_path = get_path_to_generic_or_avatar(jid) + file_path = gtkgui_helpers.get_path_to_generic_or_avatar(jid) if os.path.isfile(file_path): fd = fopen(file_path, 'rb') data = fd.read() - icon = gtkgui_helpers.get_pixbuf_from_data(data) + icon = gtk.Image() + icon.set_from_pixbuf(gtkgui_helpers.get_pixbuf_from_data(data)) item = gtk.ImageMenuItem(contact + " (1)") if icon: - item.setImage(icon) + item.set_image(icon) item.set_always_show_image(True) item.connect("activate", self.event_raise, event) item.show() |