summaryrefslogtreecommitdiff
path: root/plugins/Popup/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-11-28 21:45:37 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-11-28 21:45:37 +0000
commit30707c980d1560b358dbf2671a4d2a26a1e8173c (patch)
tree74aee5adaaac976e1398274ca64c5461a60f1feb /plugins/Popup/src
parent335ec43a4bfdcbbd0b2257037f1f3e0553d89076 (diff)
various menu initialization quirks
git-svn-id: http://svn.miranda-ng.org/main/trunk@2552 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Popup/src')
-rw-r--r--plugins/Popup/src/main.cpp15
1 files changed, 5 insertions, 10 deletions
diff --git a/plugins/Popup/src/main.cpp b/plugins/Popup/src/main.cpp
index 67c805844c..764a7acc20 100644
--- a/plugins/Popup/src/main.cpp
+++ b/plugins/Popup/src/main.cpp
@@ -179,9 +179,7 @@ static int IconsChanged(WPARAM wParam,LPARAM lParam)
{
LoadActions();
- CLISTMENUITEM mi = { 0 };
- mi.cbSize = sizeof(mi);
-
+ CLISTMENUITEM mi = { sizeof(mi) };
if (PopUpOptions.ModuleIsEnabled == TRUE) { //The module is enabled.
//The action to do is "disable popups" (show disabled) and we must write "enable popup" in the new item.
mi.hIcon = IcoLib_GetIcon(ICO_POPUP_ON,0);
@@ -225,9 +223,8 @@ INT_PTR svcEnableDisableMenuCommand(WPARAM wp, LPARAM lp)
{
int iResult = 0;
int iResultRoot = 0;
- CLISTMENUITEM mi = { 0 };
- mi.cbSize = sizeof(mi);
+ CLISTMENUITEM mi = { sizeof(mi) };
if (PopUpOptions.ModuleIsEnabled) {
//The module is enabled.
//The action to do is "disable popups" (show disabled) and we must write "enable popup" in the new item.
@@ -261,11 +258,9 @@ INT_PTR svcShowHistory(WPARAM, LPARAM)
return 0;
}
-void InitMenuItems(void) {
- CLISTMENUITEM mi={0};
-
- // Common
- mi.cbSize = sizeof(mi);
+void InitMenuItems(void)
+{
+ CLISTMENUITEM mi = { sizeof(mi) };
// support new genmenu style
mi.flags = CMIF_ROOTHANDLE|CMIF_TCHAR;
mi.hParentMenu = HGENMENU_ROOT;