summaryrefslogtreecommitdiff
path: root/plugins/Clist_nicer
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-06-24 15:02:42 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-06-24 15:02:42 +0000
commit727a0432f5909ba54e6d15010fde94dff825fe5e (patch)
tree2bca1de02335533dc2678c143e7b8ff088c25d47 /plugins/Clist_nicer
parent0ccdb951979ead80e9264233776b9147ff701fc7 (diff)
fixes for MENUITEMINFO declarations
git-svn-id: http://svn.miranda-ng.org/main/trunk@14363 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_nicer')
-rw-r--r--plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp6
-rw-r--r--plugins/Clist_nicer/src/clistevents.cpp12
2 files changed, 11 insertions, 7 deletions
diff --git a/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp b/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp
index cbce3fa8a4..d203d954c9 100644
--- a/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp
+++ b/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp
@@ -108,7 +108,8 @@ INT_PTR GroupMenuCheckService(WPARAM, LPARAM)
INT_PTR GroupMenuonAddService(WPARAM wParam, LPARAM lParam)
{
MENUITEMINFO *mii = (MENUITEMINFO *)wParam;
- if (mii == NULL) return 0;
+ if (mii == NULL)
+ return 0;
if (hHideShowMainMenuItem == (HANDLE)lParam) {
mii->fMask |= MIIM_STATE;
@@ -418,7 +419,8 @@ INT_PTR SubGroupMenuCheckService(WPARAM, LPARAM)
INT_PTR SubGroupMenuonAddService(WPARAM wParam, LPARAM)
{
MENUITEMINFO *mii = (MENUITEMINFO *)wParam;
- if (mii == NULL) return 0;
+ if (mii == NULL)
+ return 0;
/*
if (hHideShowMainMenuItem == (HANDLE)lParam) {
diff --git a/plugins/Clist_nicer/src/clistevents.cpp b/plugins/Clist_nicer/src/clistevents.cpp
index 47fe8121d9..9d7e722d8b 100644
--- a/plugins/Clist_nicer/src/clistevents.cpp
+++ b/plugins/Clist_nicer/src/clistevents.cpp
@@ -158,20 +158,21 @@ LRESULT CALLBACK EventAreaWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPa
case WM_COMMAND:
if (LOWORD(wParam) == IDC_NOTIFYBUTTON) {
int iSelection;
- MENUITEMINFO mii = { 0 };
- POINT pt;
struct NotifyMenuItemExData *nmi = 0;
int iCount = GetMenuItemCount(cfg::dat.hMenuNotify);
- BOOL result;
+ POINT pt;
GetCursorPos(&pt);
+
+ MENUITEMINFO mii = { 0 };
mii.cbSize = sizeof(mii);
mii.fMask = MIIM_DATA;
if (iCount > 1)
iSelection = TrackPopupMenu(cfg::dat.hMenuNotify, TPM_RETURNCMD, pt.x, pt.y, 0, hwnd, NULL);
else
iSelection = GetMenuItemID(cfg::dat.hMenuNotify, 0);
- result = GetMenuItemInfo(cfg::dat.hMenuNotify, (UINT)iSelection, FALSE, &mii);
+
+ BOOL result = GetMenuItemInfo(cfg::dat.hMenuNotify, (UINT)iSelection, FALSE, &mii);
if (result != 0) {
nmi = (struct NotifyMenuItemExData *) mii.dwItemData;
if (nmi) {
@@ -260,7 +261,8 @@ CListEvent* AddEvent(CLISTEVENT *cle)
return NULL;
if (p->cle.hContact != 0 && p->cle.hDbEvent != 1 && !(p->cle.flags & CLEF_ONLYAFEW)) {
- MENUITEMINFO mii = { sizeof(mii) };
+ MENUITEMINFO mii = { 0 };
+ mii.cbSize = sizeof(mii);
mii.fMask = MIIM_DATA | MIIM_BITMAP | MIIM_ID;
if (p->cle.pszService && !strncmp("SRMsg/ReadMessage", p->cle.pszService, 17)) {
// dup check only for msg events