From 5fdbe74ef5349341f2f513c92c920a57e9c9648b Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 7 Sep 2016 18:33:37 +0000 Subject: attempt to fix rclick on popups in NewXstatusNotify git-svn-id: http://svn.miranda-ng.org/main/trunk@17273 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/NewXstatusNotify/src/popup.cpp | 10 +++++----- src/mir_app/src/menu_utils.cpp | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/plugins/NewXstatusNotify/src/popup.cpp b/plugins/NewXstatusNotify/src/popup.cpp index 9dfc797344..386f9f3196 100644 --- a/plugins/NewXstatusNotify/src/popup.cpp +++ b/plugins/NewXstatusNotify/src/popup.cpp @@ -103,9 +103,9 @@ void QueryAwayMessage(HWND hWnd, PLUGINDATA *pdp) (CallProtoService(szProto, PS_GETCAPS, PFLAGNUM_3, 0) & Proto_Status2Flag(pdp->newStatus))) { pdp->hWnd = hWnd; - //The following HookEventMessage will hook the ME_PROTO_ACK event and send a WM_AWAYMSG to hWnd when the hooks get notified. + // The following HookEventMessage will hook the ME_PROTO_ACK event and send a WM_AWAYMSG to hWnd when the hooks get notified. pdp->hAwayMsgHook = HookEventParam(ME_PROTO_ACK, AwayMsgHook, (LPARAM)pdp); - //The following instruction asks Miranda to retrieve the away message and associates a hProcess (handle) to this request. This handle will appear in the ME_PROTO_ACK event. + // The following instruction asks Miranda to retrieve the away message and associates a hProcess (handle) to this request. This handle will appear in the ME_PROTO_ACK event. pdp->hAwayMsgProcess = (HANDLE)ProtoChainSend(hContact, PSS_GETAWAYMSG, 0, 0); } } @@ -154,14 +154,14 @@ LRESULT CALLBACK PopupDlgProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lPa PLUGINDATA *pdp = NULL; switch (message) { - case WM_MEASUREITEM: //Needed by the contact's context menu + case WM_MEASUREITEM: // Needed by the contact's context menu return Menu_MeasureItem(lParam); - case WM_DRAWITEM: //Needed by the contact's context menu + case WM_DRAWITEM: // Needed by the contact's context menu return Menu_DrawItem(lParam); case WM_COMMAND: - //This one returns TRUE if it processed the menu command, and FALSE if it did not process it. + // This one returns TRUE if it processed the menu command, and FALSE if it did not process it. if (Clist_MenuProcessCommand(LOWORD(wParam), MPCF_CONTACTMENU, PUGetContact(hwnd))) break; diff --git a/src/mir_app/src/menu_utils.cpp b/src/mir_app/src/menu_utils.cpp index 76955d5ae4..22f5634e79 100644 --- a/src/mir_app/src/menu_utils.cpp +++ b/src/mir_app/src/menu_utils.cpp @@ -444,7 +444,7 @@ int MO_ProcessCommandBySubMenuIdent(int menuID, int command, LPARAM lParam) MIR_APP_DLL(BOOL) Menu_ProcessCommandById(int command, LPARAM lParam) { if (!bIsGenMenuInited) - return -1; + return false; mir_cslock lck(csMenuHook); for (int i = 0; i < g_menus.getCount(); i++) @@ -469,7 +469,7 @@ MIR_APP_DLL(BOOL) Menu_ProcessCommand(HGENMENU hMenuItem, LPARAM lParam) } LPCSTR srvname = pimi->parent->ExecService; - CallService(srvname, (WPARAM)pimi->pUserData, lParam); + CallServiceSync(srvname, (WPARAM)pimi->pUserData, lParam); return true; } -- cgit v1.2.3