summaryrefslogtreecommitdiff
path: root/protocols/WhatsApp/src/proto.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2022-10-26 17:06:04 +0300
committerGeorge Hazan <ghazan@miranda.im>2022-10-26 17:06:04 +0300
commit9d7fc83aa463676e0820a056fa6632711b50f790 (patch)
tree14c5f7ea806e315adf4d0daef4b044ecfc751c26 /protocols/WhatsApp/src/proto.cpp
parent976a3f93925a28feb107ae505834ce7a728a42b8 (diff)
WhatsApp: typing notification
Diffstat (limited to 'protocols/WhatsApp/src/proto.cpp')
-rw-r--r--protocols/WhatsApp/src/proto.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/protocols/WhatsApp/src/proto.cpp b/protocols/WhatsApp/src/proto.cpp
index 96e379ed73..25f1671936 100644
--- a/protocols/WhatsApp/src/proto.cpp
+++ b/protocols/WhatsApp/src/proto.cpp
@@ -217,11 +217,13 @@ int WhatsAppProto::SendMsg(MCONTACT hContact, int, const char *pszMsg)
return SendTextMessage(jid, pszMsg);
}
-int WhatsAppProto::UserIsTyping(MCONTACT hContact, int)
+int WhatsAppProto::UserIsTyping(MCONTACT hContact, int type)
{
if (hContact && isOnline()) {
ptrA jid(getStringA(hContact, DBKEY_ID));
if (jid && isOnline()) {
+ WSSendNode(
+ WANode("chatstates") << CHAR_PARAM("to", jid) << XCHILD((type == PROTOTYPE_SELFTYPING_ON) ? "composing" : "paused"));
}
}