Merged revisions 5044-5051 via svnmerge from
svn://svn.gajim.org/gajim/trunk ........ r5044 | asterix | 2006-01-07 17:17:05 -0700 (Sat, 07 Jan 2006) | 2 lines open the vcard on the real jid in gc if we know it ........ r5045 | asterix | 2006-01-07 17:23:33 -0700 (Sat, 07 Jan 2006) | 2 lines use real jid when we open a pm message if we know it ........ r5046 | asterix | 2006-01-07 17:27:38 -0700 (Sat, 07 Jan 2006) | 2 lines get contact from the self.contacts so that even if it's pm we get a Contact instance ........ r5047 | asterix | 2006-01-07 17:30:58 -0700 (Sat, 07 Jan 2006) | 2 lines don't ask vcard when we get an error presence ........ r5048 | asterix | 2006-01-07 17:39:05 -0700 (Sat, 07 Jan 2006) | 2 lines fix logic in contacts.add_contact() function ........ r5049 | asterix | 2006-01-07 18:08:21 -0700 (Sat, 07 Jan 2006) | 2 lines do not use underline in join_gc menu ........ r5050 | asterix | 2006-01-07 18:12:09 -0700 (Sat, 07 Jan 2006) | 2 lines don't use underline in all menus that contact an account name ........ r5051 | asterix | 2006-01-07 18:18:16 -0700 (Sat, 07 Jan 2006) | 2 lines add an ACE option to hide the avatar in tabbed chat window ........
This commit is contained in:
parent
eb27dbe61a
commit
c033a670d1
|
@ -464,7 +464,7 @@ class Chat:
|
||||||
|
|
||||||
if self.widget_name == 'tabbed_chat_window':
|
if self.widget_name == 'tabbed_chat_window':
|
||||||
jid = self.get_active_jid()
|
jid = self.get_active_jid()
|
||||||
c = gajim.contacts.get_first_contact_from_jid(self.account, jid)
|
c = self.contacts[jid]
|
||||||
if _('not in the roster') in c.groups: # for add_to_roster_menuitem
|
if _('not in the roster') in c.groups: # for add_to_roster_menuitem
|
||||||
childs[5].show()
|
childs[5].show()
|
||||||
childs[5].set_no_show_all(False)
|
childs[5].set_no_show_all(False)
|
||||||
|
@ -502,7 +502,7 @@ class Chat:
|
||||||
childs[3].set_active(isactive)
|
childs[3].set_active(isactive)
|
||||||
childs[3].set_property('sensitive', issensitive)
|
childs[3].set_property('sensitive', issensitive)
|
||||||
# If we don't have resource, we can't do file transfert
|
# If we don't have resource, we can't do file transfert
|
||||||
c = gajim.contacts.get_first_contact_from_jid(self.account, jid)
|
c = self.contacts[jid]
|
||||||
if not c.resource:
|
if not c.resource:
|
||||||
childs[2].set_sensitive(False)
|
childs[2].set_sensitive(False)
|
||||||
else:
|
else:
|
||||||
|
|
|
@ -1179,6 +1179,9 @@ class ChatControl(ChatControlBase):
|
||||||
self.send_chatstate('inactive', self.contact)
|
self.send_chatstate('inactive', self.contact)
|
||||||
|
|
||||||
def show_avatar(self, resource = None):
|
def show_avatar(self, resource = None):
|
||||||
|
if not gajim.config.get('show_avatar_in_chat'):
|
||||||
|
return
|
||||||
|
|
||||||
jid = self.contact.jid
|
jid = self.contact.jid
|
||||||
jid_with_resource = jid
|
jid_with_resource = jid
|
||||||
if resource:
|
if resource:
|
||||||
|
|
|
@ -186,6 +186,7 @@ class Config:
|
||||||
'send_sha_in_gc_presence': [opt_bool, True, _('Jabberd1.4 does not like sha info when one join a password protected room. Turn this option to False to stop sending sha info in groupchat presences')],
|
'send_sha_in_gc_presence': [opt_bool, True, _('Jabberd1.4 does not like sha info when one join a password protected room. Turn this option to False to stop sending sha info in groupchat presences')],
|
||||||
'one_message_window': [opt_str, 'never',
|
'one_message_window': [opt_str, 'never',
|
||||||
_('Controls the window where new messages are placed.\n\'always\' - All messages are sent to a single window.\n\'never\' - All messages get their own window.\n\'peracct\' - Messages for each account are sent to a specific window.\n\'pertype\' - Each message type (e.g., chats vs. groupchats) are sent to a specific window. Note, changing this option requires restarting Gajim before the changes will take effect')],
|
_('Controls the window where new messages are placed.\n\'always\' - All messages are sent to a single window.\n\'never\' - All messages get their own window.\n\'peracct\' - Messages for each account are sent to a specific window.\n\'pertype\' - Each message type (e.g., chats vs. groupchats) are sent to a specific window. Note, changing this option requires restarting Gajim before the changes will take effect')],
|
||||||
|
'show_avatar_in_chat': [opt_bool, True, _('If False, you will no longer see the avatar in the chat window')],
|
||||||
}
|
}
|
||||||
|
|
||||||
__options_per_key = {
|
__options_per_key = {
|
||||||
|
|
|
@ -531,7 +531,7 @@ class Connection:
|
||||||
self.dispatch('ERROR_ANSWER', ('', jid_stripped,
|
self.dispatch('ERROR_ANSWER', ('', jid_stripped,
|
||||||
errmsg, errcode))
|
errmsg, errcode))
|
||||||
|
|
||||||
if avatar_sha:
|
if avatar_sha and ptype != 'error':
|
||||||
if self.vcard_shas.has_key(jid_stripped):
|
if self.vcard_shas.has_key(jid_stripped):
|
||||||
if avatar_sha != self.vcard_shas[jid_stripped]:
|
if avatar_sha != self.vcard_shas[jid_stripped]:
|
||||||
# avatar has been updated
|
# avatar has been updated
|
||||||
|
|
|
@ -122,12 +122,16 @@ class Contacts:
|
||||||
if not self._contacts[account].has_key(contact.jid):
|
if not self._contacts[account].has_key(contact.jid):
|
||||||
self._contacts[account][contact.jid] = [contact]
|
self._contacts[account][contact.jid] = [contact]
|
||||||
return
|
return
|
||||||
|
contacts = self._contacts[account][contact.jid]
|
||||||
|
# We had only one that was offline, remove it
|
||||||
|
if len(contacts) == 1 and contacts[0].show == 'offline':
|
||||||
|
self.remove_contact(account, contacts[0])
|
||||||
# If same JID with same resource already exists, use the new one
|
# If same JID with same resource already exists, use the new one
|
||||||
for c in self._contacts[account][contact.jid]:
|
for c in contacts:
|
||||||
if c.resource == contact.resource:
|
if c.resource == contact.resource:
|
||||||
self.remove_contact(account, c)
|
self.remove_contact(account, c)
|
||||||
break
|
break
|
||||||
self._contacts[account][contact.jid].append(contact)
|
contacts.append(contact)
|
||||||
|
|
||||||
def remove_contact(self, account, contact):
|
def remove_contact(self, account, contact):
|
||||||
if not self._contacts.has_key(account):
|
if not self._contacts.has_key(account):
|
||||||
|
@ -223,7 +227,13 @@ class Contacts:
|
||||||
|
|
||||||
def contact_from_gc_contact(self, gc_contact):
|
def contact_from_gc_contact(self, gc_contact):
|
||||||
'''Create a Contact instance from a GC_Contact instance'''
|
'''Create a Contact instance from a GC_Contact instance'''
|
||||||
return Contact(jid = gc_contact.get_full_jid(), name = gc_contact.name,
|
if gc_contact.jid:
|
||||||
|
jid = gc_contact.jid
|
||||||
|
resource = gc_contact.resource
|
||||||
|
else:
|
||||||
|
jid = gc_contact.get_full_jid()
|
||||||
|
resource = ''
|
||||||
|
return Contact(jid = jid, resource = resource, name = gc_contact.name,
|
||||||
groups = ['none'], show = gc_contact.show, status = gc_contact.status,
|
groups = ['none'], show = gc_contact.show, status = gc_contact.status,
|
||||||
sub = 'none')
|
sub = 'none')
|
||||||
|
|
||||||
|
|
|
@ -330,10 +330,7 @@ class GroupchatControl(ChatControlBase):
|
||||||
gajim.interface.systray.add_jid(fjid, self.account, 'pm')
|
gajim.interface.systray.add_jid(fjid, self.account, 'pm')
|
||||||
self.parent_win.show_title()
|
self.parent_win.show_title()
|
||||||
else:
|
else:
|
||||||
gc_c = gajim.contacts.get_gc_contact(self.account, self.room_jid, nick)
|
self._start_private_message(nick)
|
||||||
c = gajim.contacts.contact_from_gc_contact(gc_c)
|
|
||||||
print "creating PM chat"
|
|
||||||
gajim.interface.roster.new_chat(c, self.account, private_chat = True)
|
|
||||||
# Scroll to line
|
# Scroll to line
|
||||||
self.list_treeview.expand_row(path[0:1], False)
|
self.list_treeview.expand_row(path[0:1], False)
|
||||||
self.list_treeview.scroll_to_cell(path)
|
self.list_treeview.scroll_to_cell(path)
|
||||||
|
@ -577,21 +574,9 @@ class GroupchatControl(ChatControlBase):
|
||||||
nick = model[iter][C_NICK].decode('utf-8')
|
nick = model[iter][C_NICK].decode('utf-8')
|
||||||
fjid = gajim.construct_fjid(self.room_jid, nick) # 'fake' jid
|
fjid = gajim.construct_fjid(self.room_jid, nick) # 'fake' jid
|
||||||
|
|
||||||
chat_win = gajim.interface.msg_win_mgr.get_window(fjid)
|
self._start_private_message(nick)
|
||||||
if not chat_win:
|
|
||||||
gc_c = gajim.contacts.get_gc_contact(self.account, self.room_jid, nick)
|
|
||||||
c = gajim.contacts.contact_from_gc_contact(gc_c)
|
|
||||||
print "creating PM chat"
|
|
||||||
gajim.interface.roster.new_chat(c, self.account, private_chat = True)
|
|
||||||
chat_win = gajim.interface.msg_win_mgr.get_window(fjid)
|
|
||||||
chat_control = chat_win.get_control(fjid)
|
|
||||||
|
|
||||||
#make active here in case we need to send a message
|
|
||||||
chat_win.set_active_tab(fjid)
|
|
||||||
|
|
||||||
if msg:
|
if msg:
|
||||||
chat_control.send_message(msg)
|
chat_control.send_message(msg)
|
||||||
chat_win.window.present()
|
|
||||||
|
|
||||||
def draw_contact(self, nick, selected=False, focus=False):
|
def draw_contact(self, nick, selected=False, focus=False):
|
||||||
iter = self.get_contact_iter(nick)
|
iter = self.get_contact_iter(nick)
|
||||||
|
@ -1333,7 +1318,9 @@ class GroupchatControl(ChatControlBase):
|
||||||
menu.show_all()
|
menu.show_all()
|
||||||
|
|
||||||
def _start_private_message(self, nick):
|
def _start_private_message(self, nick):
|
||||||
nick_jid = gajim.construct_fjid(self.room_jid, nick)
|
gc_c = gajim.contacts.get_gc_contact(self.account, self.room_jid, nick)
|
||||||
|
c = gajim.contacts.contact_from_gc_contact(gc_c)
|
||||||
|
nick_jid = c.jid
|
||||||
|
|
||||||
win = gajim.interface.msg_win_mgr.get_window(nick_jid)
|
win = gajim.interface.msg_win_mgr.get_window(nick_jid)
|
||||||
if not win:
|
if not win:
|
||||||
|
@ -1355,7 +1342,7 @@ class GroupchatControl(ChatControlBase):
|
||||||
widget.expand_row(path, False)
|
widget.expand_row(path, False)
|
||||||
else: # We want to send a private message
|
else: # We want to send a private message
|
||||||
nick = model[iter][C_NICK].decode('utf-8')
|
nick = model[iter][C_NICK].decode('utf-8')
|
||||||
win = self._start_private_message(nick)
|
self._start_private_message(nick)
|
||||||
|
|
||||||
def on_list_treeview_button_press_event(self, widget, event):
|
def on_list_treeview_button_press_event(self, widget, event):
|
||||||
'''popup user's group's or agent menu'''
|
'''popup user's group's or agent menu'''
|
||||||
|
@ -1385,17 +1372,7 @@ class GroupchatControl(ChatControlBase):
|
||||||
iter = model.get_iter(path)
|
iter = model.get_iter(path)
|
||||||
if len(path) == 2:
|
if len(path) == 2:
|
||||||
nick = model[iter][C_NICK].decode('utf-8')
|
nick = model[iter][C_NICK].decode('utf-8')
|
||||||
fjid = gajim.construct_fjid(self.room_jid, nick)
|
self._start_private_message(nick)
|
||||||
win = gajim.interface.msg_win_mgr.get_window(fjid)
|
|
||||||
if not win:
|
|
||||||
gc_c = gajim.contacts.get_gc_contact(self.account, self.room_jid,
|
|
||||||
nick)
|
|
||||||
c = gajim.contacts.contact_from_gc_contact(gc_c)
|
|
||||||
gajim.interface.roster.new_chat(c, self.account,
|
|
||||||
private_chat = True)
|
|
||||||
win = gajim.interface.msg_win_mgr.get_window(fjid)
|
|
||||||
win.set_active_tab(fjid)
|
|
||||||
win.window.present()
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
elif event.button == 1: # left click
|
elif event.button == 1: # left click
|
||||||
|
@ -1526,13 +1503,18 @@ class GroupchatControl(ChatControlBase):
|
||||||
def on_info(self, widget, ck):
|
def on_info(self, widget, ck):
|
||||||
'''Call vcard_information_window class to display user's information'''
|
'''Call vcard_information_window class to display user's information'''
|
||||||
c = gajim.contacts.get_gc_contact(self.account, self.room_jid, nick)
|
c = gajim.contacts.get_gc_contact(self.account, self.room_jid, nick)
|
||||||
jid = c.get_full_jid()
|
# jid = c.get_full_jid()
|
||||||
if gajim.interface.instances[self.account]['infos'].has_key(jid):
|
# if gajim.interface.instances[self.account]['infos'].has_key(jid):
|
||||||
gajim.interface.instances[self.account]['infos'][jid].window.present()
|
# gajim.interface.instances[self.account]['infos'][jid].window.present()
|
||||||
|
# we create a Contact instance
|
||||||
|
c2 = gajim.contacts.contact_from_gc_contact(c)
|
||||||
|
if gajim.interface.instances[self.account]['infos'].has_key(c2.jid):
|
||||||
|
gajim.interface.instances[self.account]['infos'][c2.jid].window.present()
|
||||||
else:
|
else:
|
||||||
# we create a Contact instance
|
# # we create a Contact instance
|
||||||
c2 = gajim.contacts.contact_from_gc_contact(c)
|
# c2 = gajim.contacts.contact_from_gc_contact(c)
|
||||||
gajim.interface.instances[self.account]['infos'][jid] = \
|
# gajim.interface.instances[self.account]['infos'][jid] = \
|
||||||
|
gajim.interface.instances[self.account]['infos'][c2.jid] = \
|
||||||
vcard.VcardWindow(c2, self.account, False)
|
vcard.VcardWindow(c2, self.account, False)
|
||||||
|
|
||||||
def on_history(self, widget, ck):
|
def on_history(self, widget, ck):
|
||||||
|
|
|
@ -1162,13 +1162,12 @@ current room topic.') % command, room_jid)
|
||||||
def on_info(self, widget, room_jid, nick):
|
def on_info(self, widget, room_jid, nick):
|
||||||
'''Call vcard_information_window class to display user's information'''
|
'''Call vcard_information_window class to display user's information'''
|
||||||
c = gajim.contacts.get_gc_contact(self.account, room_jid, nick)
|
c = gajim.contacts.get_gc_contact(self.account, room_jid, nick)
|
||||||
jid = c.get_full_jid()
|
# we create a Contact instance
|
||||||
if gajim.interface.instances[self.account]['infos'].has_key(jid):
|
c2 = gajim.contacts.contact_from_gc_contact(c)
|
||||||
gajim.interface.instances[self.account]['infos'][jid].window.present()
|
if gajim.interface.instances[self.account]['infos'].has_key(c2.jid):
|
||||||
|
gajim.interface.instances[self.account]['infos'][c2.jid].window.present()
|
||||||
else:
|
else:
|
||||||
# we create a Contact instance
|
gajim.interface.instances[self.account]['infos'][c2.jid] = \
|
||||||
c2 = gajim.contacts.contact_from_gc_contact(c)
|
|
||||||
gajim.interface.instances[self.account]['infos'][jid] = \
|
|
||||||
vcard.VcardWindow(c2, self.account, False)
|
vcard.VcardWindow(c2, self.account, False)
|
||||||
|
|
||||||
def on_history(self, widget, room_jid, nick):
|
def on_history(self, widget, room_jid, nick):
|
||||||
|
@ -1676,14 +1675,13 @@ current room topic.') % command, room_jid)
|
||||||
else: # We want to send a private message
|
else: # We want to send a private message
|
||||||
room_jid = self.get_active_jid()
|
room_jid = self.get_active_jid()
|
||||||
nick = model[iter][C_NICK].decode('utf-8')
|
nick = model[iter][C_NICK].decode('utf-8')
|
||||||
jid = gajim.construct_fjid(room_jid, nick)
|
gc_c = gajim.contacts.get_gc_contact(self.account, room_jid, nick)
|
||||||
# FIXME
|
c = gajim.contacts.contact_from_gc_contact(gc_c)
|
||||||
if not gajim.interface.instances[self.account]['chats'].has_key(jid):
|
if not gajim.interface.instances[self.account]['chats'].has_key(c.jid):
|
||||||
gc_c = gajim.contacts.get_gc_contact(self.account, room_jid, nick)
|
|
||||||
c = gajim.contacts.contact_from_gc_contact(gc_c)
|
|
||||||
gajim.interface.roster.new_chat(c, self.account)
|
gajim.interface.roster.new_chat(c, self.account)
|
||||||
gajim.interface.instances[self.account]['chats'][jid].set_active_tab(jid)
|
gajim.interface.instances[self.account]['chats'][c.jid].set_active_tab(
|
||||||
gajim.interface.instances[self.account]['chats'][jid].window.present()
|
c.jid)
|
||||||
|
gajim.interface.instances[self.account]['chats'][c.jid].window.present()
|
||||||
|
|
||||||
def on_list_treeview_row_expanded(self, widget, iter, path):
|
def on_list_treeview_row_expanded(self, widget, iter, path):
|
||||||
'''When a row is expanded: change the icon of the arrow'''
|
'''When a row is expanded: change the icon of the arrow'''
|
||||||
|
|
|
@ -457,33 +457,34 @@ class RosterWindow:
|
||||||
self.new_message_menuitem_handler_id)
|
self.new_message_menuitem_handler_id)
|
||||||
self.new_message_menuitem_handler_id = None
|
self.new_message_menuitem_handler_id = None
|
||||||
|
|
||||||
#remove the existing submenus
|
# remove the existing submenus
|
||||||
add_new_contact_menuitem.remove_submenu()
|
add_new_contact_menuitem.remove_submenu()
|
||||||
service_disco_menuitem.remove_submenu()
|
service_disco_menuitem.remove_submenu()
|
||||||
join_gc_menuitem.remove_submenu()
|
join_gc_menuitem.remove_submenu()
|
||||||
new_message_menuitem.remove_submenu()
|
new_message_menuitem.remove_submenu()
|
||||||
advanced_menuitem.remove_submenu()
|
advanced_menuitem.remove_submenu()
|
||||||
|
|
||||||
#remove the existing accelerator
|
# remove the existing accelerator
|
||||||
if self.have_new_message_accel:
|
if self.have_new_message_accel:
|
||||||
ag = gtk.accel_groups_from_object(self.window)[0]
|
ag = gtk.accel_groups_from_object(self.window)[0]
|
||||||
new_message_menuitem.remove_accelerator(ag, gtk.keysyms.n,
|
new_message_menuitem.remove_accelerator(ag, gtk.keysyms.n,
|
||||||
gtk.gdk.CONTROL_MASK)
|
gtk.gdk.CONTROL_MASK)
|
||||||
self.have_new_message_accel = False
|
self.have_new_message_accel = False
|
||||||
|
|
||||||
#join gc
|
# join gc
|
||||||
sub_menu = gtk.Menu()
|
sub_menu = gtk.Menu()
|
||||||
join_gc_menuitem.set_submenu(sub_menu)
|
join_gc_menuitem.set_submenu(sub_menu)
|
||||||
at_least_one_account_connected = False
|
at_least_one_account_connected = False
|
||||||
multiple_accounts = len(gajim.connections) >= 2 #FIXME: stop using bool var here
|
multiple_accounts = len(gajim.connections) >= 2 #FIXME: stop using bool var here
|
||||||
for account in gajim.connections:
|
for account in gajim.connections:
|
||||||
if gajim.connections[account].connected <= 1: #if offline or connecting
|
if gajim.connections[account].connected <= 1: # if offline or connecting
|
||||||
continue
|
continue
|
||||||
if not at_least_one_account_connected:
|
if not at_least_one_account_connected:
|
||||||
at_least_one_account_connected = True
|
at_least_one_account_connected = True
|
||||||
if multiple_accounts:
|
if multiple_accounts:
|
||||||
label = gtk.Label()
|
label = gtk.Label()
|
||||||
label.set_markup('<u>' + account.upper() +'</u>')
|
label.set_markup('<u>' + account.upper() +'</u>')
|
||||||
|
label.set_use_underline(False)
|
||||||
item = gtk.MenuItem()
|
item = gtk.MenuItem()
|
||||||
item.add(label)
|
item.add(label)
|
||||||
item.connect('state-changed', self.on_bm_header_changed_state)
|
item.connect('state-changed', self.on_bm_header_changed_state)
|
||||||
|
@ -494,7 +495,7 @@ class RosterWindow:
|
||||||
sub_menu.append(item)
|
sub_menu.append(item)
|
||||||
|
|
||||||
for bookmark in gajim.connections[account].bookmarks:
|
for bookmark in gajim.connections[account].bookmarks:
|
||||||
item = gtk.MenuItem(bookmark['name'])
|
item = gtk.MenuItem(bookmark['name'], False) # Do not use underline
|
||||||
item.connect('activate', self.on_bookmark_menuitem_activate,
|
item.connect('activate', self.on_bookmark_menuitem_activate,
|
||||||
account, bookmark)
|
account, bookmark)
|
||||||
sub_menu.append(item)
|
sub_menu.append(item)
|
||||||
|
@ -519,7 +520,7 @@ class RosterWindow:
|
||||||
if gajim.connections[account].connected <= 1:
|
if gajim.connections[account].connected <= 1:
|
||||||
#if offline or connecting
|
#if offline or connecting
|
||||||
continue
|
continue
|
||||||
item = gtk.MenuItem(_('to %s account') % account)
|
item = gtk.MenuItem(_('to %s account') % account, False)
|
||||||
sub_menu.append(item)
|
sub_menu.append(item)
|
||||||
item.connect('activate', self.on_add_new_contact, account)
|
item.connect('activate', self.on_add_new_contact, account)
|
||||||
add_new_contact_menuitem.set_submenu(sub_menu)
|
add_new_contact_menuitem.set_submenu(sub_menu)
|
||||||
|
@ -531,7 +532,7 @@ class RosterWindow:
|
||||||
if gajim.connections[account].connected <= 1:
|
if gajim.connections[account].connected <= 1:
|
||||||
#if offline or connecting
|
#if offline or connecting
|
||||||
continue
|
continue
|
||||||
item = gtk.MenuItem(_('using %s account') % account)
|
item = gtk.MenuItem(_('using %s account') % account, False)
|
||||||
sub_menu.append(item)
|
sub_menu.append(item)
|
||||||
item.connect('activate', self.on_service_disco_menuitem_activate,
|
item.connect('activate', self.on_service_disco_menuitem_activate,
|
||||||
account)
|
account)
|
||||||
|
@ -545,7 +546,7 @@ class RosterWindow:
|
||||||
if gajim.connections[account].connected <= 1:
|
if gajim.connections[account].connected <= 1:
|
||||||
#if offline or connecting
|
#if offline or connecting
|
||||||
continue
|
continue
|
||||||
item = gtk.MenuItem(_('using account %s') % account)
|
item = gtk.MenuItem(_('using account %s') % account, False)
|
||||||
sub_menu.append(item)
|
sub_menu.append(item)
|
||||||
item.connect('activate', self.on_new_message_menuitem_activate,
|
item.connect('activate', self.on_new_message_menuitem_activate,
|
||||||
account)
|
account)
|
||||||
|
@ -556,7 +557,7 @@ class RosterWindow:
|
||||||
#Advanced Actions
|
#Advanced Actions
|
||||||
sub_menu = gtk.Menu()
|
sub_menu = gtk.Menu()
|
||||||
for account in gajim.connections:
|
for account in gajim.connections:
|
||||||
item = gtk.MenuItem(_('for account %s') % account)
|
item = gtk.MenuItem(_('for account %s') % account, False)
|
||||||
sub_menu.append(item)
|
sub_menu.append(item)
|
||||||
advanced_menuitem_menu = self.get_and_connect_advanced_menuitem_menu(
|
advanced_menuitem_menu = self.get_and_connect_advanced_menuitem_menu(
|
||||||
account)
|
account)
|
||||||
|
|
|
@ -301,6 +301,8 @@ class TabbedChatWindow(chat.Chat):
|
||||||
|
|
||||||
def show_avatar(self, jid, resource):
|
def show_avatar(self, jid, resource):
|
||||||
# Get the XML instance
|
# Get the XML instance
|
||||||
|
if not gajim.config.get('show_avatar_in_chat'):
|
||||||
|
return
|
||||||
jid_with_resource = jid
|
jid_with_resource = jid
|
||||||
if resource:
|
if resource:
|
||||||
jid_with_resource += '/' + resource
|
jid_with_resource += '/' + resource
|
||||||
|
|
Loading…
Reference in New Issue