diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-24 15:02:42 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-24 15:02:42 +0000 |
commit | 727a0432f5909ba54e6d15010fde94dff825fe5e (patch) | |
tree | 2bca1de02335533dc2678c143e7b8ff088c25d47 /plugins/SpellChecker/src | |
parent | 0ccdb951979ead80e9264233776b9147ff701fc7 (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/SpellChecker/src')
-rw-r--r-- | plugins/SpellChecker/src/utils.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/plugins/SpellChecker/src/utils.cpp b/plugins/SpellChecker/src/utils.cpp index f712daa96d..83884c35ae 100644 --- a/plugins/SpellChecker/src/utils.cpp +++ b/plugins/SpellChecker/src/utils.cpp @@ -1047,8 +1047,8 @@ TCHAR *GetWordUnderPoint(Dialog *dlg, POINT pt, CHARRANGE &sel) void AppendSubmenu(HMENU hMenu, HMENU hSubMenu, TCHAR *name)
{
- MENUITEMINFO mii = { sizeof(mii) };
- mii.cbSize = sizeof(MENUITEMINFO);
+ MENUITEMINFO mii = { 0 };
+ mii.cbSize = sizeof(mii);
mii.fMask = MIIM_SUBMENU | MIIM_TYPE;
mii.fType = MFT_STRING;
mii.hSubMenu = hSubMenu;
@@ -1062,7 +1062,8 @@ void AppendMenuItem(HMENU hMenu, int id, TCHAR *name, HICON hIcon, BOOL checked) ICONINFO iconInfo;
GetIconInfo(hIcon, &iconInfo);
- MENUITEMINFO mii = { sizeof(mii) };
+ MENUITEMINFO mii = { 0 };
+ mii.cbSize = sizeof(mii); mii.fMask = MIIM_CHECKMARKS | MIIM_TYPE | MIIM_STATE;
mii.fType = MFT_STRING;
mii.fState = (checked ? MFS_CHECKED : 0);
@@ -1456,7 +1457,7 @@ LRESULT CALLBACK MenuWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) continue;
MENUITEMINFO mii = { 0 };
- mii.cbSize = sizeof(MENUITEMINFO);
+ mii.cbSize = sizeof(mii);
mii.fMask = MIIM_STATE;
GetMenuItemInfo(hMenu, id, FALSE, &mii);
|