summaryrefslogtreecommitdiff
path: root/plugins/AutoShutdown/src
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2018-05-23 23:29:25 +0300
committerGeorge Hazan <ghazan@miranda.im>2018-05-23 23:29:25 +0300
commit176e52e14fd0358a7f26ca8d7b0205244dfde2e7 (patch)
tree10da2f8951d20103af0215c38d07ea96ba61c191 /plugins/AutoShutdown/src
parent91b13500b47a51f3a284d9f409b7b8dac167a06d (diff)
no need to initialize pcli variable in each plugin (only in Clist_*)
Diffstat (limited to 'plugins/AutoShutdown/src')
-rw-r--r--plugins/AutoShutdown/src/frame.cpp4
-rw-r--r--plugins/AutoShutdown/src/main.cpp3
-rw-r--r--plugins/AutoShutdown/src/shutdownsvc.cpp2
3 files changed, 3 insertions, 6 deletions
diff --git a/plugins/AutoShutdown/src/frame.cpp b/plugins/AutoShutdown/src/frame.cpp
index ab4baad2b9..78b11eb92d 100644
--- a/plugins/AutoShutdown/src/frame.cpp
+++ b/plugins/AutoShutdown/src/frame.cpp
@@ -487,7 +487,7 @@ void ShowCountdownFrame(WORD fTimeFlags)
0, 0,
GetSystemMetrics(SM_CXICON) + 103,
GetSystemMetrics(SM_CYICON) + 2,
- pcli->hwndContactList,
+ g_CLI.hwndContactList,
nullptr,
g_plugin.getInst(),
&fTimeFlags);
@@ -509,7 +509,7 @@ void ShowCountdownFrame(WORD fTimeFlags)
/* HACKS TO FIX CLUI FRAMES:
* *** why is CLUIFrames is horribly buggy??! *** date: sept 2005, nothing changed until sept 2006
* workaround #1: MS_CLIST_FRAMES_REMOVEFRAME does not finish with destroy cycle (clist_modern, clist_nicer crashes) */
- SendMessage(pcli->hwndContactList, WM_SIZE, 0, 0);
+ SendMessage(g_CLI.hwndContactList, WM_SIZE, 0, 0);
/* workaround #2: drawing glitch after adding a frame (frame positioned wrongly when hidden) */
CallService(MS_CLIST_FRAMES_UPDATEFRAME, hFrame, FU_FMPOS | FU_FMREDRAW);
/* workaround #3: MS_CLIST_FRAMES_SETFRAMEOPTIONS does cause redrawing problems */
diff --git a/plugins/AutoShutdown/src/main.cpp b/plugins/AutoShutdown/src/main.cpp
index a6b359a6b0..0f0dcfc0da 100644
--- a/plugins/AutoShutdown/src/main.cpp
+++ b/plugins/AutoShutdown/src/main.cpp
@@ -20,7 +20,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#include "stdafx.h"
-CLIST_INTERFACE *pcli;
CMPlugin g_plugin;
IconItem iconList[] =
@@ -62,8 +61,6 @@ static int ShutdownModulesLoaded(WPARAM, LPARAM)
extern "C" __declspec(dllexport) int Load(void)
{
- pcli = Clist_GetInterface();
-
INITCOMMONCONTROLSEX icc;
icc.dwSize = sizeof(icc);
icc.dwICC = ICC_DATE_CLASSES | ICC_UPDOWN_CLASS | ICC_PROGRESS_CLASS;
diff --git a/plugins/AutoShutdown/src/shutdownsvc.cpp b/plugins/AutoShutdown/src/shutdownsvc.cpp
index b120727a7a..d1ebc110a7 100644
--- a/plugins/AutoShutdown/src/shutdownsvc.cpp
+++ b/plugins/AutoShutdown/src/shutdownsvc.cpp
@@ -147,7 +147,7 @@ static DWORD ShutdownNow(BYTE shutdownType)
OutputDebugStringA("Not ready to exit. Waiting...\n"); /* tell others, all ascii */
}
/* shutdown service must be called from main thread anyway */
- if (!DestroyWindow(pcli->hwndContactList))
+ if (!DestroyWindow(g_CLI.hwndContactList))
dwErrCode = GetLastError();
}
break;