Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorYann Leboulanger <asterix@lagaule.org>2006-11-30 12:05:59 +0300
committerYann Leboulanger <asterix@lagaule.org>2006-11-30 12:05:59 +0300
commitff7c612f97f49ffa43eaa0fbb38facde436e37c9 (patch)
tree17381ddc07260fd7fa5678d6092b24f9b98fc48f /src
parentcc09dae0fe14623d42dedfe9f0dd153e5d4dccea (diff)
show groupchat icon in groupchat window banner. see #2702. TODO find muc_active.svg to create 32x32 icons
Diffstat (limited to 'src')
-rw-r--r--src/groupchat_control.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/groupchat_control.py b/src/groupchat_control.py
index 3d81a68f3..1fcf12701 100644
--- a/src/groupchat_control.py
+++ b/src/groupchat_control.py
@@ -417,6 +417,21 @@ class GroupchatControl(ChatControlBase):
for nick in gajim.contacts.get_nick_list(self.account, self.room_jid):
self.draw_contact(nick)
+ def _update_banner_state_image(self):
+ banner_status_img = self.xml.get_widget('gc_banner_status_image')
+ images = gajim.interface.roster.jabber_state_images
+ if images.has_key('32') and images['32'].has_key('muc_active'):
+ muc_icon = images['32']['muc_active']
+ if muc_icon.get_storage_type() != gtk.IMAGE_EMPTY:
+ pix = muc_icon.get_pixbuf()
+ banner_status_img.set_from_pixbuf(pix)
+ return
+ # we need to scale 16x16 to 32x32
+ muc_icon = images['16']['muc_active']
+ pix = muc_icon.get_pixbuf()
+ scaled_pix = pix.scale_simple(32, 32, gtk.gdk.INTERP_BILINEAR)
+ banner_status_img.set_from_pixbuf(scaled_pix)
+
def prepare_context_menu(self):
'''sets compact view menuitem active state
sets sensitivity state for configure_room'''