Commit 1255e956 authored by Saul Ibarra's avatar Saul Ibarra

Render status messages appropriately

parent 0f0a3c2e
......@@ -2080,7 +2080,11 @@ class ChatWindow(base_class, ui_class, ColorHelperMixin):
else:
sender = ChatSender(message.sender.display_name or session.name, uri, session.icon.filename)
session.chat_widget.add_message(ChatMessage(content, sender, 'incoming'))
is_status_message = any(h.name=='Message-Type' and h.value=='status' and h.namespace=='urn:ag-projects:xml:ns:cpim' for h in message.additional_headers)
if is_status_message:
session.chat_widget.add_message(ChatStatus(content))
else:
session.chat_widget.add_message(ChatMessage(content, sender, 'incoming'))
session.remote_composing = False
settings = SIPSimpleSettings()
......
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