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_*) --- plugins/Popup/src/main.cpp | 4 +--- plugins/Popup/src/popup_thread.cpp | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'plugins/Popup/src') diff --git a/plugins/Popup/src/main.cpp b/plugins/Popup/src/main.cpp index f0f0fe2ee0..51f7891dce 100644 --- a/plugins/Popup/src/main.cpp +++ b/plugins/Popup/src/main.cpp @@ -36,7 +36,7 @@ void UpgradeDb(); //===== Initializations ================================================================= static int OkToExit(WPARAM, LPARAM); bool OptionLoaded = false; -CLIST_INTERFACE *pcli; + CMPlugin g_plugin; //===== Global variables ================================================================ @@ -321,8 +321,6 @@ static int OnShutdown(WPARAM, LPARAM) MIRAPI int Load(void) { - pcli = Clist_GetInterface(); - CreateServiceFunction(MS_POPUP_GETSTATUS, GetStatus); #if defined(_DEBUG) diff --git a/plugins/Popup/src/popup_thread.cpp b/plugins/Popup/src/popup_thread.cpp index 3aa0a05167..2037f2d46f 100644 --- a/plugins/Popup/src/popup_thread.cpp +++ b/plugins/Popup/src/popup_thread.cpp @@ -69,7 +69,7 @@ bool UpdatePopupPosition(PopupWnd2 *prev, PopupWnd2 *wnd) else { // Multimonitor stuff (we have more then 1) HWND hWnd; if (PopupOptions.Monitor == MN_MIRANDA) - hWnd = pcli->hwndContactList; + hWnd = g_CLI.hwndContactList; else // PopupOptions.Monitor == MN_ACTIVE hWnd = GetForegroundWindow(); -- cgit v1.2.3