Commit ace9fc66 authored by mathieui's avatar mathieui

Fix #1998, #2439 (reset chat state status)

parent c9069ce6
......@@ -3494,6 +3494,10 @@ class Core(object):
return
roster.modified()
contact.error = presence['error']['type'] + ': ' + presence['error']['condition']
# reset chat states status on presence error
tab = self.get_tab_by_name(jid.full, tabs.ConversationTab)
if tab:
tab.remote_wants_chatstates = None
def on_got_offline(self, presence):
"""
......
......@@ -406,6 +406,7 @@ class DynamicConversationTab(ConversationTab):
Unlock the tab from a resource. It is now “associated” with the bare
jid.
"""
self.remote_wants_chatstates = None
if self.locked_resource != None:
self.locked_resource = None
......
......@@ -357,6 +357,7 @@ class PrivateTab(ChatTab):
def deactivate(self, reason=None):
self.on = False
self.remote_wants_chatstates = None
if reason:
self.add_message(txt=reason, typ=2)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment