From 3cc643812de9ad33f411ad936183d447be4fe51a Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 9 Jan 2017 17:24:13 +0300 Subject: we don't need that hook anymore --- protocols/Discord/src/proto.cpp | 18 ------------------ protocols/Discord/src/proto.h | 1 - 2 files changed, 19 deletions(-) (limited to 'protocols') diff --git a/protocols/Discord/src/proto.cpp b/protocols/Discord/src/proto.cpp index 71ed6dc8b2..5d72ea501a 100644 --- a/protocols/Discord/src/proto.cpp +++ b/protocols/Discord/src/proto.cpp @@ -45,7 +45,6 @@ CDiscordProto::CDiscordProto(const char *proto_name, const wchar_t *username) : // Events HookProtoEvent(ME_OPT_INITIALISE, &CDiscordProto::OnOptionsInit); - HookProtoEvent(ME_MSG_WINDOWEVENT, &CDiscordProto::OnSrmmEvent); // database db_set_resident(m_szModuleName, "XStatusMsg"); @@ -332,23 +331,6 @@ int CDiscordProto::OnPreShutdown(WPARAM, LPARAM) ///////////////////////////////////////////////////////////////////////////////////////// -int CDiscordProto::OnSrmmEvent(WPARAM, LPARAM lParam) -{ - MessageWindowEventData *MWeventdata = (MessageWindowEventData*)lParam; - - if (MWeventdata->uType == MSG_WINDOW_EVT_OPENING && MWeventdata->hContact) { - SnowFlake oldid = getId(MWeventdata->hContact, DB_KEY_LASTMSGID); - if (oldid > 0) - RetrieveHistory(MWeventdata->hContact, MSG_AFTER, oldid, 99); - else - RetrieveHistory(MWeventdata->hContact, MSG_NOFILTER, 0, 99); - } - - return 0; -} - -///////////////////////////////////////////////////////////////////////////////////////// - int CDiscordProto::OnEvent(PROTOEVENTTYPE event, WPARAM wParam, LPARAM lParam) { switch (event) { diff --git a/protocols/Discord/src/proto.h b/protocols/Discord/src/proto.h index b5293614ea..c3cbae6d4a 100644 --- a/protocols/Discord/src/proto.h +++ b/protocols/Discord/src/proto.h @@ -220,7 +220,6 @@ public: int __cdecl OnModulesLoaded(WPARAM, LPARAM); int __cdecl OnPreShutdown(WPARAM, LPARAM); int __cdecl OnOptionsInit(WPARAM, LPARAM); - int __cdecl OnSrmmEvent(WPARAM, LPARAM); // dispatch commands void OnCommandMessage(const JSONNode&); -- cgit v1.2.3