From 46d6a43726d64a0d7f808ad55557bfc56b89f97d Mon Sep 17 00:00:00 2001 From: Sergey Bolhovskoy Date: Wed, 13 Jul 2016 08:25:04 +0000 Subject: =?UTF-8?q?VKontakte:=20add=20=E2=80=98Send=20VK-objects=20links?= =?UTF-8?q?=20as=20attachments=E2=80=99=20option=20move=20=E2=80=98Use=20n?= =?UTF-8?q?on-standard=20popups=20for=20news=20and=20event=20notifications?= =?UTF-8?q?=E2=80=99=20option=20to=20View=20page=20version=20bump?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: http://svn.miranda-ng.org/main/trunk@17090 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/VKontakte/src/vk_messages.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'protocols/VKontakte/src/vk_messages.cpp') diff --git a/protocols/VKontakte/src/vk_messages.cpp b/protocols/VKontakte/src/vk_messages.cpp index f5a6726bc0..02c84f8e78 100644 --- a/protocols/VKontakte/src/vk_messages.cpp +++ b/protocols/VKontakte/src/vk_messages.cpp @@ -62,8 +62,16 @@ int CVkProto::SendMsg(MCONTACT hContact, int, const char *szMsg) if (StickerId) pReq << INT_PARAM("sticker_id", StickerId); - else + else { pReq << CHAR_PARAM("message", szMsg); + if (m_vkOptions.bSendVKLinksAsAttachments) { + CMStringA szAttachments = GetAttachmentsFromMessage(szMsg); + if (!szAttachments.IsEmpty()) { + debugLogA("CVkProto::SendMsg Attachments = %s", szAttachments); + pReq << CHAR_PARAM("attachment", szAttachments); + } + } + } if (!bIsChat) pReq->pUserInfo = new CVkSendMsgParam(hContact, uMsgId); -- cgit v1.2.3