diff options
author | Robert Pösel <robyer@seznam.cz> | 2014-08-11 13:58:08 +0000 |
---|---|---|
committer | Robert Pösel <robyer@seznam.cz> | 2014-08-11 13:58:08 +0000 |
commit | e54f5144d2be315ee14ea7ae42a2a38f53e1162a (patch) | |
tree | 780cff78c56c8c384fe82ca66f9ac25a5bc25ac7 /protocols/FacebookRM/src/process.cpp | |
parent | fcd08bb4c2fb2ef60efa4a434a673941152916c7 (diff) |
Facebook: Hidden option to disable multi user chat
git-svn-id: http://svn.miranda-ng.org/main/trunk@10155 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/FacebookRM/src/process.cpp')
-rw-r--r-- | protocols/FacebookRM/src/process.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/protocols/FacebookRM/src/process.cpp b/protocols/FacebookRM/src/process.cpp index 6f52f02bba..da8fb609b8 100644 --- a/protocols/FacebookRM/src/process.cpp +++ b/protocols/FacebookRM/src/process.cpp @@ -461,6 +461,9 @@ void FacebookProto::LoadLastMessages(void *p) bool isChat = isChatRoom(hContact); + if (isChat && m_disableChat) + return; + ptrA item_id(getStringA(hContact, isChat ? FACEBOOK_KEY_TID : FACEBOOK_KEY_ID)); if (item_id == NULL) { debugLogA("!!!!! LoadLastMessages: Contact has no TID/ID"); @@ -598,6 +601,11 @@ void FacebookProto::ReceiveMessages(std::vector<facebook_message*> messages, boo DWORD timestamp = local_timestamp || !messages[i]->time ? ::time(NULL) : messages[i]->time; if (messages[i]->isChat) { + if (m_disableChat) { + delete messages[i]; + continue; + } + // Multi-user message debugLogA(" Got chat message: %s", messages[i]->message_text.c_str()); |