From 9de0202a0b12838d505825413c3cbcce5edabc11 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 6 Mar 2013 22:12:20 +0000 Subject: cleanup of the unnecessary UnhookEvent() calls git-svn-id: http://svn.miranda-ng.org/main/trunk@3909 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/BossKeyPlus/src/BossKey.cpp | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'plugins/BossKeyPlus') diff --git a/plugins/BossKeyPlus/src/BossKey.cpp b/plugins/BossKeyPlus/src/BossKey.cpp index 66715892ca..7331e958c7 100644 --- a/plugins/BossKeyPlus/src/BossKey.cpp +++ b/plugins/BossKeyPlus/src/BossKey.cpp @@ -31,7 +31,7 @@ // unique to this DLL, not to be shared HINSTANCE g_hInstance; CLIST_INTERFACE *pcli; -HANDLE g_hmGenMenuInit, g_hMenuItem, g_hHideService, g_hIsHiddenService; +HANDLE g_hMenuItem, g_hHideService, g_hIsHiddenService; HWINEVENTHOOK g_hWinHook; HWND g_hListenWindow, hDlg, g_hDlgPass, hOldForegroundWindow; HWND_ITEM *g_pMirWnds; // a pretty simple linked list @@ -628,16 +628,13 @@ void BossKeyMenuItemInit(void) // Add menu item g_hMenuItem = Menu_AddMainMenuItem(&mi); - g_hmGenMenuInit = HookEvent(ME_CLIST_PREBUILDMAINMENU, GenMenuInit); + HookEvent(ME_CLIST_PREBUILDMAINMENU, GenMenuInit); } void BossKeyMenuItemUnInit(void) // Remove menu item { CallService(MS_CLIST_REMOVEMAINMENUITEM, (WPARAM)g_hMenuItem, 0); g_hMenuItem = 0; - if(g_hmGenMenuInit) - UnhookEvent(g_hmGenMenuInit); - g_hmGenMenuInit = 0; } void RegisterCoreHotKeys (void) @@ -841,9 +838,6 @@ extern "C" int __declspec(dllexport) Unload(void) { UninitIdleTimer(); - if(g_hmGenMenuInit) - UnhookEvent(g_hmGenMenuInit); - if (g_hWinHook != 0) UnhookWinEvent(g_hWinHook); -- cgit v1.2.3