summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-12-08 19:08:48 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-12-08 19:08:48 +0000
commita969ecc545180bd10a270050f0038e52d37141a7 (patch)
tree293330c6efeac33f274dd945b169bfde9f2ca196
parent7fab27be6c6ed18e5dc3af4ac28b7e1dccdea898 (diff)
unified menu for mmap & dbeditor
git-svn-id: http://svn.miranda-ng.org/main/trunk@7089 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--plugins/Db3x_mmap/src/ui.cpp10
-rw-r--r--plugins/DbEditorPP/src/main.cpp1
2 files changed, 8 insertions, 3 deletions
diff --git a/plugins/Db3x_mmap/src/ui.cpp b/plugins/Db3x_mmap/src/ui.cpp
index 0c74569dcd..8e98974c09 100644
--- a/plugins/Db3x_mmap/src/ui.cpp
+++ b/plugins/Db3x_mmap/src/ui.cpp
@@ -261,12 +261,16 @@ static int OnModulesLoaded(PVOID obj, WPARAM, LPARAM)
// main menu item
CLISTMENUITEM mi = { sizeof(mi) };
- mi.flags = CMIM_ALL;
+ mi.pszName = LPGEN("Database");
+ mi.position = 500000000;
+ mi.flags = CMIF_ROOTHANDLE;
+ mi.icolibItem = iconList[0].hIcolib;
+ HGENMENU hMenuRoot = Menu_AddMainMenuItem(&mi);
+
mi.icolibItem = iconList[1].hIcolib;
mi.pszName = db->GetMenuTitle();
- mi.pszPopupName = LPGEN("Database");
+ mi.hParentMenu = hMenuRoot;
mi.pszService = MS_DB_CHANGEPASSWORD;
- mi.position = 500000000;
hSetPwdMenu = Menu_AddMainMenuItem(&mi);
return 0;
}
diff --git a/plugins/DbEditorPP/src/main.cpp b/plugins/DbEditorPP/src/main.cpp
index 7461e12bdd..c74fa638cb 100644
--- a/plugins/DbEditorPP/src/main.cpp
+++ b/plugins/DbEditorPP/src/main.cpp
@@ -159,6 +159,7 @@ int ModulesLoaded(WPARAM wParam,LPARAM lParam)
CLISTMENUITEM mi = { sizeof(mi) };
mi.position = 1900000001;
mi.hIcon = LoadIcon(hInst, MAKEINTRESOURCE(ICO_REGEDIT));
+ mi.pszPopupName = "Database";
mi.pszName = modFullname;
mi.pszService = "DBEditorpp/MenuCommand";
Menu_AddMainMenuItem(&mi);