Skip to content
Snippets Groups Projects
Commit c5b93e0b authored by Yann Leboulanger's avatar Yann Leboulanger
Browse files

open a new tab only if it is not already in the notebook

parent 6ed0c6d0
No related branches found
No related tags found
No related merge requests found
......@@ -609,8 +609,11 @@ class New_message_window:
self.plugin.roster.contacts[self.account][jid] = [user]
self.plugin.roster.add_user_to_roster(user.jid, self.account)
else:
[user] = self.plugin.roster.contacts[self.account][jid]
self.plugin.roster.new_chat(user, self.account)
user = self.plugin.roster.contacts[self.account][jid][0]
if self.plugin.windows[self.account]['chats'].has_key(jid):
self.plugin.windows[self.account]['chats'][jid].active_tab(jid)
else:
self.plugin.roster.new_chat(user, self.account)
widget.get_toplevel().destroy()
def __init__(self, plugin, account):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment