From 76e343ab968fb6f194333fb0ec7057eaf621bcd4 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sat, 25 Jul 2015 13:19:35 +0000 Subject: an option added to use the remote timestamps for messages (patch by Cassio is well received) git-svn-id: http://svn.miranda-ng.org/main/trunk@14684 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/WhatsApp/src/messages.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'protocols/WhatsApp/src/messages.cpp') diff --git a/protocols/WhatsApp/src/messages.cpp b/protocols/WhatsApp/src/messages.cpp index 452215b90a..837b13ef01 100644 --- a/protocols/WhatsApp/src/messages.cpp +++ b/protocols/WhatsApp/src/messages.cpp @@ -31,7 +31,11 @@ void WhatsAppProto::onMessageForMe(const FMessage &pMsg) PROTORECVEVENT recv = { 0 }; recv.szMessage = const_cast(msg.c_str()); - recv.timestamp = time(NULL); + if (getByte(WHATSAPP_KEY_USE_REMOTE_TIME, 0)) + recv.timestamp = pMsg.timestamp; + else + recv.timestamp = time(NULL); + ProtoChainRecvMsg(hContact, &recv); } -- cgit v1.2.3