ACE: hide_avatar_of_transport

This commit is contained in:
Nikos Kouremenos 2005-12-02 13:10:02 +00:00
parent 524866db6f
commit 42487409b3
2 changed files with 7 additions and 0 deletions

View file

@ -163,6 +163,7 @@ class Config:
'print_status_in_chats': [opt_bool, True, _('If False, you will no longer see status line in chats when a contact changes his or her status and/or his status message.')],
'log_contact_status_changes': [opt_bool, False],
'restored_messages_color': [opt_str, 'grey'],
'hide_avatar_of_transport': [opt_bool, False],
}
__options_per_key = {

View file

@ -433,6 +433,12 @@ def get_avatar_pixbuf_from_cache(jid):
returns None if there is no image in vcard
returns 'ask' if cached vcard should not be used (user changed his vcard,
so we have new sha) or if we don't have the vcard'''
if gajim.config.get('hide_avatar_of_transport') and\
gajim.jid_is_transport(jid):
# don't show avatar for the transport itself
return None
if jid not in os.listdir(gajim.VCARDPATH):
return 'ask'