summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-12-14 13:46:20 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-12-14 13:46:20 +0000
commit4ac6a5d90bfa2956aa69cd47b01f9e64db0d8cca (patch)
tree3edf2db3b1e7329e9f110bbef9a5383b5ce07f2a
parent7d2b13bf34baed9f0ca00ad0c1904b29cb752cec (diff)
yet another way to violate menu item's flags
git-svn-id: http://svn.miranda-ng.org/main/trunk@15859 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--src/mir_app/src/menu_utils.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mir_app/src/menu_utils.cpp b/src/mir_app/src/menu_utils.cpp
index 17fdcaea62..6ef5d6d9cf 100644
--- a/src/mir_app/src/menu_utils.cpp
+++ b/src/mir_app/src/menu_utils.cpp
@@ -336,8 +336,10 @@ MIR_APP_DLL(int) Menu_ModifyItem(HGENMENU hMenuItem, const TCHAR *ptszName, HAND
replaceStrT(pimi->mi.name.t, ptszName);
if (iFlags != -1) {
- // we allow to set only first 3 bits
+ Menu_SetItemFlags(hMenuItem, true, iFlags);
int oldflags = (pimi->mi.flags & 0xFFFFFFF8);
+ if (!pimi->customVisible)
+ oldflags |= CMIF_HIDDEN;
pimi->mi.flags = (iFlags & 0x07) | oldflags;
}