diff options
author | George Hazan <ghazan@miranda.im> | 2020-02-29 21:32:45 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-02-29 21:32:45 +0300 |
commit | f0173fd8343e7f1469b40ea8372f6b951846f63b (patch) | |
tree | 05a775d2c18d8eb43d7172bd4e13203d75e83e0a /protocols/JabberG/src/jabber_thread.cpp | |
parent | 5792d59c3ed577096556b744a51bb375e59c325f (diff) |
MessageState: rewritten from scratch to work
Diffstat (limited to 'protocols/JabberG/src/jabber_thread.cpp')
-rwxr-xr-x | protocols/JabberG/src/jabber_thread.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/protocols/JabberG/src/jabber_thread.cpp b/protocols/JabberG/src/jabber_thread.cpp index 51ef853e94..432510910c 100755 --- a/protocols/JabberG/src/jabber_thread.cpp +++ b/protocols/JabberG/src/jabber_thread.cpp @@ -1198,13 +1198,14 @@ void CJabberProto::OnProcessMessage(const TiXmlElement *node, ThreadData *info) nPacketId = JabberGetPacketID(node);
if (nPacketId != -1)
ProtoBroadcastAck(hContact, ACKTYPE_MESSAGE, ACKRESULT_SUCCESS, (HANDLE)nPacketId);
+
+ if (g_plugin.bMessageState)
+ CallService(MS_MESSAGESTATE_UPDATE, hContact, MRD_TYPE_DELIVERED);
}
if (auto *n = XmlGetChildByTag(node, "displayed", "xmlns", JABBER_FEAT_CHAT_MARKERS))
- if (g_plugin.bMessageState) {
- MessageReadData readData(time(0), MRD_TYPE_READTIME);
- CallService(MS_MESSAGESTATE_UPDATE, hContact, (LPARAM)&readData);
- }
+ if (g_plugin.bMessageState)
+ CallService(MS_MESSAGESTATE_UPDATE, hContact, MRD_TYPE_READ);
JabberReadXep203delay(node, msgTime);
|