From 176e52e14fd0358a7f26ca8d7b0205244dfde2e7 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 23 May 2018 23:29:25 +0300 Subject: no need to initialize pcli variable in each plugin (only in Clist_*) --- protocols/VKontakte/src/main.cpp | 3 --- protocols/VKontakte/src/misc.cpp | 4 ++-- protocols/VKontakte/src/vk_feed.cpp | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) (limited to 'protocols/VKontakte') diff --git a/protocols/VKontakte/src/main.cpp b/protocols/VKontakte/src/main.cpp index 493c01411a..d267ede49a 100644 --- a/protocols/VKontakte/src/main.cpp +++ b/protocols/VKontakte/src/main.cpp @@ -19,7 +19,6 @@ along with this program. If not, see . #include "version.h" CMPlugin g_plugin; -CLIST_INTERFACE *pcli; ///////////////////////////////////////////////////////////////////////////////////////// @@ -52,8 +51,6 @@ extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_PROTOC extern "C" int __declspec(dllexport) Load() { - pcli = Clist_GetInterface(); - InitIcons(); return 0; } diff --git a/protocols/VKontakte/src/misc.cpp b/protocols/VKontakte/src/misc.cpp index 43ff4a5c0d..1aa0f98c15 100644 --- a/protocols/VKontakte/src/misc.cpp +++ b/protocols/VKontakte/src/misc.cpp @@ -773,9 +773,9 @@ void CVkProto::MarkDialogAsRead(MCONTACT hContact) DBEVENTINFO dbei = {}; if (!db_event_get(hDBEvent, &dbei) && !mir_strcmp(m_szModuleName, dbei.szModule)) { db_event_markRead(hContact, hDBEvent); - pcli->pfnRemoveEvent(hMContact, hDBEvent); + g_CLI.pfnRemoveEvent(hMContact, hDBEvent); if (hContact != hMContact) - pcli->pfnRemoveEvent(hContact, hDBEvent); + g_CLI.pfnRemoveEvent(hContact, hDBEvent); } hDBEvent = db_event_next(hContact, hDBEvent); diff --git a/protocols/VKontakte/src/vk_feed.cpp b/protocols/VKontakte/src/vk_feed.cpp index 87fea21168..20e2bdfbe6 100644 --- a/protocols/VKontakte/src/vk_feed.cpp +++ b/protocols/VKontakte/src/vk_feed.cpp @@ -87,7 +87,7 @@ void CVkProto::AddCListEvent(bool bNews) wchar_t toolTip[255]; mir_snwprintf(toolTip, bNews ? TranslateT("New news") : TranslateT("New notifications")); cle.szTooltip.w = toolTip; - pcli->pfnAddEvent(&cle); + g_CLI.pfnAddEvent(&cle); } ////////////////////////////////////////////////////////////////////////////////////////////////////////// -- cgit v1.2.3