From cb1787afbb67184321f206f13f836b63cd06740a Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 15 Sep 2023 14:52:01 +0300 Subject: PROTO_INTERFACE::SendMsg - unused parameter flags removed --- include/m_protoint.h | 2 +- libs/win32/mir_app.lib | Bin 271000 -> 270996 bytes libs/win64/mir_app.lib | Bin 270156 -> 270152 bytes protocols/Discord/src/proto.cpp | 2 +- protocols/Discord/src/proto.h | 2 +- protocols/Dummy/src/dummy_proto.cpp | 2 +- protocols/Dummy/src/dummy_proto.h | 2 +- protocols/Facebook/src/groupchats.cpp | 2 +- protocols/Facebook/src/proto.cpp | 2 +- protocols/Facebook/src/proto.h | 2 +- protocols/Gadu-Gadu/src/gg_proto.cpp | 2 +- protocols/Gadu-Gadu/src/gg_proto.h | 2 +- protocols/ICQ-WIM/src/groupchats.cpp | 2 +- protocols/ICQ-WIM/src/proto.cpp | 2 +- protocols/ICQ-WIM/src/proto.h | 2 +- protocols/IRCG/src/ircproto.cpp | 2 +- protocols/IRCG/src/ircproto.h | 2 +- protocols/JabberG/src/jabber_chat.cpp | 2 +- protocols/JabberG/src/jabber_omemo.cpp | 2 +- protocols/JabberG/src/jabber_proto.cpp | 2 +- protocols/JabberG/src/jabber_proto.h | 2 +- protocols/Sametime/src/sametime_proto.cpp | 2 +- protocols/Sametime/src/sametime_proto.h | 2 +- protocols/SkypeWeb/src/skype_messages.cpp | 2 +- protocols/SkypeWeb/src/skype_proto.h | 2 +- protocols/Steam/src/steam_proto.cpp | 2 +- protocols/Steam/src/steam_proto.h | 2 +- protocols/Telegram/src/proto.cpp | 2 +- protocols/Telegram/src/proto.h | 2 +- protocols/Tox/src/tox_proto.cpp | 2 +- protocols/Tox/src/tox_proto.h | 2 +- protocols/Twitter/src/proto.cpp | 2 +- protocols/Twitter/src/proto.h | 2 +- protocols/VKontakte/src/vk_chats.cpp | 2 +- protocols/VKontakte/src/vk_messages.cpp | 4 ++-- protocols/VKontakte/src/vk_proto.h | 2 +- protocols/WhatsApp/src/proto.cpp | 2 +- protocols/WhatsApp/src/proto.h | 2 +- src/mir_app/src/mir_app.def | 2 +- src/mir_app/src/mir_app64.def | 2 +- src/mir_app/src/proto_interface.cpp | 2 +- src/mir_app/src/proto_internal.cpp | 2 +- src/mir_app/src/protocols.cpp | 2 +- 43 files changed, 42 insertions(+), 42 deletions(-) diff --git a/include/m_protoint.h b/include/m_protoint.h index 2c1a7ffe53..8c169b8192 100644 --- a/include/m_protoint.h +++ b/include/m_protoint.h @@ -240,7 +240,7 @@ public: virtual int SendContacts(MCONTACT hContact, int flags, int nContacts, MCONTACT *hContactsList); virtual HANDLE SendFile(MCONTACT hContact, const wchar_t *szDescription, wchar_t **ppszFiles); - virtual int SendMsg(MCONTACT hContact, int flags, const char *msg); + virtual int SendMsg(MCONTACT hContact, const char *msg); virtual int SetApparentMode(MCONTACT hContact, int mode); virtual int SetStatus(int iNewStatus); diff --git a/libs/win32/mir_app.lib b/libs/win32/mir_app.lib index cef9bf721c..e59f19933f 100644 Binary files a/libs/win32/mir_app.lib and b/libs/win32/mir_app.lib differ diff --git a/libs/win64/mir_app.lib b/libs/win64/mir_app.lib index b10de66983..524fa19157 100644 Binary files a/libs/win64/mir_app.lib and b/libs/win64/mir_app.lib differ diff --git a/protocols/Discord/src/proto.cpp b/protocols/Discord/src/proto.cpp index ed5b6e365b..b9c13939e3 100644 --- a/protocols/Discord/src/proto.cpp +++ b/protocols/Discord/src/proto.cpp @@ -480,7 +480,7 @@ void CDiscordProto::OnSendMsg(NETLIBHTTPREQUEST *pReply, AsyncHttpRequest *pReq) } } -int CDiscordProto::SendMsg(MCONTACT hContact, int, const char *pszSrc) +int CDiscordProto::SendMsg(MCONTACT hContact, const char *pszSrc) { if (!m_bOnline) return -1; diff --git a/protocols/Discord/src/proto.h b/protocols/Discord/src/proto.h index 3ba17654c1..89523eeb37 100644 --- a/protocols/Discord/src/proto.h +++ b/protocols/Discord/src/proto.h @@ -368,7 +368,7 @@ public: HANDLE GetAwayMsg(MCONTACT hContact) override; int SetAwayMsg(int iStatus, const wchar_t *msg) override; - int SendMsg(MCONTACT hContact, int flags, const char *pszSrc) override; + int SendMsg(MCONTACT hContact, const char *pszSrc) override; HANDLE SendFile(MCONTACT hContact, const wchar_t *szDescription, wchar_t **ppszFiles) override; diff --git a/protocols/Dummy/src/dummy_proto.cpp b/protocols/Dummy/src/dummy_proto.cpp index 8a67a9763d..a3f0eb113e 100644 --- a/protocols/Dummy/src/dummy_proto.cpp +++ b/protocols/Dummy/src/dummy_proto.cpp @@ -136,7 +136,7 @@ INT_PTR CDummyProto::GetCaps(int type, MCONTACT) ////////////////////////////////////////////////////////////////////////////// -int CDummyProto::SendMsg(MCONTACT hContact, int, const char *msg) +int CDummyProto::SendMsg(MCONTACT hContact, const char *msg) { std::string message = msg; unsigned int id = InterlockedIncrement(&this->msgid); diff --git a/protocols/Dummy/src/dummy_proto.h b/protocols/Dummy/src/dummy_proto.h index d7836f7f64..3760fbba4a 100644 --- a/protocols/Dummy/src/dummy_proto.h +++ b/protocols/Dummy/src/dummy_proto.h @@ -30,7 +30,7 @@ struct CDummyProto : public PROTO INT_PTR GetCaps(int type, MCONTACT hContact = NULL) override; - int SendMsg(MCONTACT hContact, int flags, const char* msg) override; + int SendMsg(MCONTACT hContact, const char* msg) override; int SetStatus(int iNewStatus) override; diff --git a/protocols/Facebook/src/groupchats.cpp b/protocols/Facebook/src/groupchats.cpp index 3717d65eef..9215983585 100644 --- a/protocols/Facebook/src/groupchats.cpp +++ b/protocols/Facebook/src/groupchats.cpp @@ -164,7 +164,7 @@ int FacebookProto::GroupchatEventHook(WPARAM, LPARAM lParam) wchar_t *wszText = NEWWSTR_ALLOCA(gch->ptszText); Chat_UnescapeTags(wszText); - int mid = SendMsg(si->hContact, 0, T2Utf(wszText)); + int mid = SendMsg(si->hContact, T2Utf(wszText)); mir_cslock lck(m_csOwnMessages); for (auto &msg : arOwnMessages) diff --git a/protocols/Facebook/src/proto.cpp b/protocols/Facebook/src/proto.cpp index 82b45478ad..5e896c6f4e 100644 --- a/protocols/Facebook/src/proto.cpp +++ b/protocols/Facebook/src/proto.cpp @@ -215,7 +215,7 @@ INT_PTR FacebookProto::GetCaps(int type, MCONTACT) ///////////////////////////////////////////////////////////////////////////////////////// -int FacebookProto::SendMsg(MCONTACT hContact, int, const char *pszSrc) +int FacebookProto::SendMsg(MCONTACT hContact, const char *pszSrc) { if (!m_bOnline) return -1; diff --git a/protocols/Facebook/src/proto.h b/protocols/Facebook/src/proto.h index 16a3cbd4c1..660146e56f 100644 --- a/protocols/Facebook/src/proto.h +++ b/protocols/Facebook/src/proto.h @@ -528,7 +528,7 @@ public: MCONTACT AddToList(int flags, PROTOSEARCHRESULT *psr) override; INT_PTR GetCaps(int type, MCONTACT hContact) override; - int SendMsg(MCONTACT hContact, int flags, const char *pszSrc) override; + int SendMsg(MCONTACT hContact, const char *pszSrc) override; int SetStatus(int iNewStatus) override; int UserIsTyping(MCONTACT hContact, int type) override; diff --git a/protocols/Gadu-Gadu/src/gg_proto.cpp b/protocols/Gadu-Gadu/src/gg_proto.cpp index ea05b30e3c..82c53a6a94 100644 --- a/protocols/Gadu-Gadu/src/gg_proto.cpp +++ b/protocols/Gadu-Gadu/src/gg_proto.cpp @@ -506,7 +506,7 @@ HWND GaduProto::CreateExtendedSearchUI(HWND owner) ////////////////////////////////////////////////////////// // when messsage sent // -int GaduProto::SendMsg(MCONTACT hContact, int, const char *msg) +int GaduProto::SendMsg(MCONTACT hContact, const char *msg) { uin_t uin = (uin_t)getDword(hContact, GG_KEY_UIN, 0); if (!isonline()) diff --git a/protocols/Gadu-Gadu/src/gg_proto.h b/protocols/Gadu-Gadu/src/gg_proto.h index 526d0edf07..a5bf2f7a59 100644 --- a/protocols/Gadu-Gadu/src/gg_proto.h +++ b/protocols/Gadu-Gadu/src/gg_proto.h @@ -46,7 +46,7 @@ struct GaduProto : public PROTO HWND CreateExtendedSearchUI(HWND owner) override; HANDLE SendFile(MCONTACT hContact, const wchar_t* szDescription, wchar_t** ppszFiles) override; - int SendMsg(MCONTACT hContact, int flags, const char* msg) override; + int SendMsg(MCONTACT hContact, const char* msg) override; int SetApparentMode(MCONTACT hContact, int mode) override; int SetStatus(int iNewStatus) override; diff --git a/protocols/ICQ-WIM/src/groupchats.cpp b/protocols/ICQ-WIM/src/groupchats.cpp index 603cc4101d..9f9e314811 100644 --- a/protocols/ICQ-WIM/src/groupchats.cpp +++ b/protocols/ICQ-WIM/src/groupchats.cpp @@ -240,7 +240,7 @@ int CIcqProto::GroupchatEventHook(WPARAM, LPARAM lParam) if (m_bOnline) { wchar_t *wszText = NEWWSTR_ALLOCA(gch->ptszText); Chat_UnescapeTags(wszText); - SendMsg(si->hContact, 0, T2Utf(wszText)); + SendMsg(si->hContact, T2Utf(wszText)); } break; diff --git a/protocols/ICQ-WIM/src/proto.cpp b/protocols/ICQ-WIM/src/proto.cpp index 343ac8fef5..0eeab208f5 100644 --- a/protocols/ICQ-WIM/src/proto.cpp +++ b/protocols/ICQ-WIM/src/proto.cpp @@ -559,7 +559,7 @@ HANDLE CIcqProto::SendFile(MCONTACT hContact, const wchar_t *szDescription, wcha //////////////////////////////////////////////////////////////////////////////////////// // PS_SendMessage - sends a message -int CIcqProto::SendMsg(MCONTACT hContact, int, const char *pszSrc) +int CIcqProto::SendMsg(MCONTACT hContact, const char *pszSrc) { CMStringA szUserid(GetUserId(hContact)); if (szUserid.IsEmpty()) diff --git a/protocols/ICQ-WIM/src/proto.h b/protocols/ICQ-WIM/src/proto.h index 1d51df8369..1cf5f4381b 100644 --- a/protocols/ICQ-WIM/src/proto.h +++ b/protocols/ICQ-WIM/src/proto.h @@ -404,7 +404,7 @@ class CIcqProto : public PROTO HANDLE SearchBasic(const wchar_t *id) override; HANDLE SendFile(MCONTACT hContact, const wchar_t *szDescription, wchar_t **ppszFiles) override; - int SendMsg(MCONTACT hContact, int flags, const char *msg) override; + int SendMsg(MCONTACT hContact, const char *msg) override; int SetApparentMode(MCONTACT hContact, int mode) override; int SetStatus(int iNewStatus) override; diff --git a/protocols/IRCG/src/ircproto.cpp b/protocols/IRCG/src/ircproto.cpp index 0e4af4c31f..c4ecb1e30e 100644 --- a/protocols/IRCG/src/ircproto.cpp +++ b/protocols/IRCG/src/ircproto.cpp @@ -581,7 +581,7 @@ HANDLE CIrcProto::SendFile(MCONTACT hContact, const wchar_t*, wchar_t** ppszFile //////////////////////////////////////////////////////////////////////////////////////// // SendMessage - sends a message -int CIrcProto::SendMsg(MCONTACT hContact, int, const char* pszSrc) +int CIrcProto::SendMsg(MCONTACT hContact, const char* pszSrc) { uint8_t bDcc = getByte(hContact, "DCC", 0); uint16_t wStatus = getWord(hContact, "Status", ID_STATUS_OFFLINE); diff --git a/protocols/IRCG/src/ircproto.h b/protocols/IRCG/src/ircproto.h index 6614bf4df7..6b30cea36d 100644 --- a/protocols/IRCG/src/ircproto.h +++ b/protocols/IRCG/src/ircproto.h @@ -62,7 +62,7 @@ struct CIrcProto : public PROTO HANDLE SearchBasic(const wchar_t* id) override; HANDLE SendFile(MCONTACT hContact, const wchar_t *szDescription, wchar_t **ppszFiles) override; - int SendMsg(MCONTACT hContact, int flags, const char* msg) override; + int SendMsg(MCONTACT hContact, const char* msg) override; int SetStatus(int iNewStatus) override; diff --git a/protocols/JabberG/src/jabber_chat.cpp b/protocols/JabberG/src/jabber_chat.cpp index 6906c24c2b..e54817fe25 100644 --- a/protocols/JabberG/src/jabber_chat.cpp +++ b/protocols/JabberG/src/jabber_chat.cpp @@ -1348,7 +1348,7 @@ int CJabberProto::JabberGcEventHook(WPARAM, LPARAM lParam) if (gch->ptszText && mir_wstrlen(gch->ptszText) > 0) { rtrimw(gch->ptszText); Chat_UnescapeTags(gch->ptszText); - SendMsg(item->hContact, 0, T2Utf(gch->ptszText)); + SendMsg(item->hContact, T2Utf(gch->ptszText)); } break; diff --git a/protocols/JabberG/src/jabber_omemo.cpp b/protocols/JabberG/src/jabber_omemo.cpp index d1f921f9b4..6e0b7a172c 100644 --- a/protocols/JabberG/src/jabber_omemo.cpp +++ b/protocols/JabberG/src/jabber_omemo.cpp @@ -1206,7 +1206,7 @@ void CJabberProto::OmemoPutMessageToOutgoingQueue(MCONTACT hContact, const char* void CJabberProto::OmemoHandleMessageQueue() { for (auto &i : m_omemo.outgoing_messages) { - SendMsg(i.hContact, 0, i.pszSrc); + SendMsg(i.hContact, i.pszSrc); mir_free(i.pszSrc); } m_omemo.outgoing_messages.clear(); diff --git a/protocols/JabberG/src/jabber_proto.cpp b/protocols/JabberG/src/jabber_proto.cpp index bc038bb3fc..c0b8d4b93c 100644 --- a/protocols/JabberG/src/jabber_proto.cpp +++ b/protocols/JabberG/src/jabber_proto.cpp @@ -885,7 +885,7 @@ HANDLE CJabberProto::SendFile(MCONTACT hContact, const wchar_t *szDescription, w //////////////////////////////////////////////////////////////////////////////////////// // JabberSendMessage - sends a message -int CJabberProto::SendMsg(MCONTACT hContact, int /*flags*/, const char *pszSrc) +int CJabberProto::SendMsg(MCONTACT hContact, const char *pszSrc) { XmlNode m("message"); return SendMsgEx(hContact, pszSrc, m); diff --git a/protocols/JabberG/src/jabber_proto.h b/protocols/JabberG/src/jabber_proto.h index 0e568605b6..8791339476 100644 --- a/protocols/JabberG/src/jabber_proto.h +++ b/protocols/JabberG/src/jabber_proto.h @@ -137,7 +137,7 @@ struct CJabberProto : public PROTO, public IJabberInterface int SendContacts(MCONTACT hContact, int flags, int nContacts, MCONTACT *hContactsList) override; HANDLE SendFile(MCONTACT hContact, const wchar_t *szDescription, wchar_t **ppszFiles) override; - int SendMsg(MCONTACT hContact, int flags, const char *msg) override; + int SendMsg(MCONTACT hContact, const char *msg) override; int SendMsgEx(MCONTACT hContact, const char *msg, XmlNode &m); int SetApparentMode(MCONTACT hContact, int mode) override; diff --git a/protocols/Sametime/src/sametime_proto.cpp b/protocols/Sametime/src/sametime_proto.cpp index adb4f67ce0..89774f0b63 100644 --- a/protocols/Sametime/src/sametime_proto.cpp +++ b/protocols/Sametime/src/sametime_proto.cpp @@ -195,7 +195,7 @@ HANDLE CSametimeProto::SendFile(MCONTACT hContact, const wchar_t* szDescription, return nullptr; // failure } -int CSametimeProto::SendMsg(MCONTACT hContact, int, const char* msg) +int CSametimeProto::SendMsg(MCONTACT hContact, const char* msg) { debugLogW(L"CSametimeProto::SendMsg() hContact=[%x]", hContact); diff --git a/protocols/Sametime/src/sametime_proto.h b/protocols/Sametime/src/sametime_proto.h index fb022ae3c2..e2faca6d07 100644 --- a/protocols/Sametime/src/sametime_proto.h +++ b/protocols/Sametime/src/sametime_proto.h @@ -28,7 +28,7 @@ struct CSametimeProto : public PROTO MEVENT RecvMsg(MCONTACT hContact, PROTORECVEVENT*) override; HANDLE SendFile(MCONTACT hContact, const wchar_t* szDescription, wchar_t** ppszFiles) override; - int SendMsg(MCONTACT hContact, int flags, const char* msg) override; + int SendMsg(MCONTACT hContact, const char* msg) override; int SetStatus(int iNewStatus) override; diff --git a/protocols/SkypeWeb/src/skype_messages.cpp b/protocols/SkypeWeb/src/skype_messages.cpp index 25e15e73b1..aab76d7ad8 100644 --- a/protocols/SkypeWeb/src/skype_messages.cpp +++ b/protocols/SkypeWeb/src/skype_messages.cpp @@ -20,7 +20,7 @@ along with this program. If not, see . /* MESSAGE SENDING */ // outcoming message flow -int CSkypeProto::SendMsg(MCONTACT hContact, int, const char *szMessage) +int CSkypeProto::SendMsg(MCONTACT hContact, const char *szMessage) { if (!IsOnline()) return -1; diff --git a/protocols/SkypeWeb/src/skype_proto.h b/protocols/SkypeWeb/src/skype_proto.h index 9236c905c5..b87b5b7a77 100644 --- a/protocols/SkypeWeb/src/skype_proto.h +++ b/protocols/SkypeWeb/src/skype_proto.h @@ -59,7 +59,7 @@ public: INT_PTR GetCaps(int type, MCONTACT hContact = NULL) override; int GetInfo(MCONTACT hContact, int infoType) override; HANDLE SearchBasic(const wchar_t* id) override; - int SendMsg(MCONTACT hContact, int flags, const char* msg) override; + int SendMsg(MCONTACT hContact, const char* msg) override; int SetStatus(int iNewStatus) override; int UserIsTyping(MCONTACT hContact, int type) override; int RecvContacts(MCONTACT hContact, PROTORECVEVENT*) override; diff --git a/protocols/Steam/src/steam_proto.cpp b/protocols/Steam/src/steam_proto.cpp index a37c9521e0..38643c2f47 100644 --- a/protocols/Steam/src/steam_proto.cpp +++ b/protocols/Steam/src/steam_proto.cpp @@ -243,7 +243,7 @@ HANDLE CSteamProto::SearchByName(const wchar_t *nick, const wchar_t *firstName, return (HANDLE)STEAM_SEARCH_BYNAME; } -int CSteamProto::SendMsg(MCONTACT hContact, int, const char *message) +int CSteamProto::SendMsg(MCONTACT hContact, const char *message) { if (!IsOnline()) return -1; diff --git a/protocols/Steam/src/steam_proto.h b/protocols/Steam/src/steam_proto.h index 8b93aa0e7f..cdc4e3f6ff 100644 --- a/protocols/Steam/src/steam_proto.h +++ b/protocols/Steam/src/steam_proto.h @@ -278,7 +278,7 @@ public: HANDLE SearchBasic(const wchar_t *id) override; HANDLE SearchByName(const wchar_t *nick, const wchar_t *firstName, const wchar_t *lastName) override; - int SendMsg(MCONTACT hContact, int flags, const char *msg) override; + int SendMsg(MCONTACT hContact, const char *msg) override; int SetStatus(int iNewStatus) override; diff --git a/protocols/Telegram/src/proto.cpp b/protocols/Telegram/src/proto.cpp index 98d055af2b..4f62a300a0 100644 --- a/protocols/Telegram/src/proto.cpp +++ b/protocols/Telegram/src/proto.cpp @@ -466,7 +466,7 @@ void CTelegramProto::OnSendFile(td::ClientManager::Response &response, void *pUs ///////////////////////////////////////////////////////////////////////////////////////// -int CTelegramProto::SendMsg(MCONTACT hContact, int, const char *pszMessage) +int CTelegramProto::SendMsg(MCONTACT hContact, const char *pszMessage) { ptrA szId(getStringA(hContact, DBKEY_ID)); if (szId == nullptr) diff --git a/protocols/Telegram/src/proto.h b/protocols/Telegram/src/proto.h index c3d0252a06..27394a241c 100644 --- a/protocols/Telegram/src/proto.h +++ b/protocols/Telegram/src/proto.h @@ -333,7 +333,7 @@ public: MEVENT RecvFile(MCONTACT hContact, PROTORECVFILE *pre) override; HANDLE SearchByName(const wchar_t *nick, const wchar_t *firstName, const wchar_t *lastName) override; - int SendMsg(MCONTACT hContact, int flags, const char *pszMessage) override; + int SendMsg(MCONTACT hContact, const char *pszMessage) override; int SetStatus(int iNewStatus) override; void OnBuildProtoMenu() override; diff --git a/protocols/Tox/src/tox_proto.cpp b/protocols/Tox/src/tox_proto.cpp index 07a6d20cd1..cfabeefac9 100644 --- a/protocols/Tox/src/tox_proto.cpp +++ b/protocols/Tox/src/tox_proto.cpp @@ -139,7 +139,7 @@ HWND CToxProto::CreateExtendedSearchUI(HWND owner) return OnCreateExtendedSearchUI(owner); } -int CToxProto::SendMsg(MCONTACT hContact, int, const char *msg) +int CToxProto::SendMsg(MCONTACT hContact, const char *msg) { return OnSendMessage(hContact, msg); } diff --git a/protocols/Tox/src/tox_proto.h b/protocols/Tox/src/tox_proto.h index 84674da96a..f69c695874 100644 --- a/protocols/Tox/src/tox_proto.h +++ b/protocols/Tox/src/tox_proto.h @@ -55,7 +55,7 @@ public: HANDLE SearchAdvanced(HWND owner) override; HWND CreateExtendedSearchUI(HWND owner) override; - int SendMsg(MCONTACT hContact, int flags, const char *msg) override; + int SendMsg(MCONTACT hContact, const char *msg) override; HANDLE SendFile(MCONTACT hContact, const wchar_t *, wchar_t **ppszFiles) override; diff --git a/protocols/Twitter/src/proto.cpp b/protocols/Twitter/src/proto.cpp index 05cefe2748..b28506cec1 100644 --- a/protocols/Twitter/src/proto.cpp +++ b/protocols/Twitter/src/proto.cpp @@ -120,7 +120,7 @@ INT_PTR CTwitterProto::GetCaps(int type, MCONTACT) ///////////////////////////////////////////////////////////////////////////////////////// -int CTwitterProto::SendMsg(MCONTACT hContact, int, const char *msg) +int CTwitterProto::SendMsg(MCONTACT hContact, const char *msg) { if (m_iStatus != ID_STATUS_ONLINE) return -1; diff --git a/protocols/Twitter/src/proto.h b/protocols/Twitter/src/proto.h index 51efed7e0c..1e3e408830 100644 --- a/protocols/Twitter/src/proto.h +++ b/protocols/Twitter/src/proto.h @@ -177,7 +177,7 @@ public: HANDLE SearchBasic(const wchar_t *) override; HANDLE SearchByEmail(const wchar_t *) override; - int SendMsg(MCONTACT, int, const char *) override; + int SendMsg(MCONTACT, const char *) override; int SetStatus(int) override; diff --git a/protocols/VKontakte/src/vk_chats.cpp b/protocols/VKontakte/src/vk_chats.cpp index e40d9402c0..6d6a84db99 100644 --- a/protocols/VKontakte/src/vk_chats.cpp +++ b/protocols/VKontakte/src/vk_chats.cpp @@ -611,7 +611,7 @@ int CVkProto::OnChatEvent(WPARAM, LPARAM lParam) ptrW pwszBuf(mir_wstrdup(gch->ptszText)); rtrimw(pwszBuf); Chat_UnescapeTags(pwszBuf); - SendMsg(cc->m_si->hContact, 0, T2Utf(pwszBuf)); + SendMsg(cc->m_si->hContact, T2Utf(pwszBuf)); } break; diff --git a/protocols/VKontakte/src/vk_messages.cpp b/protocols/VKontakte/src/vk_messages.cpp index f45233e7a0..9e2a49c8b1 100644 --- a/protocols/VKontakte/src/vk_messages.cpp +++ b/protocols/VKontakte/src/vk_messages.cpp @@ -19,7 +19,7 @@ along with this program. If not, see . ////////////////////////////////////////////////////////////////////////////// -int CVkProto::SendMsg(MCONTACT hContact, int, const char *szMsg) +int CVkProto::SendMsg(MCONTACT hContact, const char *szMsg) { debugLogA("CVkProto::SendMsg"); if (!IsOnline()) @@ -64,7 +64,7 @@ int CVkProto::SendMsg(MCONTACT hContact, int, const char *szMsg) ProtoBroadcastAsync(hContact, ACKTYPE_MESSAGE, ACKRESULT_SUCCESS, (HANDLE)uMsgId); if (!IsEmpty(pszRetMsg)) - SendMsg(hContact, 0, pszRetMsg); + SendMsg(hContact, pszRetMsg); else if (m_iStatus == ID_STATUS_INVISIBLE) Push(new AsyncHttpRequest(this, REQUEST_GET, "/method/account.setOffline.json", true, &CVkProto::OnReceiveSmth)); diff --git a/protocols/VKontakte/src/vk_proto.h b/protocols/VKontakte/src/vk_proto.h index 4ebab92222..1c6e747e2a 100644 --- a/protocols/VKontakte/src/vk_proto.h +++ b/protocols/VKontakte/src/vk_proto.h @@ -66,7 +66,7 @@ struct CVkProto : public PROTO HANDLE SearchBasic(const wchar_t *id) override; HANDLE SearchByEmail(const wchar_t *email) override; HANDLE SearchByName(const wchar_t *nick, const wchar_t *firstName, const wchar_t *lastName) override; - int SendMsg(MCONTACT hContact, int flags, const char *msg) override; + int SendMsg(MCONTACT hContact, const char *msg) override; HANDLE SendFile(MCONTACT hContact, const wchar_t *szDescription, wchar_t **ppszFiles) override; int SetStatus(int iNewStatus) override; int UserIsTyping(MCONTACT hContact, int type) override; diff --git a/protocols/WhatsApp/src/proto.cpp b/protocols/WhatsApp/src/proto.cpp index 917ca012aa..303753b7ee 100644 --- a/protocols/WhatsApp/src/proto.cpp +++ b/protocols/WhatsApp/src/proto.cpp @@ -243,7 +243,7 @@ int WhatsAppProto::SetStatus(int iNewStatus) ///////////////////////////////////////////////////////////////////////////////////////// -int WhatsAppProto::SendMsg(MCONTACT hContact, int, const char *pszMsg) +int WhatsAppProto::SendMsg(MCONTACT hContact, const char *pszMsg) { if (!isOnline()) return -1; diff --git a/protocols/WhatsApp/src/proto.h b/protocols/WhatsApp/src/proto.h index ef3bb4f408..01ab9ba043 100644 --- a/protocols/WhatsApp/src/proto.h +++ b/protocols/WhatsApp/src/proto.h @@ -466,7 +466,7 @@ public: MCONTACT AddToList(int flags, PROTOSEARCHRESULT *psr) override; INT_PTR GetCaps(int type, MCONTACT hContact = NULL) override; HANDLE SearchBasic(const wchar_t* id) override; - int SendMsg(MCONTACT hContact, int flags, const char* msg) override; + int SendMsg(MCONTACT hContact, const char* msg) override; int SetStatus(int iNewStatus) override; int UserIsTyping(MCONTACT hContact, int type) override; diff --git a/src/mir_app/src/mir_app.def b/src/mir_app/src/mir_app.def index 08989886ce..f53ffc745c 100644 --- a/src/mir_app/src/mir_app.def +++ b/src/mir_app/src/mir_app.def @@ -63,7 +63,7 @@ Button_SetSkin_IcoLib @24 ?SearchByName@PROTO_INTERFACE@@UAEPAXPB_W00@Z @65 NONAME ?SendContacts@PROTO_INTERFACE@@UAEHIHHPAI@Z @66 NONAME ?SendFile@PROTO_INTERFACE@@UAEPAXIPB_WPAPA_W@Z @67 NONAME -?SendMsg@PROTO_INTERFACE@@UAEHIHPBD@Z @68 NONAME +?SendMsg@PROTO_INTERFACE@@UAEHIPBD@Z @68 NONAME ?SetApparentMode@PROTO_INTERFACE@@UAEHIH@Z @70 NONAME ?SetAwayMsg@PROTO_INTERFACE@@UAEHHPB_W@Z @71 NONAME ?SetStatus@PROTO_INTERFACE@@UAEHH@Z @72 NONAME diff --git a/src/mir_app/src/mir_app64.def b/src/mir_app/src/mir_app64.def index d15c8b7a46..e10960fe1b 100644 --- a/src/mir_app/src/mir_app64.def +++ b/src/mir_app/src/mir_app64.def @@ -63,7 +63,7 @@ Button_SetSkin_IcoLib @24 ?SearchByName@PROTO_INTERFACE@@UEAAPEAXPEB_W00@Z @65 NONAME ?SendContacts@PROTO_INTERFACE@@UEAAHIHHPEAI@Z @66 NONAME ?SendFile@PROTO_INTERFACE@@UEAAPEAXIPEB_WPEAPEA_W@Z @67 NONAME -?SendMsg@PROTO_INTERFACE@@UEAAHIHPEBD@Z @68 NONAME +?SendMsg@PROTO_INTERFACE@@UEAAHIPEBD@Z @68 NONAME ?SetApparentMode@PROTO_INTERFACE@@UEAAHIH@Z @70 NONAME ?SetAwayMsg@PROTO_INTERFACE@@UEAAHHPEB_W@Z @71 NONAME ?SetStatus@PROTO_INTERFACE@@UEAAHH@Z @72 NONAME diff --git a/src/mir_app/src/proto_interface.cpp b/src/mir_app/src/proto_interface.cpp index 716cc7bb29..0f3b2e12d5 100644 --- a/src/mir_app/src/proto_interface.cpp +++ b/src/mir_app/src/proto_interface.cpp @@ -254,7 +254,7 @@ HANDLE PROTO_INTERFACE::SendFile(MCONTACT, const wchar_t*, wchar_t**) return nullptr; // error } -int PROTO_INTERFACE::SendMsg(MCONTACT, int, const char*) +int PROTO_INTERFACE::SendMsg(MCONTACT, const char*) { return 0; // error } diff --git a/src/mir_app/src/proto_internal.cpp b/src/mir_app/src/proto_internal.cpp index 85ee586a92..b8d0cabb5c 100644 --- a/src/mir_app/src/proto_internal.cpp +++ b/src/mir_app/src/proto_internal.cpp @@ -209,7 +209,7 @@ struct DEFAULT_PROTO_INTERFACE : public PROTO_INTERFACE return res; } - int SendMsg(MCONTACT hContact, int /*flags*/, const char *msg) override + int SendMsg(MCONTACT hContact, const char *msg) override { CCSDATA ccs = { hContact, PSS_MESSAGE, 0, (LPARAM)msg }; return (int)ProtoCallService(m_szModuleName, PSS_MESSAGE, 0, (LPARAM)&ccs); diff --git a/src/mir_app/src/protocols.cpp b/src/mir_app/src/protocols.cpp index bafd0d0d04..6a472ee64e 100644 --- a/src/mir_app/src/protocols.cpp +++ b/src/mir_app/src/protocols.cpp @@ -425,7 +425,7 @@ INT_PTR CallProtoServiceInt(MCONTACT hContact, const char *szModule, const char case 23: return (INT_PTR)ppi->SendContacts(hContact, LOWORD(wParam), HIWORD(wParam), (MCONTACT *)lParam); case 24: return (INT_PTR)ppi->SendFile(hContact, (wchar_t *)wParam, (wchar_t **)lParam); case 25: { - int msgId = ppi->SendMsg(hContact, wParam, (const char *)lParam); + int msgId = ppi->SendMsg(hContact, (const char *)lParam); if (msgId == -1) { ppi->ProtoBroadcastAsync(hContact, ACKTYPE_MESSAGE, ACKRESULT_FAILED, (HANDLE)-1, (LPARAM)TranslateT("Protocol is offline")); return -1; -- cgit v1.2.3