From 7fc7a6cb82be0ced9fdd1d1b8550e1d53c7b819c Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Tue, 8 Mar 2005 22:03:05 +0000 Subject: [PATCH] show the correct icon in task bar when we have sevrals accounts --- plugins/gtkgui/gtkgui.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/plugins/gtkgui/gtkgui.py b/plugins/gtkgui/gtkgui.py index 768446fcb..0368df3f4 100644 --- a/plugins/gtkgui/gtkgui.py +++ b/plugins/gtkgui/gtkgui.py @@ -2253,6 +2253,12 @@ class roster_window: self.cb.handler_unblock(self.id_signal_cb) statuss = ['offline', 'online', 'away', 'xa', 'dnd', 'invisible'] self.plugin.systray.set_status(statuss[maxi]) + image = self.roster.pixbufs[statuss[maxi]] + if image.get_storage_type() == gtk.IMAGE_ANIMATION: + pixbuf = image.get_animation().get_static_image() + self.roster.window.set_icon(pixbuf) + elif image.get_storage_type() == gtk.IMAGE_PIXBUF: + self.roster.window.set_icon(image.get_pixbuf()) def on_status_changed(self, account, status): """the core tells us that our status has changed""" @@ -3073,12 +3079,6 @@ class plugin: def handle_event_status(self, account, status): #('STATUS', account, status) self.roster.on_status_changed(account, status) - image = self.roster.pixbufs[status] - if image.get_storage_type() == gtk.IMAGE_ANIMATION: - pixbuf = image.get_animation().get_static_image() - self.roster.window.set_icon(pixbuf) - elif image.get_storage_type() == gtk.IMAGE_PIXBUF: - self.roster.window.set_icon(image.get_pixbuf()) def handle_event_notify(self, account, array): #('NOTIFY', account, (jid, status, message, resource, priority, keyID,