diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-26 22:03:02 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-26 22:03:02 +0000 |
commit | be616d81bdaf8fd4ae61b0a145fb81bbdf467994 (patch) | |
tree | c0d4798a8e882583f74eb166508e0f4ce96bd4e4 /plugins/YAPP/src | |
parent | c89c550677f40d8b2010de442053cba81ba06d96 (diff) |
YEEHAW! CLISTMENUITEM::pszPopupName also died
git-svn-id: http://svn.miranda-ng.org/main/trunk@14404 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/YAPP/src')
-rw-r--r-- | plugins/YAPP/src/services.cpp | 1 | ||||
-rw-r--r-- | plugins/YAPP/src/yapp.cpp | 15 |
2 files changed, 4 insertions, 12 deletions
diff --git a/plugins/YAPP/src/services.cpp b/plugins/YAPP/src/services.cpp index c314328c05..e80b50203a 100644 --- a/plugins/YAPP/src/services.cpp +++ b/plugins/YAPP/src/services.cpp @@ -194,7 +194,6 @@ static INT_PTR GetOpaque(WPARAM wParam, LPARAM lParam) void UpdateMenu()
{
bool isEnabled = db_get_b(0, "Popup", "ModuleIsEnabled", 1) == 1;
-
if (isEnabled) {
Menu_ModifyItem(hMenuItem, LPGENT("Disable Popups"), IcoLib_GetIcon(ICO_POPUP_ON));
Menu_ModifyItem(hMenuRoot, NULL, IcoLib_GetIcon(ICO_POPUP_ON));
diff --git a/plugins/YAPP/src/yapp.cpp b/plugins/YAPP/src/yapp.cpp index 323712e943..c937996dcf 100644 --- a/plugins/YAPP/src/yapp.cpp +++ b/plugins/YAPP/src/yapp.cpp @@ -168,18 +168,11 @@ void InitMenuItems(void) {
bool isEnabled = db_get_b(0, "Popup", "ModuleIsEnabled", 1) == 1;
- CLISTMENUITEM mi = { 0 };
- mi.flags = CMIF_ROOTHANDLE|CMIF_TCHAR;
- mi.hParentMenu = HGENMENU_ROOT;
-
- // Build main menu
- mi.position = 500010000;
- mi.ptszName = LPGENT("Popups");
- mi.hIcon = IcoLib_GetIcon(isEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
- hMenuRoot = Menu_AddMainMenuItem(&mi);
+ hMenuRoot = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 500010000, IcoLib_GetIcon(isEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0));
- // Add item to main menu
- mi.hParentMenu = (HGENMENU)hMenuRoot;
+ CLISTMENUITEM mi = { 0 };
+ mi.flags = CMIF_TCHAR;
+ mi.hParentMenu = hMenuRoot;
mi.hIcon = IcoLib_GetIcon(ICO_HISTORY, 0);
mi.pszService= MS_POPUP_SHOWHISTORY;
|