diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-28 17:41:48 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-28 17:41:48 +0000 |
commit | 59cd198e89782263777c57dcd54704ecb1e10212 (patch) | |
tree | 9515cc2c31c1254c330e79906bb669279af9b8a5 | |
parent | ca2afc50a432cefe892c6877710642bce6bd57c9 (diff) |
finally CLISTEVENT removed completely
git-svn-id: http://svn.miranda-ng.org/main/trunk@14430 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
173 files changed, 1017 insertions, 1107 deletions
diff --git a/bin10/lib/mir_app64.lib b/bin10/lib/mir_app64.lib Binary files differindex c5f5a9394e..4774014a24 100644 --- a/bin10/lib/mir_app64.lib +++ b/bin10/lib/mir_app64.lib diff --git a/bin12/lib/mir_app64.lib b/bin12/lib/mir_app64.lib Binary files differindex c5f5a9394e..4774014a24 100644 --- a/bin12/lib/mir_app64.lib +++ b/bin12/lib/mir_app64.lib diff --git a/include/delphi/m_clist.inc b/include/delphi/m_clist.inc index 251b5d68f6..9c54fae5d5 100644 --- a/include/delphi/m_clist.inc +++ b/include/delphi/m_clist.inc @@ -46,47 +46,6 @@ const }
MS_CLIST_GETSTATUSMODEDESCRIPTION:PAnsiChar = 'CList/GetStatusModeDescription';
-const
- CMIF_GRAYED = 1;
- CMIF_CHECKED = 2;
- CMIF_HIDDEN = 4; // only works on contact menus
- CMIF_NOTOFFLINE = 8; // item won't appear for contacts that are offline
- CMIF_NOTONLINE = 16; // " online
- CMIF_NOTONLIST = 32; // item won't appear on standard contacts
- CMIF_NOTOFFLIST = 64; // item won't appear on contacts that have the 'NotOnList' setting
- CMIF_UNICODE = 512; // will return TCHAR* instead of AnsiChar*
- CMIF_KEEPUNTRANSLATED = 1024; // don't translate a menu item
-
- CMIF_DEFAULT = 4096; // this menu item is the default one
-
-type
-// WARNING: do not use Translate(TS) for p(t)szName or p(t)szPopupName as they
-// are translated by the core, which may lead to double translation.
-// Use LPGEN instead which are just dummy wrappers/markers for "lpgen.pl".
- PCLISTMENUITEM = ^TCLISTMENUITEM;
- TCLISTMENUITEM = record
- szName : TChar; // [TRANSLATED-BY-CORE] text of the menu item
- flags : dword; // combination of CMIF_*
- position : int; // approx position on the menu, lower numbers go nearer the top
- hIcon : THANDLE; // icon to put by the item, if this was *not* loaded from
- // a resource, you can delete it straight after the call
- pszService : PAnsiChar; // name of the service to call when the service is clicked
- hParentMenu : THANDLE; // parent menu hamdle
- hLangpack : int; // plugin's hLangpack (added automatically)
- end;
-
-function _AddMainMenuItem(mi:PCLISTMENUITEM; hlang:integer) : HGENMENU; stdcall;
- external AppDll name 'Menu_AddMainMenuItem';
-
-function _AddContactMenuItem(mi:PCLISTMENUITEM; pszProto:PAnsiChar; hlang:integer) : HGENMENU; stdcall;
- external AppDll name 'Menu_AddContactMenuItem';
-
-function _AddProtoMenuItem(mi:PCLISTMENUITEM; pszProto:PAnsiChar; hlang:integer) : HGENMENU; stdcall;
- external AppDll name 'Menu_AddProtoMenuItem';
-
-function _AddStatusMenuItem(mi:PCLISTMENUITEM; pszProto:PAnsiChar; hlang:integer) : HGENMENU; stdcall;
- external AppDll name 'Menu_AddStatusMenuItem';
-
function Menu_BuildContactMenu(hContact:TMCONTACT) : HMENU; stdcall;
external AppDll name 'Menu_BuildContactMenu';
diff --git a/include/delphi/m_clistint.inc b/include/delphi/m_clistint.inc index 64040a535d..33e2ab5d7e 100644 --- a/include/delphi/m_clistint.inc +++ b/include/delphi/m_clistint.inc @@ -520,7 +520,6 @@ type * version 6 additions (0.8.0.x) - accounts
*************************************************************************************)
pfnGetAccountIndexByPos : function (pos:int):int; cdecl;
- pfnConvertMenu: function( clitem:PCLISTMENUITEM; moitem:PMO_MenuItem):int; cdecl;
(*************************************************************************************
* version 7 additions (0.11.0.x) - extra images
diff --git a/include/delphi/m_genmenu.inc b/include/delphi/m_genmenu.inc index b152cb8106..ad49a1c160 100644 --- a/include/delphi/m_genmenu.inc +++ b/include/delphi/m_genmenu.inc @@ -141,18 +141,44 @@ const SETTING_NOOFFLINEBOTTOM_DEFAULT = 0;
+const
+ CMIF_GRAYED = 1;
+ CMIF_CHECKED = 2;
+ CMIF_HIDDEN = 4; // only works on contact menus
+ CMIF_NOTOFFLINE = 8; // item won't appear for contacts that are offline
+ CMIF_NOTONLINE = 16; // " online
+ CMIF_NOTONLIST = 32; // item won't appear on standard contacts
+ CMIF_NOTOFFLIST = 64; // item won't appear on contacts that have the 'NotOnList' setting
+ CMIF_UNICODE = 512; // will return TCHAR* instead of AnsiChar*
+ CMIF_KEEPUNTRANSLATED = 1024; // don't translate a menu item
+
+ CMIF_DEFAULT = 4096; // this menu item is the default one
+
type
PMO_MenuItem = ^TMO_MenuItem;
TMO_MenuItem = record
- position :int;
- root :HGENMENU;
- szName :TCHAR;
- flags :integer;
- hIcon :HICON; // or hIcolibItem:THANDLE;
- ownerdata:^pointer;
- hLangpack:int;
+ position :int;
+ pszService:PAnsiChar;
+ root :HGENMENU;
+ szName :TCHAR;
+ flags :integer;
+ hIcon :HICON; // or hIcolibItem:THANDLE;
+ ownerdata :^pointer;
+ hLangpack :int;
end;
+function _AddMainMenuItem(mi:PMO_MenuItem; hlang:integer) : HGENMENU; stdcall;
+ external AppDll name 'Menu_AddMainMenuItem';
+
+function _AddContactMenuItem(mi:PMO_MenuItem; pszProto:PAnsiChar; hlang:integer) : HGENMENU; stdcall;
+ external AppDll name 'Menu_AddContactMenuItem';
+
+function _AddProtoMenuItem(mi:PMO_MenuItem; pszProto:PAnsiChar; hlang:integer) : HGENMENU; stdcall;
+ external AppDll name 'Menu_AddProtoMenuItem';
+
+function _AddStatusMenuItem(mi:PMO_MenuItem; pszProto:PAnsiChar; hlang:integer) : HGENMENU; stdcall;
+ external AppDll name 'Menu_AddStatusMenuItem';
+
{
This structure passed to CheckService.
}
diff --git a/include/delphi/m_helpers.inc b/include/delphi/m_helpers.inc index 72a0b66103..ac89dd005f 100644 --- a/include/delphi/m_helpers.inc +++ b/include/delphi/m_helpers.inc @@ -52,12 +52,12 @@ function Srmm_GetNthIcon(hContact:TMCONTACT; index:int):pStatusIconData; function SkinAddNewSound(const name, description, defaultFile: PAnsiChar): int_ptr;
function SkinPlaySound (const name: PAnsiChar): int_ptr;
-function Menu_AddContextFrameMenuItem(mi:PCLISTMENUITEM):HGENMENU;
-function Menu_AddMainMenuItem (mi:PCLISTMENUITEM):HGENMENU;
-function Menu_AddContactMenuItem (mi:PCLISTMENUITEM):HGENMENU;
-function Menu_AddStatusMenuItem (mi:PCLISTMENUITEM):HGENMENU;
-function Menu_AddProtoMenuItem (mi:PCLISTMENUITEM):HGENMENU;
-function Menu_AddTrayMenuItem (mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddContextFrameMenuItem(mi:PMO_MenuItem):HGENMENU;
+function Menu_AddMainMenuItem (mi:PMO_MenuItem):HGENMENU;
+function Menu_AddContactMenuItem (mi:PMO_MenuItem):HGENMENU;
+function Menu_AddStatusMenuItem (mi:PMO_MenuItem):HGENMENU;
+function Menu_AddProtoMenuItem (mi:PMO_MenuItem):HGENMENU;
+function Menu_AddTrayMenuItem (mi:PMO_MenuItem):HGENMENU;
function UserInfo_AddPage(wParam:WPARAM; odp:POPTIONSDIALOGPAGE):int_ptr;
function Options_AddPage (wParam:WPARAM; odp:POPTIONSDIALOGPAGE):int_ptr;
@@ -384,33 +384,33 @@ begin end;
-function Menu_AddContextFrameMenuItem(mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddContextFrameMenuItem(mi:PMO_MenuItem):HGENMENU;
begin
mi^.hLangpack:=hLangpack;
result:=CallService(MS_CLIST_ADDCONTEXTFRAMEMENUITEM, 0,LPARAM(mi));
end;
-function Menu_AddMainMenuItem(mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddMainMenuItem(mi:PMO_MenuItem):HGENMENU;
begin
result:=_AddMainMenuItem(mi, hLangpack);
end;
-function Menu_AddContactMenuItem(mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddContactMenuItem(mi:PMO_MenuItem):HGENMENU;
begin
result:=_AddContactMenuItem(mi, nil, hLangpack);
end;
-function Menu_AddStatusMenuItem(mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddStatusMenuItem(mi:PMO_MenuItem):HGENMENU;
begin
result:=_AddStatusMenuItem(mi, nil, hLangpack);
end;
-function Menu_AddProtoMenuItem(mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddProtoMenuItem(mi:PMO_MenuItem):HGENMENU;
begin
result:=_AddProtoMenuItem(mi, nil, hLangpack);
end;
-function Menu_AddTrayMenuItem(mi:PCLISTMENUITEM):HGENMENU;
+function Menu_AddTrayMenuItem(mi:PMO_MenuItem):HGENMENU;
begin
mi^.hLangpack:=hLangpack;
result:=CallService(MS_CLIST_ADDTRAYMENUITEM, 0,LPARAM(mi));
diff --git a/include/m_clist.h b/include/m_clist.h index 38cce1e062..803fe25ba5 100644 --- a/include/m_clist.h +++ b/include/m_clist.h @@ -75,40 +75,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #define GSMDF_UNTRANSLATED 4
#define MS_CLIST_GETSTATUSMODEDESCRIPTION "CList/GetStatusModeDescription"
-struct CLISTMENUITEM
-{
- MAllStrings name; // [TRANSLATED-BY-CORE] text of the menu item
- DWORD flags; // set of CMIF_* flags
- int position; // approx position on the menu. lower numbers go nearer the top
- HANDLE icolibItem; // set CMIF_ICONFROMICOLIB to pass this value
- char* pszService; // name of service to call when the item gets selected
- HGENMENU hParentMenu; // HGENMENU_ROOT or NULL means the root menu
- int hLangpack; // plugin's hLangpack (added automatically)
-};
-
-#define CMIF_GRAYED 1
-#define CMIF_CHECKED 2
-#define CMIF_HIDDEN 4 //only works on contact menus
-#define CMIF_NOTOFFLINE 8 //item won't appear for contacts that are offline
-#define CMIF_NOTONLINE 16 // " online
-#define CMIF_NOTONLIST 32 //item won't appear on standard contacts
-#define CMIF_NOTOFFLIST 64 //item won't appear on contacts that have the 'NotOnList' setting
-
-#define CMIF_UNICODE 512 //will return TCHAR* instead of char*
-#if defined(_UNICODE)
- #define CMIF_TCHAR CMIF_UNICODE //will return TCHAR* instead of char*
-#else
- #define CMIF_TCHAR 0 //will return char*, as usual
-#endif
-
-#define CMIF_KEEPUNTRANSLATED 1024 // don't translate a menu item
-#define CMIF_DEFAULT 4096 // this menu item is the default one
-
/////////////////////////////////////////////////////////////////////////////////////////
// MAIN MENU
// adds a new element into main menu
-EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddMainMenuItem(CLISTMENUITEM *mi, int = hLangpack);
+EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddMainMenuItem(TMO_MenuItem *mi, int = hLangpack);
// gets a handle to the main Miranda menu
// returns a HMENU. This need not to be freed since it's owned by clist
@@ -127,7 +98,7 @@ EXTERN_C MIR_APP_DLL(HMENU) Menu_BuildMainMenu(void); // CONTACT MENU
// adds a new element into contact menu
-EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddContactMenuItem(CLISTMENUITEM *mi, const char *pszProto = NULL, int = hLangpack);
+EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddContactMenuItem(TMO_MenuItem *mi, const char *pszProto = NULL, int = hLangpack);
// builds the context menu for a specific contact
// returns a HMENU identifying the menu. This should be DestroyMenu()ed when
@@ -147,7 +118,7 @@ EXTERN_C MIR_APP_DLL(HMENU) Menu_BuildContactMenu(MCONTACT hContact); EXTERN_C MIR_APP_DLL(HMENU) Menu_GetStatusMenu(void);
// adds an item to a status menu
-EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddStatusMenuItem(CLISTMENUITEM *mi, const char *pszProto = NULL, int = hLangpack);
+EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddStatusMenuItem(TMO_MenuItem *mi, const char *pszProto = NULL, int = hLangpack);
// the status menu is about to be built
// wParam = lParam = 0
@@ -157,7 +128,7 @@ EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddStatusMenuItem(CLISTMENUITEM *mi, const c // PROTOCOL MENU
// adds an item to status or main menu, according to the option
-EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddProtoMenuItem(CLISTMENUITEM *mi, const char *pszProto = NULL, int = hLangpack);
+EXTERN_C MIR_APP_DLL(HGENMENU) Menu_AddProtoMenuItem(TMO_MenuItem *mi, const char *pszProto = NULL, int = hLangpack);
/////////////////////////////////////////////////////////////////////////////////////////
// GROUP MENU
@@ -176,9 +147,9 @@ GroupMenuParam, *lpGroupMenuParam; // add a new item to the Group menus
// wParam=lpGroupMenuParam, params to call when exec menuitem
-// lParam=(LPARAM)(CLISTMENUITEM*)&mi
+// lParam=(LPARAM)(TMO_MenuItem*)&mi
-__forceinline HGENMENU Menu_AddGroupMenuItem(lpGroupMenuParam gmp, CLISTMENUITEM *mi)
+__forceinline HGENMENU Menu_AddGroupMenuItem(lpGroupMenuParam gmp, TMO_MenuItem *mi)
{
mi->hLangpack = hLangpack;
return (HGENMENU)CallService("CList/AddGroupMenuItem", (WPARAM)gmp, (LPARAM)mi);
@@ -198,9 +169,9 @@ __forceinline HGENMENU Menu_AddGroupMenuItem(lpGroupMenuParam gmp, CLISTMENUITEM // add a new item to the SubGroup menus
// wParam=lpGroupMenuParam, params to call when exec menuitem
-// lParam=(LPARAM)(CLISTMENUITEM*)&mi
+// lParam=(LPARAM)(TMO_MenuItem*)&mi
-__forceinline HGENMENU Menu_AddSubGroupMenuItem(lpGroupMenuParam gmp, CLISTMENUITEM *mi)
+__forceinline HGENMENU Menu_AddSubGroupMenuItem(lpGroupMenuParam gmp, TMO_MenuItem *mi)
{
mi->hLangpack = hLangpack;
return (HGENMENU)CallService("CList/AddSubGroupMenuItem", (WPARAM)gmp, (LPARAM)mi);
@@ -220,9 +191,9 @@ __forceinline HGENMENU Menu_AddSubGroupMenuItem(lpGroupMenuParam gmp, CLISTMENUI // add a new item to the tray menus
// wParam=0
-// lParam=(LPARAM)(CLISTMENUITEM*)&mi
+// lParam=(LPARAM)(TMO_MenuItem*)&mi
-__forceinline HGENMENU Menu_AddTrayMenuItem(CLISTMENUITEM *mi)
+__forceinline HGENMENU Menu_AddTrayMenuItem(TMO_MenuItem *mi)
{
mi->hLangpack = hLangpack;
return (HGENMENU)CallService("CList/AddTrayMenuItem", 0, (LPARAM)mi);
diff --git a/include/m_clistint.h b/include/m_clistint.h index d518d92a79..7890028d09 100644 --- a/include/m_clistint.h +++ b/include/m_clistint.h @@ -463,7 +463,6 @@ typedef struct * version 6 additions (0.8.0.x) - accounts
*************************************************************************************/
int (*pfnGetAccountIndexByPos)(int pos);
- int (*pfnConvertMenu)(CLISTMENUITEM*, TMO_MenuItem*);
/*************************************************************************************
* version 7 additions (0.11.0.x) - extra images
diff --git a/include/m_cluiframes.h b/include/m_cluiframes.h index a52f65375e..39ac12cfc5 100644 --- a/include/m_cluiframes.h +++ b/include/m_cluiframes.h @@ -231,9 +231,9 @@ typedef struct tagCLISTFrame { //popupposition=frameid
//contactowner=advanced parameter
-__forceinline HGENMENU Menu_AddContextFrameMenuItem(CLISTMENUITEM *mi)
-{ mi->hLangpack = hLangpack;
- return (HGENMENU)CallService("CList/AddContextFrameMenuItem", 0, (LPARAM)mi);
+__forceinline HGENMENU Menu_AddContextFrameMenuItem(TMO_MenuItem *pmi)
+{ pmi->hLangpack = hLangpack;
+ return (HGENMENU)CallService("CList/AddContextFrameMenuItem", 0, (LPARAM)pmi);
}
//////////////////////////////////////////////////////////////////////////
diff --git a/include/m_genmenu.h b/include/m_genmenu.h index 9ecbfadb31..20ca70b020 100644 --- a/include/m_genmenu.h +++ b/include/m_genmenu.h @@ -17,20 +17,37 @@ #define MO_PROTO (-3)
#define MO_STATUS (-4)
-#define SETTING_NOOFFLINEBOTTOM_DEFAULT 0
+#define CMIF_GRAYED 1
+#define CMIF_CHECKED 2
+#define CMIF_HIDDEN 4 //only works on contact menus
+#define CMIF_NOTOFFLINE 8 //item won't appear for contacts that are offline
+#define CMIF_NOTONLINE 16 // " online
+#define CMIF_NOTONLIST 32 //item won't appear on standard contacts
+#define CMIF_NOTOFFLIST 64 //item won't appear on contacts that have the 'NotOnList' setting
+
+#define CMIF_UNICODE 512 //will return TCHAR* instead of char*
+#if defined(_UNICODE)
+#define CMIF_TCHAR CMIF_UNICODE //will return TCHAR* instead of char*
+#else
+#define CMIF_TCHAR 0 //will return char*, as usual
+#endif
+
+#define CMIF_KEEPUNTRANSLATED 1024 // don't translate a menu item
+#define CMIF_DEFAULT 4096 // this menu item is the default one
struct TMO_MenuItem
{
int position;
+ const char *pszService;
HGENMENU root;
MAllStrings name;
- int flags;
+ int flags; // set of CMIF_* constants
union {
HICON hIcon;
HANDLE hIcolibItem;
};
void *ownerdata;
- int hLangpack;
+ int hLangpack;
};
/*
diff --git a/plugins/Actman/ua/i_uaplaces.inc b/plugins/Actman/ua/i_uaplaces.inc index d6307a6c36..38531a19a3 100644 --- a/plugins/Actman/ua/i_uaplaces.inc +++ b/plugins/Actman/ua/i_uaplaces.inc @@ -324,7 +324,7 @@ begin end;
end;
-function MakeMenuItem(mtype:tMenuType;clmi:PCListMenuItem):THANDLE;
+function MakeMenuItem(mtype:tMenuType;clmi:PMO_MenuItem):THANDLE;
begin
case mtype of
main_menu : result:=Menu_AddMainMenuItem(clmi);
@@ -342,7 +342,7 @@ var extra:pWideChar;
ActItem:pMyActionItem;
ActMItem,UAMenuItem:pUAMenuItem;
- clmi:TCListMenuItem;
+ mi:TMO_MenuItem;
i:integer;
res:boolean;
begin
@@ -376,36 +376,36 @@ begin // need to create popup menu
if not res then
begin
- FillChar(clmi,SizeOf(clmi),0);
+ FillChar(mi,SizeOf(mi),0);
if (UAMenuItem.menu_opt and UAF_NOTRANS)<>0 then
- clmi.flags :=CMIF_UNICODE or CMIF_KEEPUNTRANSLATED
+ mi.flags :=CMIF_UNICODE or CMIF_KEEPUNTRANSLATED
else
- clmi.flags :=CMIF_UNICODE{ or CMIF_ICONFROMICOLIB};
+ mi.flags :=CMIF_UNICODE{ or CMIF_ICONFROMICOLIB};
if (UAMenuItem.szMenuPopup<>nil) and (UAMenuItem.szMenuPopup^<>#0) then
begin
if (UAMenuItem.menu_opt and UAF_MSUBVAR)<>0 then
- clmi.szName.w:=ParseVarString(UAMenuItem.szMenuPopup)
+ mi.szName.w:=ParseVarString(UAMenuItem.szMenuPopup)
else
- clmi.szName.w:=UAMenuItem.szMenuPopup;
+ mi.szName.w:=UAMenuItem.szMenuPopup;
end
else
- clmi.szName.w:=nil;
- if clmi.szName.w=nil then
- clmi.szName.w:=ActionItem.szActDescr;
+ mi.szName.w:=nil;
+ if mi.szName.w=nil then
+ mi.szName.w:=ActionItem.szActDescr;
- clmi.hIcon :=AddRootMenuIcon(clmi.szName.w);
- clmi.position:=ActionItem.wSortIndex*10;
+ mi.hIcon :=AddRootMenuIcon(mi.szName.w);
+ mi.position:=ActionItem.wSortIndex*10;
// position in Root Menu
- inc(clmi.position,GetMenuPosition(0,mtype,
+ inc(mi.position,GetMenuPosition(0,mtype,
(UAMenuItem.menu_opt and UAF_MENUSEP)<>0));
- UAMenuItem.hMenuRoot:=MakeMenuItem(mtype,@clmi);
+ UAMenuItem.hMenuRoot:=MakeMenuItem(mtype,@mi);
- if (clmi.szName.w<>ActionItem.szActDescr) and
- (clmi.szName.w<>UAMenuItem.szMenuPopup) then
- mFreeMem(clmi.szName.w);
+ if (mi.szName.w<>ActionItem.szActDescr) and
+ (mi.szName.w<>UAMenuItem.szMenuPopup) then
+ mFreeMem(mi.szName.w);
for i:=1 to HIGH(arMenuRec) do
begin
@@ -423,55 +423,55 @@ begin // Now Menu Item preparing
{}{}
- FillChar(clmi,SizeOf(clmi),0);
+ FillChar(mi,SizeOf(mi),0);
if (UAMenuItem.menu_opt and UAF_NOTRANS)<>0 then
- clmi.flags :=CMIF_UNICODE or CMIF_KEEPUNTRANSLATED
+ mi.flags :=CMIF_UNICODE or CMIF_KEEPUNTRANSLATED
else
- clmi.flags :=CMIF_UNICODE{ or CMIF_ICONFROMICOLIB};
+ mi.flags :=CMIF_UNICODE{ or CMIF_ICONFROMICOLIB};
if (ActionItem.flags and (UAF_2STATE+UAF_PRESSED))<>(UAF_2STATE+UAF_PRESSED) then
begin
- clmi.hIcon:=ActionItem.hIcolibIcon;
+ mi.hIcon:=ActionItem.hIcolibIcon;
extra:='0';
end
else
begin
- clmi.hIcon:=ActionItem.hIcolibIconPressed;
- clmi.flags:=clmi.flags or CMIF_CHECKED;
+ mi.hIcon:=ActionItem.hIcolibIconPressed;
+ mi.flags:=mi.flags or CMIF_CHECKED;
extra:='1';
end;
if (UAMenuItem.szMenuNameVars<>nil) and (UAMenuItem.szMenuNameVars^<>#0) then
begin
if (UAMenuItem.menu_opt and UAF_MNAMVAR)<>0 then
- clmi.szName.w:=ParseVarString(UAMenuItem.szMenuNameVars,0,extra)
+ mi.szName.w:=ParseVarString(UAMenuItem.szMenuNameVars,0,extra)
else
- clmi.szName.w:=UAMenuItem.szMenuNameVars;
+ mi.szName.w:=UAMenuItem.szMenuNameVars;
end
else
- clmi.szName.w:=nil;
- if clmi.szName.w=nil then
- clmi.szName.w:=ActionItem.szActDescr;
+ mi.szName.w:=nil;
+ if mi.szName.w=nil then
+ mi.szName.w:=ActionItem.szActDescr;
if UAMenuItem.hMenuRoot<>0 then
begin
- clmi.hParentMenu:=UAMenuItem.hMenuRoot;
+ mi.root:=UAMenuItem.hMenuRoot;
end;
- clmi.pszService:=ActionItem.szNameID;
+ mi.pszService:=ActionItem.szNameID;
if ActionItem.hMenuService=0 then
ActionItem.hMenuService:=CreateServiceFunctionParam(
- clmi.pszService,@ServiceCallWithFParam,ActionItem.dwActID);
+ mi.pszService,@ServiceCallWithFParam,ActionItem.dwActID);
- clmi.position:=ActionItem.wSortIndex*10;
+ mi.position:=ActionItem.wSortIndex*10;
{}{}
- inc(clmi.position,GetMenuPosition(UAMenuItem.hMenuRoot,mtype,
+ inc(mi.position,GetMenuPosition(UAMenuItem.hMenuRoot,mtype,
(UAMenuItem.menu_opt and UAF_MENUSEP)<>0));
- UAMenuItem.hMenuItem:=MakeMenuItem(mtype,@clmi);
+ UAMenuItem.hMenuItem:=MakeMenuItem(mtype,@mi);
//CallService(MenuServices[mtype],0,LPARAM(@clmi));
- if (clmi.szName.w<>ActionItem.szActDescr) and
- (clmi.szName.w<>UAMenuItem.szMenuNameVars) then
- mFreeMem(clmi.szName.w);
+ if (mi.szName.w<>ActionItem.szActDescr) and
+ (mi.szName.w<>UAMenuItem.szMenuNameVars) then
+ mFreeMem(mi.szName.w);
{}
end;
diff --git a/plugins/AddContactPlus/src/main.cpp b/plugins/AddContactPlus/src/main.cpp index c8ec5cd667..a14f14b0a5 100644 --- a/plugins/AddContactPlus/src/main.cpp +++ b/plugins/AddContactPlus/src/main.cpp @@ -92,10 +92,10 @@ static int OnAccListChanged(WPARAM, LPARAM) if (hMainMenuItem)
return 0;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500020001;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = icon.hIcolib;
+ mi.hIcolibItem = icon.hIcolib;
mi.name.t = LPGENT("&Add contact...");
mi.pszService = MS_ADDCONTACTPLUS_SHOW;
hMainMenuItem = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/Alarms/src/frame.cpp b/plugins/Alarms/src/frame.cpp index be6235ef2d..3425b91ab2 100644 --- a/plugins/Alarms/src/frame.cpp +++ b/plugins/Alarms/src/frame.cpp @@ -541,11 +541,11 @@ int CreateFrame() // create menu item
CreateServiceFunction(MODULE "/ShowHideReminders", ShowHideMenuFunc);
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = hIconMenuShowHide;
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = hIconMenuShowHide;
mi.name.a = LPGEN("Show reminders");
mi.pszService = MODULE "/ShowHideReminders";
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Alarms"), 0);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Alarms"), 0);
mi.position = 500010000;
hMenuShowReminders = Menu_AddMainMenuItem(&mi);
/////////////////////
diff --git a/plugins/Alarms/src/options.cpp b/plugins/Alarms/src/options.cpp index 322c2d87e5..1207c1c0dc 100644 --- a/plugins/Alarms/src/options.cpp +++ b/plugins/Alarms/src/options.cpp @@ -692,13 +692,13 @@ void AddMenuItem() {
if (hMainMenuItem) return;
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = IcoLib_GetIconHandle("alarms_menu_set");
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = IcoLib_GetIconHandle("alarms_menu_set");
mi.name.a = "Set alarm";
mi.pszService = MODULE "/NewAlarm";
mi.position = 500010000;
if (!ServiceExists(MS_CLIST_FRAMES_ADDFRAME))
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Alarms"), mi.position);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Alarms"), mi.position);
hMainMenuItem = Menu_AddMainMenuItem(&mi);
}
diff --git a/plugins/AuthState/src/main.cpp b/plugins/AuthState/src/main.cpp index 0915ba1ec0..21f2855cf7 100644 --- a/plugins/AuthState/src/main.cpp +++ b/plugins/AuthState/src/main.cpp @@ -197,7 +197,7 @@ extern "C" int __declspec(dllexport) Load(void) if (bContactMenuItem) {
hAuthMenuSelected = CreateServiceFunction("AuthState/MenuItem", onAuthMenuSelected);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -1999901005;
mi.flags = CMIF_TCHAR;
mi.name.t = LPGENT("Enable AuthState icons");
diff --git a/plugins/AutoShutdown/src/settingsdlg.cpp b/plugins/AutoShutdown/src/settingsdlg.cpp index 927a03c439..b5ae256e82 100644 --- a/plugins/AutoShutdown/src/settingsdlg.cpp +++ b/plugins/AutoShutdown/src/settingsdlg.cpp @@ -436,29 +436,29 @@ static HGENMENU hMainMenuItem,hTrayMenuItem; void SetShutdownMenuItem(bool fActive)
{
/* main menu */
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 2001090000;
if (fActive)
{
- mi.icolibItem = iconList[1].hIcolib;
+ mi.hIcolibItem = iconList[1].hIcolib;
mi.name.t = LPGENT("Stop automatic &shutdown");
}
else
{
- mi.icolibItem = iconList[2].hIcolib;
+ mi.hIcolibItem = iconList[2].hIcolib;
mi.name.t = LPGENT("Automatic &shutdown...");
}
mi.pszService = "AutoShutdown/MenuCommand";
mi.flags = CMIF_TCHAR;
if (hMainMenuItem != NULL)
- Menu_ModifyItem(hMainMenuItem, mi.name.t, mi.icolibItem);
+ Menu_ModifyItem(hMainMenuItem, mi.name.t, mi.hIcolibItem);
else
hMainMenuItem = Menu_AddMainMenuItem(&mi);
/* tray menu */
mi.position = 899999;
if (hTrayMenuItem != NULL)
- Menu_ModifyItem(hTrayMenuItem, mi.name.t, mi.icolibItem);
+ Menu_ModifyItem(hTrayMenuItem, mi.name.t, mi.hIcolibItem);
else
hTrayMenuItem = Menu_AddTrayMenuItem(&mi);
}
diff --git a/plugins/AvatarHistory/src/AvatarDlg.cpp b/plugins/AvatarHistory/src/AvatarDlg.cpp index 67cefbd921..5e8df39842 100644 --- a/plugins/AvatarHistory/src/AvatarDlg.cpp +++ b/plugins/AvatarHistory/src/AvatarDlg.cpp @@ -514,14 +514,14 @@ void InitMenuItem() {
CreateServiceFunction(MS_AVATARHISTORY_SHOWDIALOG, ShowDialogSvc);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = LPGENT("View Avatar History");
mi.flags = CMIF_TCHAR;
mi.position = 1000090010;
- mi.icolibItem = createDefaultOverlayedIcon(FALSE);
+ mi.hIcolibItem = createDefaultOverlayedIcon(FALSE);
mi.pszService = MS_AVATARHISTORY_SHOWDIALOG;
hMenu = Menu_AddContactMenuItem(&mi);
- DestroyIcon((HICON)mi.icolibItem);
+ DestroyIcon((HICON)mi.hIcolibItem);
}
static INT_PTR ShowDialogSvc(WPARAM wParam, LPARAM lParam)
diff --git a/plugins/BasicHistory/src/BasicHistory.cpp b/plugins/BasicHistory/src/BasicHistory.cpp index 60d262af6e..0b23c19211 100644 --- a/plugins/BasicHistory/src/BasicHistory.cpp +++ b/plugins/BasicHistory/src/BasicHistory.cpp @@ -96,9 +96,9 @@ int ToolbarModuleLoaded(WPARAM wParam,LPARAM lParam) void InitMenuItems()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000090000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_HISTORY);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_HISTORY);
mi.name.a = LPGEN("View &History");
mi.pszService = MS_HISTORY_SHOWCONTACTHISTORY;
hContactMenu = Menu_AddContactMenuItem(&mi);
@@ -108,7 +108,7 @@ void InitMenuItems() Menu_AddMainMenuItem(&mi);
mi.position = 1000090001;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
mi.name.a = LPGEN("Delete All User History");
mi.pszService = MS_HISTORY_DELETEALLCONTACTHISTORY;
hDeleteContactMenu = Menu_AddContactMenuItem(&mi);
@@ -120,9 +120,9 @@ void InitTaskMenuItems() {
if (Options::instance->taskOptions.size() > 0) {
if (hTaskMainMenu == NULL) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500060005;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_HISTORY);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_HISTORY);
mi.name.a = LPGEN("Execute history task");
hTaskMainMenu = Menu_AddMainMenuItem(&mi);
}
@@ -137,10 +137,10 @@ void InitTaskMenuItems() int pos = (int)taskMenus.size();
for (; taskIt != Options::instance->taskOptions.end(); ++taskIt) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
mi.pszService = MS_HISTORY_EXECUTE_TASK;
- mi.hParentMenu = hTaskMainMenu;
+ mi.root = hTaskMainMenu;
mi.name.t = (TCHAR*)taskIt->taskName.c_str();
HGENMENU menu = Menu_AddMainMenuItem(&mi);
Menu_ConfigureItem(menu, MCI_OPT_EXECPARAM, pos++);
diff --git a/plugins/Boltun/src/boltun.cpp b/plugins/Boltun/src/boltun.cpp index 9c44fccd4a..5868bb3d0b 100644 --- a/plugins/Boltun/src/boltun.cpp +++ b/plugins/Boltun/src/boltun.cpp @@ -597,7 +597,7 @@ extern "C" int __declspec(dllexport) Load(void) CreateServiceFunction(SERV_CONTACT_NOT_TO_CHAT, ContactClickNotToChat);
CreateServiceFunction(SERV_CONTACT_START_CHATTING, ContactClickStartChatting);
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -50010002; //TODO: check the warning
mi.name.a = BOLTUN_AUTO_CHAT;
mi.pszService = SERV_CONTACT_AUTO_CHAT;
@@ -610,7 +610,7 @@ extern "C" int __declspec(dllexport) Load(void) mi.flags = CMIF_NOTOFFLINE;
mi.position = -50010000; //TODO: check the warning
- mi.icolibItem = LoadIcon(GetModuleHandle(NULL), MAKEINTRESOURCE(IDI_RECVMSG));
+ mi.hIcolibItem = LoadIcon(GetModuleHandle(NULL), MAKEINTRESOURCE(IDI_RECVMSG));
mi.name.a = BOLTUN_START_CHATTING;
mi.pszService = SERV_CONTACT_START_CHATTING;
hMenuItemStartChatting = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/BossKeyPlus/src/BossKey.cpp b/plugins/BossKeyPlus/src/BossKey.cpp index a30a429636..39f892024f 100644 --- a/plugins/BossKeyPlus/src/BossKey.cpp +++ b/plugins/BossKeyPlus/src/BossKey.cpp @@ -530,10 +530,10 @@ static int GenMenuInit(WPARAM, LPARAM) // Modify menu item text before to show t void BossKeyMenuItemInit(void) // Add menu item
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
mi.position = 2000100000;
- mi.icolibItem = IcoLib_GetIcon("hidemim");
+ mi.hIcolibItem = IcoLib_GetIcon("hidemim");
mi.name.t = LPGENT("Hide");
mi.pszService = MS_BOSSKEY_HIDE;
g_hMenuItem = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/BuddyExpectator/src/BuddyExpectator.cpp b/plugins/BuddyExpectator/src/BuddyExpectator.cpp index a05f1ff936..89d4c65dda 100644 --- a/plugins/BuddyExpectator/src/BuddyExpectator.cpp +++ b/plugins/BuddyExpectator/src/BuddyExpectator.cpp @@ -611,9 +611,9 @@ int ModulesLoaded(WPARAM, LPARAM) if (options.enableMissYou) {
HookEvent(ME_CLIST_PREBUILDCONTACTMENU, onPrebuildContactMenu);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.icolibItem = iconList[2].hIcolib;
+ mi.hIcolibItem = iconList[2].hIcolib;
mi.position = 200000;
mi.name.t = LPGENT("Enable Miss You");
mi.pszService = "BuddyExpectator/actionMissYouClick";
diff --git a/plugins/BuddyPounce/src/main.cpp b/plugins/BuddyPounce/src/main.cpp index a8d2dc419a..4178be4dc9 100644 --- a/plugins/BuddyPounce/src/main.cpp +++ b/plugins/BuddyPounce/src/main.cpp @@ -43,9 +43,9 @@ extern "C" __declspec(dllexport) PLUGININFOEX* MirandaPluginInfoEx(DWORD) int MainInit(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 10;
- mi.icolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_POUNCE));
+ mi.hIcolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_POUNCE));
mi.name.a = LPGEN("&Buddy Pounce");
mi.pszService = "BuddyPounce/MenuCommand";
Menu_AddContactMenuItem(&mi);
diff --git a/plugins/CSList/src/cslist.cpp b/plugins/CSList/src/cslist.cpp index db3383d326..342bdb9c09 100644 --- a/plugins/CSList/src/cslist.cpp +++ b/plugins/CSList/src/cslist.cpp @@ -238,13 +238,13 @@ void addProtoStatusMenuItem(char *protoName) if (!ServiceExists(buf)) CreateServiceFunctionParam(buf, showList, (LPARAM)protoName); - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.flags = CMIF_TCHAR; - mi.icolibItem = forms[0].hIcoLibItem; + mi.hIcolibItem = forms[0].hIcoLibItem; mi.name.t = _T(MODULENAME); mi.position = 2000040000; mi.pszService = buf; - mi.hParentMenu = hRoot; + mi.root = hRoot; Menu_AddStatusMenuItem(&mi); RegisterHotkeys(buf, pdescr->tszAccountName, pdescr->iOrder); diff --git a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp index eb57a282fe..1ba947c761 100644 --- a/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp +++ b/plugins/ClientChangeNotify/src/ClientChangeNotify.cpp @@ -327,8 +327,8 @@ int MirandaLoaded(WPARAM wParam, LPARAM lParam) CreateServiceFunction(MS_CCN_TOGGLEPOPUPS, srvTogglePopups);
HookEvent(ME_CLIST_PREBUILDMAINMENU, PrebuildMainMenu);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
mi.flags = CMIF_TCHAR;
if (g_PopupOptPage.GetDBValueCopy(IDC_POPUPOPTDLG_POPUPNOTIFY))
mi.name.t = LPGENT("Disable c&lient change notification");
diff --git a/plugins/Clist_modern/src/CLUIFrames/cluiframes.cpp b/plugins/Clist_modern/src/CLUIFrames/cluiframes.cpp index 24cf7b4f08..00c1caa893 100644 --- a/plugins/Clist_modern/src/CLUIFrames/cluiframes.cpp +++ b/plugins/Clist_modern/src/CLUIFrames/cluiframes.cpp @@ -751,7 +751,7 @@ static int CLUIFramesGetalClientFrame(void) /////////////////////////////////////////////////////////////////////////////////////////
-static HGENMENU addFrameMenuItem(CLISTMENUITEM *pmi, int frameid, bool bMain)
+static HGENMENU addFrameMenuItem(TMO_MenuItem *pmi, int frameid, bool bMain)
{
HGENMENU res = (bMain) ? Menu_AddMainMenuItem(pmi) : Menu_AddContextFrameMenuItem(pmi);
if (pmi->pszService != NULL)
@@ -767,8 +767,8 @@ static HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popupp int framepos = id2pos(frameid);
FrameMenuHandles &fmh = (frameid == -1) ? cont : g_pfwFrames[framepos].MenuHandles;
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = root;
+ TMO_MenuItem mi = { 0 };
+ mi.root = root;
mi.position = popuppos++;
mi.name.a = LPGEN("&Visible");
mi.flags = CMIF_CHECKED;
@@ -815,7 +815,7 @@ static HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popupp fmh.MIAlignRoot = addFrameMenuItem(&mi, frameid, bMain);
// align top
- mi.hParentMenu = fmh.MIAlignRoot;
+ mi.root = fmh.MIAlignRoot;
mi.position = popuppos++;
mi.name.a = LPGEN("&Top");
mi.pszService = CLUIFRAMESSETALIGNALTOP;
@@ -834,11 +834,11 @@ static HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popupp fmh.MIAlignBottom = addFrameMenuItem(&mi, frameid, bMain);
// position root
- mi.hParentMenu = root;
+ mi.root = root;
mi.position = popuppos++;
mi.name.a = LPGEN("&Position");
mi.pszService = NULL;
- mi.hParentMenu = addFrameMenuItem(&mi, frameid, bMain);
+ mi.root = addFrameMenuItem(&mi, frameid, bMain);
mi.position = popuppos++;
mi.name.a = LPGEN("&Up");
@@ -1487,17 +1487,17 @@ static int CLUIFramesLoadMainMenu() }
// create root menu
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_FRAME);
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_FRAME);
mi.position = 3000090000;
mi.name.a = LPGEN("Frames");
cont.MainMenuItem = Menu_AddMainMenuItem(&mi);
// create frames menu
- mi.hParentMenu = cont.MainMenuItem;
+ mi.root = cont.MainMenuItem;
int separator = 3000200000;
for (int i = 0; i < g_nFramesCount; i++) {
- mi.icolibItem = g_pfwFrames[i].TitleBar.hicon;
+ mi.hIcolibItem = g_pfwFrames[i].TitleBar.hicon;
mi.flags = CMIF_TCHAR;
mi.position = separator++;
mi.name.t = g_pfwFrames[i].TitleBar.tbname ? g_pfwFrames[i].TitleBar.tbname : g_pfwFrames[i].name;
@@ -1511,7 +1511,7 @@ static int CLUIFramesLoadMainMenu() separator += 100000;
// create "show all frames" menu
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.flags = 0;
mi.position = separator++;
mi.name.a = LPGEN("Show all frames");
diff --git a/plugins/Clist_modern/src/CLUIFrames/groupmenu.cpp b/plugins/Clist_modern/src/CLUIFrames/groupmenu.cpp index 1af388347a..163d920fcd 100644 --- a/plugins/Clist_modern/src/CLUIFrames/groupmenu.cpp +++ b/plugins/Clist_modern/src/CLUIFrames/groupmenu.cpp @@ -62,29 +62,26 @@ INT_PTR BuildGroupMenu(WPARAM, LPARAM) static INT_PTR AddGroupMenuItem(WPARAM wParam, LPARAM lParam)
{
- TMO_MenuItem tmi;
- CLISTMENUITEM *mi = (CLISTMENUITEM *)lParam;
- if (!pcli->pfnConvertMenu(mi, &tmi))
- return NULL;
-
lpGroupMenuExecParam mmep = (lpGroupMenuExecParam)mir_calloc(sizeof(GroupMenuExecParam));
if (mmep == NULL)
return 0;
- //we need just one parametr.
- mmep->szServiceName = mir_strdup(mi->pszService);
+ TMO_MenuItem *pmi = (TMO_MenuItem*)lParam;
+
+ // we need just one parametr.
+ mmep->szServiceName = mir_strdup(pmi->pszService);
mmep->Param1 = 0; // mi->popupPosition; !!!!!!!!!!!!!!!!!!
lpGroupMenuParam gmp = (lpGroupMenuParam)wParam;
if (gmp != NULL) {
mmep->Param1 = gmp->wParam;
mmep->Param2 = gmp->lParam;
}
- tmi.ownerdata = mmep;
+ pmi->ownerdata = mmep;
- HGENMENU hNewItem = Menu_AddItem(hGroupMenuObject, &tmi);
+ HGENMENU hNewItem = Menu_AddItem(hGroupMenuObject, pmi);
char buf[1024];
- mir_snprintf(buf, "%s/%s", mi->pszService, mi->name.a);
+ mir_snprintf(buf, "%s/%s", pmi->pszService, pmi->name.a);
Menu_ConfigureItem(hNewItem, MCI_OPT_UNIQUENAME, buf);
return (INT_PTR)hNewItem;
}
@@ -225,45 +222,45 @@ void InitGroupMenus(void) Menu_ConfigureObject(hGroupMenuObject, MCO_OPT_ONADD_SERVICE, "CLISTMENUSGroup/GroupMenuonAddService");
// add exit command to menu
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1900000;
mi.pszService = "CloseAction";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
mi.name.a = LPGEN("E&xit");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 500;
mi.pszService = MS_CLIST_SHOWHIDE;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_SHOWHIDE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_SHOWHIDE);
mi.name.a = LPGEN("&Hide/show");
hHideShowMainMenuItem = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 200000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER);
mi.pszService = "FindAdd/FindAddCommand";
mi.name.a = LPGEN("&Find/add contacts...");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 300000;
mi.pszService = "";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MAINMENU);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MAINMENU);
mi.name.a = LPGEN("&Main menu");
hGroupMainMenuItemProxy = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 300100;
mi.pszService = "";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_STATUS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_STATUS);
mi.name.a = LPGEN("&Status");
hGroupStatusMenuItemProxy = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 400000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
mi.pszService = "Options/OptionsCommand";
mi.name.a = LPGEN("&Options...");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 500000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
mi.pszService = "Help/AboutCommand";
mi.name.a = LPGEN("&About");
AddGroupMenuItem(0, (LPARAM)&mi);
@@ -271,15 +268,15 @@ void InitGroupMenus(void) GroupMenuParam gmp = {};
mi.flags = 0;
mi.position = 100000;
- mi.icolibItem = iconItem[0].hIcolib;
+ mi.hIcolibItem = iconItem[0].hIcolib;
mi.pszService = "CLISTMENUSGroup/CreateGroupHelper";
mi.name.a = LPGEN("&New group");
hNewGroupMenuItem = (HGENMENU)AddGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
- DestroyIcon_protect((HICON)mi.icolibItem);
+ DestroyIcon_protect((HICON)mi.hIcolibItem);
mi.position = 100001;
- mi.icolibItem = NULL;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = MS_CLIST_SETHIDEOFFLINE;
mi.name.a = LPGEN("&Hide offline users");
gmp.lParam = 0; gmp.wParam = -1;
@@ -362,29 +359,24 @@ HMENU cliBuildGroupPopupMenu(ClcGroup *group) static INT_PTR AddSubGroupMenuItem(WPARAM wParam, LPARAM lParam)
{
- TMO_MenuItem tmi;
- CLISTMENUITEM *mi = (CLISTMENUITEM*)lParam;
- if (!pcli->pfnConvertMenu(mi, &tmi))
- return NULL;
-
lpSubGroupMenuExecParam mmep = (lpSubGroupMenuExecParam)mir_calloc(sizeof(SubGroupMenuExecParam));
if (mmep == NULL)
return 0;
- //we need just one parametr.
- mmep->szServiceName = mir_strdup(mi->pszService);
- mmep->Param1 = 0; // mi->popupPosition; !!!!!!!!!!!!!!!!!!
+ TMO_MenuItem *pmi = (TMO_MenuItem*)lParam;
+ // we need just one parametr.
+ mmep->szServiceName = mir_strdup(pmi->pszService);
lpGroupMenuParam gmp = (lpGroupMenuParam)wParam;
if (gmp != NULL) {
mmep->Param1 = gmp->wParam;
mmep->Param2 = gmp->lParam;
}
- tmi.ownerdata = mmep;
+ pmi->ownerdata = mmep;
- HGENMENU hNewItem = Menu_AddItem(hSubGroupMenuObject, &tmi);
+ HGENMENU hNewItem = Menu_AddItem(hSubGroupMenuObject, pmi);
char buf[1024];
- mir_snprintf(buf, "%s/%s", mi->pszService, mi->name.a);
+ mir_snprintf(buf, "%s/%s", pmi->pszService, pmi->name.a);
Menu_ConfigureItem(hNewItem, MCI_OPT_UNIQUENAME, buf);
return (INT_PTR)hNewItem;
}
@@ -468,9 +460,9 @@ void InitSubGroupMenus(void) // add exit command to menu
GroupMenuParam gmp;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000;
- mi.icolibItem = iconItem[0].hIcolib;
+ mi.hIcolibItem = iconItem[0].hIcolib;
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&New subgroup");
gmp.lParam = 0;
@@ -478,8 +470,8 @@ void InitSubGroupMenus(void) hNewSubGroupMenuItem = (HGENMENU)AddSubGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
mi.position = 1001;
- mi.icolibItem = NULL;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Hide offline users in here");
gmp.lParam = 0;
@@ -487,7 +479,7 @@ void InitSubGroupMenus(void) hHideOfflineUsersHereMenuItem = (HGENMENU)AddSubGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
mi.position = 1002;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Show offline users in here");
gmp.lParam = 0;
@@ -496,7 +488,7 @@ void InitSubGroupMenus(void) memset(&mi, 0, sizeof(mi));
mi.position = 900001;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_RENAME);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_RENAME);
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Rename group");
gmp.lParam = 0;
@@ -504,7 +496,7 @@ void InitSubGroupMenus(void) AddSubGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
mi.position = 900002;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Delete group");
gmp.lParam = 0;
diff --git a/plugins/Clist_modern/src/modern_clistmenus.cpp b/plugins/Clist_modern/src/modern_clistmenus.cpp index b31af23f27..90850f414b 100644 --- a/plugins/Clist_modern/src/modern_clistmenus.cpp +++ b/plugins/Clist_modern/src/modern_clistmenus.cpp @@ -99,8 +99,8 @@ static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM) BOOL bModifyMenu = FALSE;
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = iconList[bContactRate].hIcolib;
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = iconList[bContactRate].hIcolib;
mi.flags = CMIF_TCHAR;
if (!bContactRate)
mi.name.t = FAVMENUROOTNAME;
@@ -121,7 +121,7 @@ static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM) Menu_ConfigureItem(hFavoriteContactMenu, MCI_OPT_UNIQUENAME, "ModernClistMenu_ContactRate");
- mi.hParentMenu = hFavoriteContactMenu;
+ mi.root = hFavoriteContactMenu;
if (!hFavoriteContactMenuItems) {
hFavoriteContactMenuItems = (HGENMENU *)malloc(sizeof(HANDLE) * _countof(rates));
memset(hFavoriteContactMenuItems, 0, sizeof(HANDLE) * _countof(rates));
@@ -133,7 +133,7 @@ static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM) if (bModifyMenu && hFavoriteContactMenuItems[i])
Menu_ModifyItem(hFavoriteContactMenuItems[i], NULL, iconList[i].hIcolib, mi.flags);
else {
- mi.icolibItem = iconList[i].hIcolib;
+ mi.hIcolibItem = iconList[i].hIcolib;
mi.name.t = rates[i];
mi.pszService = CLUI_FAVSETRATE;
hFavoriteContactMenuItems[i] = Menu_AddContactMenuItem(&mi);
@@ -141,7 +141,7 @@ static int FAV_OnContactMenuBuild(WPARAM hContact, LPARAM) }
}
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.flags = CMIF_TCHAR | (db_get_b(hContact, "CList", "noOffline", 0) ? CMIF_CHECKED : 0);
if (bModifyMenu && hShowIfOflineItem)
Menu_ModifyItem(hShowIfOflineItem, NULL, INVALID_HANDLE_VALUE, mi.flags);
diff --git a/plugins/Clist_modern/src/modern_clisttray.cpp b/plugins/Clist_modern/src/modern_clisttray.cpp index 5dfb00c715..f66e4c2456 100644 --- a/plugins/Clist_modern/src/modern_clisttray.cpp +++ b/plugins/Clist_modern/src/modern_clisttray.cpp @@ -170,16 +170,11 @@ static INT_PTR BuildTrayMenu(WPARAM, LPARAM) static INT_PTR AddTrayMenuItem(WPARAM, LPARAM lParam)
{
- CLISTMENUITEM *mi = (CLISTMENUITEM*)lParam;
+ TMO_MenuItem *pmi = (TMO_MenuItem*)lParam;
+ pmi->ownerdata = mir_strdup(pmi->pszService);
- TMO_MenuItem tmi;
- if (!pcli->pfnConvertMenu(mi, &tmi))
- return NULL;
-
- tmi.ownerdata = mir_strdup(mi->pszService);
-
- HGENMENU hNewItem = Menu_AddItem(hTrayMenuObject, &tmi);
- Menu_ConfigureItem(hNewItem, MCI_OPT_UNIQUENAME, mi->pszService);
+ HGENMENU hNewItem = Menu_AddItem(hTrayMenuObject, pmi);
+ Menu_ConfigureItem(hNewItem, MCI_OPT_UNIQUENAME, pmi->pszService);
return (INT_PTR)hNewItem;
}
@@ -314,45 +309,45 @@ void InitTrayMenus(void) Menu_ConfigureObject(hTrayMenuObject, MCO_OPT_ONADD_SERVICE, "CLISTMENUSTRAY/TrayMenuonAddService");
// add exit command to menu
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 900000;
mi.pszService = "CloseAction";
mi.name.a = LPGEN("E&xit");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
Menu_AddTrayMenuItem(&mi);
mi.position = 100000;
mi.pszService = MS_CLIST_SHOWHIDE;
mi.name.a = LPGEN("&Hide/show");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_SHOWHIDE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_SHOWHIDE);
hTrayHideShowMainMenuItem = Menu_AddTrayMenuItem(&mi);
mi.position = 200000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER);
mi.pszService = "FindAdd/FindAddCommand";
mi.name.a = LPGEN("&Find/add contacts...");
Menu_AddTrayMenuItem(&mi);
mi.position = 300000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MAINMENU); // eternity #004
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MAINMENU); // eternity #004
mi.pszService = "FakeService_1";
mi.name.a = LPGEN("&Main menu");
hTrayMainMenuItemProxy = Menu_AddTrayMenuItem(&mi);
mi.position = 300100;
mi.pszService = "FakeService_2";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_STATUS); // eternity #004
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_STATUS); // eternity #004
mi.name.a = LPGEN("&Status");
hTrayStatusMenuItemProxy = Menu_AddTrayMenuItem(&mi);
mi.position = 400000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
mi.pszService = "Options/OptionsCommand";
mi.name.a = LPGEN("&Options...");
Menu_AddTrayMenuItem(&mi);
mi.position = 500000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
mi.pszService = "Help/AboutCommand";
mi.name.a = LPGEN("&About");
Menu_AddTrayMenuItem(&mi);
diff --git a/plugins/Clist_modern/src/modern_clui.cpp b/plugins/Clist_modern/src/modern_clui.cpp index d4851203ce..0c02b4fb12 100644 --- a/plugins/Clist_modern/src/modern_clui.cpp +++ b/plugins/Clist_modern/src/modern_clui.cpp @@ -335,17 +335,17 @@ HRESULT CLUI::RegisterAvatarMenu() {
Icon_RegisterT(g_hInst, LPGENT("Contact list"), iconItem, _countof(iconItem));
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
CreateServiceFunction("CList/ShowContactAvatar", CLUI::Service_Menu_ShowContactAvatar);
mi.position = 2000150000;
- mi.icolibItem = iconItem[0].hIcolib;
+ mi.hIcolibItem = iconItem[0].hIcolib;
mi.name.a = LPGEN("Show contact &avatar");
mi.pszService = "CList/ShowContactAvatar";
hShowAvatarMenuItem = Menu_AddContactMenuItem(&mi);
CreateServiceFunction("CList/HideContactAvatar", CLUI::Service_Menu_HideContactAvatar);
mi.position = 2000150001;
- mi.icolibItem = iconItem[1].hIcolib;
+ mi.hIcolibItem = iconItem[1].hIcolib;
mi.name.a = LPGEN("Hide contact &avatar");
mi.pszService = "CList/HideContactAvatar";
hHideAvatarMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/Clist_nicer/src/CLUIFrames/cluiframes.cpp b/plugins/Clist_nicer/src/CLUIFrames/cluiframes.cpp index d22724ac95..d8b1a8c031 100644 --- a/plugins/Clist_nicer/src/CLUIFrames/cluiframes.cpp +++ b/plugins/Clist_nicer/src/CLUIFrames/cluiframes.cpp @@ -566,7 +566,7 @@ int CLUIFramesGetalClientFrame(void) ///////////////////////////////////////////////////////////////////////////////////////// -static HGENMENU addFrameMenuItem(CLISTMENUITEM *pmi, int frameid, bool bMain) +static HGENMENU addFrameMenuItem(TMO_MenuItem *pmi, int frameid, bool bMain) { HGENMENU res = (bMain) ? Menu_AddMainMenuItem(pmi) : Menu_AddContextFrameMenuItem(pmi); if (pmi->pszService != NULL) @@ -582,9 +582,9 @@ HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popuppos, boo int framepos = id2pos(frameid); FrameMenuHandles &fmh = (frameid == -1) ? cont : Frames[framepos].MenuHandles; - CLISTMENUITEM mi = { 0 }; - mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA); - mi.hParentMenu = root; + TMO_MenuItem mi = { 0 }; + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA); + mi.root = root; mi.position = popuppos++; mi.name.a = LPGEN("&FrameTitle"); mi.flags = CMIF_GRAYED; @@ -592,7 +592,7 @@ HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popuppos, boo popuppos += 100000; - mi.icolibItem = NULL; + mi.hIcolibItem = NULL; mi.position = popuppos++; mi.name.a = LPGEN("&Visible"); mi.flags = CMIF_CHECKED; @@ -645,7 +645,7 @@ HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popuppos, boo popuppos += 100000; // alignment root - mi.hParentMenu = root; + mi.root = root; mi.position = popuppos++; mi.name.a = LPGEN("&Align"); mi.flags = 0; @@ -653,7 +653,7 @@ HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popuppos, boo fmh.MIAlignRoot = addFrameMenuItem(&mi, frameid, bMain); // align top - mi.hParentMenu = fmh.MIAlignRoot; + mi.root = fmh.MIAlignRoot; mi.position = popuppos++; mi.name.a = LPGEN("&Top"); mi.pszService = CLUIFRAMESSETALIGNALTOP; @@ -672,11 +672,11 @@ HMENU CLUIFramesCreateMenuForFrame(int frameid, HGENMENU root, int popuppos, boo fmh.MIAlignBottom = addFrameMenuItem(&mi, frameid, bMain); // position root - mi.hParentMenu = root; + mi.root = root; mi.position = popuppos++; mi.name.a = LPGEN("&Position"); mi.pszService = NULL; - mi.hParentMenu = addFrameMenuItem(&mi, frameid, bMain); + mi.root = addFrameMenuItem(&mi, frameid, bMain); mi.position = popuppos++; mi.name.a = LPGEN("&Up"); @@ -1338,18 +1338,18 @@ static int CLUIFramesLoadMainMenu() } // create root menu - CLISTMENUITEM mi = { 0 }; - mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_FRAME); + TMO_MenuItem mi = { 0 }; + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_FRAME); mi.position = 3000090000; mi.name.a = LPGEN("Frames"); mi.pszService = 0; cont.MainMenuItem = Menu_AddMainMenuItem(&mi); // create frames menu - mi.hParentMenu = cont.MainMenuItem; + mi.root = cont.MainMenuItem; int separator = (int)3000200000; for (int i = 0; i < nFramescount; i++) { - mi.icolibItem = Frames[i].TitleBar.hicon; + mi.hIcolibItem = Frames[i].TitleBar.hicon; mi.flags = CMIF_TCHAR; mi.position = separator; mi.name.t = Frames[i].TitleBar.tbname ? Frames[i].TitleBar.tbname : Frames[i].name; @@ -1364,7 +1364,7 @@ static int CLUIFramesLoadMainMenu() separator += 100000; // create "show all frames" menu - mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA); + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA); mi.flags = 0; mi.position = separator++; mi.name.a = LPGEN("Show all frames"); @@ -1372,7 +1372,7 @@ static int CLUIFramesLoadMainMenu() Menu_AddMainMenuItem(&mi); // create "show all titlebars" menu - mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_HELP); + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_HELP); mi.position = separator++; mi.name.a = LPGEN("Show all title bars"); mi.pszService = MS_CLIST_FRAMES_SHOWALLFRAMESTB; diff --git a/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp b/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp index fd96059baf..137fe1b888 100644 --- a/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp +++ b/plugins/Clist_nicer/src/CLUIFrames/groupmenu.cpp @@ -64,29 +64,24 @@ static INT_PTR BuildGroupMenu(WPARAM, LPARAM) static INT_PTR AddGroupMenuItem(WPARAM wParam, LPARAM lParam)
{
- TMO_MenuItem tmi;
- CLISTMENUITEM *mi = (CLISTMENUITEM *)lParam;
- if (!pcli->pfnConvertMenu(mi, &tmi))
- return NULL;
-
lpGroupMenuExecParam mmep = (lpGroupMenuExecParam)mir_calloc(sizeof(GroupMenuExecParam));
if (mmep == NULL)
return 0;
- //we need just one parametr.
- mmep->szServiceName = mir_strdup(mi->pszService);
- mmep->Param1 = 0; // mi->popupPosition; !!!!!!!!!!!!!!!!!!
+ TMO_MenuItem *pmi = (TMO_MenuItem*)lParam;
+ // we need just one parametr.
+ mmep->szServiceName = mir_strdup(pmi->pszService);
lpGroupMenuParam gmp = (lpGroupMenuParam)wParam;
if (gmp != NULL) {
mmep->Param1 = gmp->wParam;
mmep->Param2 = gmp->lParam;
}
- tmi.ownerdata = mmep;
+ pmi->ownerdata = mmep;
- HGENMENU hNewItem = Menu_AddItem(hGroupMenuObject, &tmi);
+ HGENMENU hNewItem = Menu_AddItem(hGroupMenuObject, pmi);
char buf[1024];
- mir_snprintf(buf, "%s/%s", mi->pszService, mi->name.a);
+ mir_snprintf(buf, "%s/%s", pmi->pszService, pmi->name.a);
Menu_ConfigureItem(hNewItem, MCI_OPT_UNIQUENAME, buf);
return (INT_PTR)hNewItem;
}
@@ -232,64 +227,64 @@ void InitGroupMenus(void) // add exit command to menu
GroupMenuParam gmp;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1900000;
mi.pszService = "CloseAction";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
mi.name.a = LPGEN("E&xit");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 500;
mi.pszService = MS_CLIST_SHOWHIDE;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_SHOWHIDE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_SHOWHIDE);
mi.name.a = LPGEN("&Hide/show");
hHideShowMainMenuItem = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 200000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER);
mi.pszService = "FindAdd/FindAddCommand";
mi.name.a = LPGEN("&Find/add contacts...");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 300000;
mi.pszService = "";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MAINMENU);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MAINMENU);
mi.name.a = LPGEN("&Main menu");
hGroupMainMenuItemProxy = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 300100;
mi.pszService = "";
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_STATUS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_STATUS);
mi.name.a = LPGEN("&Status");
hGroupStatusMenuItemProxy = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 390100;
- mi.icolibItem = iconItem[1].hIcolib;
+ mi.hIcolibItem = iconItem[1].hIcolib;
mi.name.a = LPGEN("Appearance");
hAppearanceMenuItemProxy = (HGENMENU)AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 400000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
mi.pszService = "Options/OptionsCommand";
mi.name.a = LPGEN("&Options...");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.position = 500000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
mi.pszService = "CLN/About";
mi.name.a = LPGEN("&About the contact list...");
AddGroupMenuItem(0, (LPARAM)&mi);
mi.flags = 0;
mi.position = 100000;
- mi.icolibItem = iconItem[0].hIcolib;
+ mi.hIcolibItem = iconItem[0].hIcolib;
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&New group");
hNewGroupMenuItem = (HGENMENU)AddGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
mi.position = 100001;
- mi.icolibItem = NULL;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = MS_CLIST_SETHIDEOFFLINE;
mi.name.a = LPGEN("&Hide offline users");
gmp.lParam = 0; gmp.wParam = -1;
@@ -331,7 +326,7 @@ SubGroupMenuExecParam, *lpSubGroupMenuExecParam; static int OnBuildSubGroupMenu(WPARAM wParam, LPARAM)
{
- ClcGroup *group = (ClcGroup *)wParam;
+ ClcGroup *group = (ClcGroup*)wParam;
if (group != 0) // contact->group
Menu_ModifyItem(hHideOfflineUsersHereMenuItem, NULL, INVALID_HANDLE_VALUE, group->hideOffline ? CMIF_CHECKED : 0);
return 0;
@@ -348,28 +343,24 @@ static INT_PTR BuildSubGroupMenu(WPARAM wParam, LPARAM) static INT_PTR AddSubGroupMenuItem(WPARAM wParam, LPARAM lParam)
{
- TMO_MenuItem tmi;
- CLISTMENUITEM *mi = (CLISTMENUITEM *)lParam;
- if (!pcli->pfnConvertMenu(mi, &tmi))
- return NULL;
-
lpSubGroupMenuExecParam mmep = (lpSubGroupMenuExecParam)mir_alloc(sizeof(SubGroupMenuExecParam));
if (mmep == NULL)
return 0;
- //we need just one parametr.
+ TMO_MenuItem *pmi = (TMO_MenuItem*)lParam;
+
+ // we need just one parametr.
lpGroupMenuParam gmp = (lpGroupMenuParam)wParam;
- mmep->szServiceName = mir_strdup(mi->pszService);
- mmep->Param1 = 0; // mi->popupPosition; !!!!!!!!!!!!!!!!!!!!!!!!!
+ mmep->szServiceName = mir_strdup(pmi->pszService);
if (gmp != NULL) {
mmep->Param1 = gmp->wParam;
mmep->Param2 = gmp->lParam;
}
- tmi.ownerdata = mmep;
- HGENMENU hNewItem = Menu_AddItem(hSubGroupMenuObject, &tmi);
+ pmi->ownerdata = mmep;
+ HGENMENU hNewItem = Menu_AddItem(hSubGroupMenuObject, pmi);
char buf[1024];
- mir_snprintf(buf, "%s/%s", mi->pszService, mi->name.a);
+ mir_snprintf(buf, "%s/%s", pmi->pszService, pmi->name.a);
Menu_ConfigureItem(hNewItem, MCI_OPT_UNIQUENAME, buf);
return (INT_PTR)hNewItem;
}
@@ -460,9 +451,9 @@ void InitSubGroupMenus(void) // add exit command to menu
GroupMenuParam gmp;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000;
- mi.icolibItem = iconItem[0].hIcolib;
+ mi.hIcolibItem = iconItem[0].hIcolib;
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&New subgroup");
gmp.lParam = 0;
@@ -470,8 +461,8 @@ void InitSubGroupMenus(void) hNewSubGroupMenuItem = (HGENMENU)AddSubGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
mi.position = 1001;
- mi.icolibItem = NULL;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Hide offline users in here");
gmp.lParam = 0;
@@ -480,7 +471,7 @@ void InitSubGroupMenus(void) memset(&mi, 0, sizeof(mi));
mi.position = 900001;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_RENAME);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_RENAME);
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Rename group");
gmp.lParam = 0;
@@ -488,7 +479,7 @@ void InitSubGroupMenus(void) AddSubGroupMenuItem((WPARAM)&gmp, (LPARAM)&mi);
mi.position = 900002;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
mi.pszService = "CLISTMENUSSubGroup/GroupMenuExecProxy";
mi.name.a = LPGEN("&Delete group");
gmp.lParam = 0;
diff --git a/plugins/Clist_nicer/src/clistmenus.cpp b/plugins/Clist_nicer/src/clistmenus.cpp index b82d0f7e5d..458f460bc0 100644 --- a/plugins/Clist_nicer/src/clistmenus.cpp +++ b/plugins/Clist_nicer/src/clistmenus.cpp @@ -381,10 +381,10 @@ int InitCustomMenus(void) CreateServiceFunction("CloseAction", CloseAction);
CreateServiceFunction("CList/SetContactIgnore", SetContactIgnore);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 200000;
mi.pszService = "CList/SetContactIgnore";
- mi.icolibItem = iconItem[1].hIcolib;
+ mi.hIcolibItem = iconItem[1].hIcolib;
mi.name.a = LPGEN("&Contact list settings...");
Menu_AddContactMenuItem(&mi);
diff --git a/plugins/Console/src/Console.cpp b/plugins/Console/src/Console.cpp index 8ce00a8cb6..d6493662f7 100644 --- a/plugins/Console/src/Console.cpp +++ b/plugins/Console/src/Console.cpp @@ -1159,9 +1159,9 @@ static int OnSystemModulesLoaded(WPARAM, LPARAM) if (hwndConsole && IsWindow(hwndConsole)) {
HookEvent(ME_TTB_MODULELOADED, OnTTBLoaded);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.icolibItem = hIcons[0];
+ mi.hIcolibItem = hIcons[0];
mi.position = 1900000000;
mi.name.t = (IsWindowVisible(hwndConsole)) ? LPGENT("Hide Console") : LPGENT("Show Console");
mi.pszService = MS_CONSOLE_SHOW_HIDE;
diff --git a/plugins/ContactsPlus/src/main.cpp b/plugins/ContactsPlus/src/main.cpp index a4dc6ff656..5e6ea3876d 100644 --- a/plugins/ContactsPlus/src/main.cpp +++ b/plugins/ContactsPlus/src/main.cpp @@ -135,11 +135,11 @@ static int HookModulesLoaded(WPARAM, LPARAM) modules[0] = MODULENAME;
CallService("DBEditorpp/RegisterModule", (WPARAM)modules, 1);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.a = LPGEN("Contacts");
mi.position = -2000009990; //position in menu
mi.pszService = MS_CONTACTS_SEND;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_CONTACTS));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_CONTACTS));
hContactMenuItem = Menu_AddContactMenuItem(&mi);
HookEvent(ME_CLIST_PREBUILDCONTACTMENU, HookPreBuildContactMenu);
diff --git a/plugins/CrashDumper/src/crshdmp.cpp b/plugins/CrashDumper/src/crshdmp.cpp index dbe47847c9..178a79af61 100644 --- a/plugins/CrashDumper/src/crshdmp.cpp +++ b/plugins/CrashDumper/src/crshdmp.cpp @@ -255,56 +255,56 @@ static int ModulesLoaded(WPARAM, LPARAM) FoldersPathChanged(0, 0);
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Version Information"), 2000089999, GetIconHandle(IDI_VI));
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Version Information"), 2000089999, GetIconHandle(IDI_VI));
mi.position = 2000089995;
mi.name.a = LPGEN("Copy to clipboard");
- mi.icolibItem = GetIconHandle(IDI_VITOCLIP);
+ mi.hIcolibItem = GetIconHandle(IDI_VITOCLIP);
mi.pszService = MS_CRASHDUMPER_STORETOCLIP;
Menu_AddMainMenuItem(&mi);
mi.position = 2000089996;
mi.name.a = LPGEN("Store to file");
- mi.icolibItem = GetIconHandle(IDI_VITOFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_VITOFILE);
mi.pszService = MS_CRASHDUMPER_STORETOFILE;
Menu_AddMainMenuItem(&mi);
mi.position = 2000089997;
mi.name.a = LPGEN("Show");
- mi.icolibItem = GetIconHandle(IDI_VISHOW);
+ mi.hIcolibItem = GetIconHandle(IDI_VISHOW);
mi.pszService = MS_CRASHDUMPER_VIEWINFO;
Menu_AddMainMenuItem(&mi);
mi.position = 2000089998;
mi.name.a = LPGEN("Show with DLLs");
- mi.icolibItem = GetIconHandle(IDI_VIUPLOAD);
+ mi.hIcolibItem = GetIconHandle(IDI_VIUPLOAD);
mi.pszService = MS_CRASHDUMPER_VIEWINFO;
Menu_ConfigureItem(Menu_AddMainMenuItem(&mi), MCI_OPT_EXECPARAM, 1);
mi.position = 2000089999;
mi.name.a = LPGEN("Upload");
- mi.icolibItem = GetIconHandle(IDI_VIUPLOAD);
+ mi.hIcolibItem = GetIconHandle(IDI_VIUPLOAD);
mi.pszService = MS_CRASHDUMPER_UPLOAD;
Menu_AddMainMenuItem(&mi);
mi.position = 2000089999;
mi.name.a = LPGEN("Copy link to clipboard");
- mi.icolibItem = GetIconHandle(IDI_LINKTOCLIP);//need icon
+ mi.hIcolibItem = GetIconHandle(IDI_LINKTOCLIP);//need icon
mi.pszService = MS_CRASHDUMPER_URLTOCLIP;
Menu_AddMainMenuItem(&mi);
if (catchcrashes && !needrestart) {
mi.position = 2000099990;
mi.name.a = LPGEN("Open crash report directory");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_FILE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_FILE);
mi.pszService = MS_CRASHDUMPER_URL;
Menu_AddMainMenuItem(&mi);
}
mi.position = 2000099991;
mi.name.a = LPGEN("Open online Version Info");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
mi.pszService = MS_CRASHDUMPER_URL;
Menu_ConfigureItem(Menu_AddMainMenuItem(&mi), MCI_OPT_EXECPARAM, 1);
diff --git a/plugins/CyrTranslit/src/MirandaContact.cpp b/plugins/CyrTranslit/src/MirandaContact.cpp index c517ac12bc..0b5d76a1de 100644 --- a/plugins/CyrTranslit/src/MirandaContact.cpp +++ b/plugins/CyrTranslit/src/MirandaContact.cpp @@ -63,7 +63,7 @@ void MirandaContact::save(MCONTACT hContact, bool bValue) void MirandaContact::addMenuItem()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.a = MENU_ITEM_TEXT;
mi.position = 65535;
mi.pszService = MENU_COMMAND_CALLBACK_SERVICE;
diff --git a/plugins/Db3x_mmap/src/ui.cpp b/plugins/Db3x_mmap/src/ui.cpp index 8a385b21f5..9a89d770e0 100644 --- a/plugins/Db3x_mmap/src/ui.cpp +++ b/plugins/Db3x_mmap/src/ui.cpp @@ -311,16 +311,16 @@ static int OnModulesLoaded(PVOID obj, WPARAM, LPARAM) HookEventObj(ME_OPT_INITIALISE, OnOptionsInit, db);
// main menu item
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = LPGENT("Database");
mi.position = 500000000;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
HGENMENU hMenuRoot = Menu_AddMainMenuItem(&mi);
- mi.icolibItem = iconList[1].hIcolib;
+ mi.hIcolibItem = iconList[1].hIcolib;
mi.name.t = db->GetMenuTitle();
- mi.hParentMenu = hMenuRoot;
+ mi.root = hMenuRoot;
mi.pszService = MS_DB_CHANGEPASSWORD;
hSetPwdMenu = Menu_AddMainMenuItem(&mi);
return 0;
diff --git a/plugins/DbEditorPP/src/main.cpp b/plugins/DbEditorPP/src/main.cpp index d38b38692e..32e9f17afc 100644 --- a/plugins/DbEditorPP/src/main.cpp +++ b/plugins/DbEditorPP/src/main.cpp @@ -113,17 +113,17 @@ int ModulesLoaded(WPARAM, LPARAM) IcoLibRegister();
// Register menu item
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Database"), 1900000001);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Database"), 1900000001);
mi.position = 1900000001;
- mi.icolibItem = GetIcoLibHandle(ICO_DBE_BUTT);
+ mi.hIcolibItem = GetIcoLibHandle(ICO_DBE_BUTT);
mi.name.a = modFullname;
mi.pszService = "DBEditorpp/MenuCommand";
Menu_AddMainMenuItem(&mi);
- mi.hParentMenu = NULL;
- mi.icolibItem = GetIcoLibHandle(ICO_REGUSER);
+ mi.root = NULL;
+ mi.hIcolibItem = GetIcoLibHandle(ICO_REGUSER);
mi.name.a = LPGEN("Open user tree in DBE++");
mi.pszService = "DBEditorpp/MenuCommand";
hUserMenu = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/Db_autobackups/src/main.cpp b/plugins/Db_autobackups/src/main.cpp index cc04428fa3..fc9443facd 100644 --- a/plugins/Db_autobackups/src/main.cpp +++ b/plugins/Db_autobackups/src/main.cpp @@ -99,18 +99,18 @@ int ModulesLoad(WPARAM, LPARAM) CreateServiceFunction(MS_AB_BACKUP, ABService);
CreateServiceFunction(MS_AB_SAVEAS, DBSaveAs);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Database"), 500100000);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Database"), 500100000);
mi.name.a = LPGEN("Backup profile");
mi.pszService = MS_AB_BACKUP;
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
mi.position = 500100000;
Menu_AddMainMenuItem(&mi);
mi.name.a = LPGEN("Save profile as...");
mi.pszService = MS_AB_SAVEAS;
- mi.icolibItem = iconList[1].hIcolib;
+ mi.hIcolibItem = iconList[1].hIcolib;
mi.position = 500100001;
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/Dropbox/src/dropbox_menus.cpp b/plugins/Dropbox/src/dropbox_menus.cpp index c1c57fbf1f..0a9326c4b2 100644 --- a/plugins/Dropbox/src/dropbox_menus.cpp +++ b/plugins/Dropbox/src/dropbox_menus.cpp @@ -15,11 +15,11 @@ INT_PTR CDropbox::SendFilesToDropboxCommand(void *obj, WPARAM hContact, LPARAM) void CDropbox::InitializeMenus()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = MODULE"/SendFilesToDropbox";
mi.name.a = LPGEN("Upload files to Dropbox");
mi.position = -2000020000 + CMI_SEND_FILES;
- mi.icolibItem = GetIconHandleByName("upload");
+ mi.hIcolibItem = GetIconHandleByName("upload");
contactMenuItems[CMI_SEND_FILES] = Menu_AddContactMenuItem(&mi);
CreateServiceFunctionObj(mi.pszService, SendFilesToDropboxCommand, this);
}
diff --git a/plugins/Exchange/src/hooked_events.cpp b/plugins/Exchange/src/hooked_events.cpp index 7f6bd40295..b703411029 100644 --- a/plugins/Exchange/src/hooked_events.cpp +++ b/plugins/Exchange/src/hooked_events.cpp @@ -60,8 +60,8 @@ int OnModulesLoaded(WPARAM, LPARAM) {
UpdateTimers();
- CLISTMENUITEM mi = {0};
- mi.icolibItem = hiMailIcon;
+ TMO_MenuItem mi = {0};
+ mi.hIcolibItem = hiMailIcon;
mi.position = 10000000;
mi.pszService = MS_EXCHANGE_CHECKEMAIL;
mi.flags = CMIF_TCHAR;
diff --git a/plugins/FTPFileYM/src/ftpfile.cpp b/plugins/FTPFileYM/src/ftpfile.cpp index 90029b8159..8efff07d42 100644 --- a/plugins/FTPFileYM/src/ftpfile.cpp +++ b/plugins/FTPFileYM/src/ftpfile.cpp @@ -91,9 +91,9 @@ void InitMenuItems() {
TCHAR stzName[256];
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.icolibItem = iconList[ServerList::FTP_COUNT].hIcolib;
+ mi.hIcolibItem = iconList[ServerList::FTP_COUNT].hIcolib;
mi.position = 3000090001;
mi.name.t = LPGENT("FTP File");
@@ -104,7 +104,7 @@ void InitMenuItems() memset(&mi, 0, sizeof(mi));
mi.name.t = stzName;
- CLISTMENUITEM mi2 = { 0 };
+ TMO_MenuItem mi2 = { 0 };
mi2.flags = CMIF_TCHAR;
mi2.pszService = MS_FTPFILE_CONTACTMENU;
@@ -114,53 +114,53 @@ void InitMenuItems() mir_sntprintf(stzName, _countof(stzName), TranslateT("FTP Server %d"), i + 1);
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = (opt.bUseSubmenu) ? hMenu : 0;
+ mi.root = (opt.bUseSubmenu) ? hMenu : 0;
- mi.icolibItem = iconList[i].hIcolib;
+ mi.hIcolibItem = iconList[i].hIcolib;
hSubMenu[i] = Menu_AddContactMenuItem(&mi);
Menu_ConfigureItem(hSubMenu[i], MCI_OPT_EXECPARAM, i + 1000);
- mi.hParentMenu = hMainMenu;
+ mi.root = hMainMenu;
hMainSubMenu[i] = Menu_AddMainMenuItem(&mi);
- mi2.hParentMenu = hSubMenu[i];
+ mi2.root = hSubMenu[i];
mi2.pszService = MS_FTPFILE_CONTACTMENU;
mi2.name.t = LPGENT("Upload file(s)");
HGENMENU tmp = Menu_AddContactMenuItem(&mi2);
Menu_ConfigureItem(tmp, MCI_OPT_EXECPARAM, mi2.position = i + UploadJob::FTP_RAWFILE);
mi2.pszService = MS_FTPFILE_MAINMENU;
- mi2.hParentMenu = hMainSubMenu[i];
+ mi2.root = hMainSubMenu[i];
Menu_AddMainMenuItem(&mi2);
- mi2.hParentMenu = hSubMenu[i];
+ mi2.root = hSubMenu[i];
mi2.pszService = MS_FTPFILE_CONTACTMENU;
mi2.name.t = LPGENT("Zip and upload file(s)");
tmp = Menu_AddContactMenuItem(&mi2);
Menu_ConfigureItem(tmp, MCI_OPT_EXECPARAM, i + UploadJob::FTP_ZIPFILE);
mi2.pszService = MS_FTPFILE_MAINMENU;
- mi2.hParentMenu = hMainSubMenu[i];
+ mi2.root = hMainSubMenu[i];
Menu_AddMainMenuItem(&mi2);
- mi2.hParentMenu = hSubMenu[i];
+ mi2.root = hSubMenu[i];
mi2.pszService = MS_FTPFILE_CONTACTMENU;
mi2.name.t = LPGENT("Zip and upload folder");
tmp = Menu_AddContactMenuItem(&mi2);
Menu_ConfigureItem(tmp, MCI_OPT_EXECPARAM, i + UploadJob::FTP_ZIPFOLDER);
mi2.pszService = MS_FTPFILE_MAINMENU;
- mi2.hParentMenu = hMainSubMenu[i];
+ mi2.root = hMainSubMenu[i];
Menu_AddMainMenuItem(&mi2);
}
memset(&mi, 0, sizeof(mi));
mi.flags = CMIF_TCHAR;
- mi.icolibItem = iconList[ServerList::FTP_COUNT].hIcolib;
+ mi.hIcolibItem = iconList[ServerList::FTP_COUNT].hIcolib;
mi.position = 3000090001;
mi.name.t = LPGENT("FTP File manager");
mi.pszService = MS_FTPFILE_SHOWMANAGER;
- mi.hParentMenu = hMainMenu;
+ mi.root = hMainMenu;
Menu_AddMainMenuItem(&mi);
PrebuildMainMenu();
diff --git a/plugins/FileAsMessage/src/main.cpp b/plugins/FileAsMessage/src/main.cpp index cb0889af43..ba4e89ce5d 100644 --- a/plugins/FileAsMessage/src/main.cpp +++ b/plugins/FileAsMessage/src/main.cpp @@ -174,9 +174,9 @@ static int OnModulesLoaded(WPARAM wparam, LPARAM lparam) hHookSkinIconsChanged = HookEvent(ME_SKIN2_ICONSCHANGED, OnSkinIconsChanged);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 200011;
- mi.icolibItem = hIcons[ICON_MAIN];
+ mi.hIcolibItem = hIcons[ICON_MAIN];
mi.name.a = LPGEN("File As Message...");
mi.pszService = SERVICE_NAME "/FESendFile";
mi.flags = CMIF_NOTOFFLINE;
diff --git a/plugins/FloatingContacts/src/main.cpp b/plugins/FloatingContacts/src/main.cpp index aa450c50b7..fbb50fda32 100644 --- a/plugins/FloatingContacts/src/main.cpp +++ b/plugins/FloatingContacts/src/main.cpp @@ -716,10 +716,10 @@ static void LoadMenus() // Remove thumb menu item
CreateServiceFunction(MODULE "/RemoveThumb", OnContactMenu_Remove);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 0xFFFFF;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_HIDE));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_HIDE));
mi.name.t = LPGENT("Remove thumb");
mi.pszService = MODULE "/RemoveThumb";
hMenuItemRemove = Menu_AddContactMenuItem(&mi);
@@ -727,7 +727,7 @@ static void LoadMenus() // Hide all thumbs main menu item
CreateServiceFunction(MODULE "/MainHideAllThumbs", OnMainMenu_HideAll);
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(fcOpt.bHideAll ? IDI_SHOW : IDI_HIDE));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(fcOpt.bHideAll ? IDI_SHOW : IDI_HIDE));
mi.name.t = fcOpt.bHideAll ? LPGENT("Show all thumbs") : LPGENT("Hide all thumbs");
mi.pszService = MODULE "/MainHideAllThumbs";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/GmailNotifier/src/main.cpp b/plugins/GmailNotifier/src/main.cpp index ca9ce6a3b5..a88f53d9ac 100644 --- a/plugins/GmailNotifier/src/main.cpp +++ b/plugins/GmailNotifier/src/main.cpp @@ -134,10 +134,10 @@ extern "C" int __declspec(dllexport) Load() CreateServiceFunction(MODULE_NAME "/MenuCommand", PluginMenuCommand);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.flags = 0;
- mi.icolibItem = Skin_LoadProtoIcon(MODULE_NAME, ID_STATUS_ONLINE);
+ mi.hIcolibItem = Skin_LoadProtoIcon(MODULE_NAME, ID_STATUS_ONLINE);
mi.name.a = LPGEN("&Check all Gmail inboxes");
mi.pszService = MODULE_NAME "/MenuCommand";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/HTTPServer/src/GuiElements.cpp b/plugins/HTTPServer/src/GuiElements.cpp index 07049a8ec2..dfa4e02adb 100644 --- a/plugins/HTTPServer/src/GuiElements.cpp +++ b/plugins/HTTPServer/src/GuiElements.cpp @@ -1461,8 +1461,8 @@ void InitGuiElements() hShareNewFileService = CreateServiceFunction(MS_SHARE_NEW_FILE, nShareNewFile);
hShowStatisticsViewService = CreateServiceFunction(MS_SHOW_STATISTICS_VIEW, nShowStatisticsView);
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_SHARE_NEW_FILE));
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_SHARE_NEW_FILE));
mi.position = -2000019955;
mi.name.t = LPGENT("HTTP Share new file");
mi.pszService = MS_SHARE_NEW_FILE;
diff --git a/plugins/HTTPServer/src/main.cpp b/plugins/HTTPServer/src/main.cpp index 87724d69ab..2d6d70b2c1 100644 --- a/plugins/HTTPServer/src/main.cpp +++ b/plugins/HTTPServer/src/main.cpp @@ -921,9 +921,9 @@ extern "C" __declspec(dllexport) int Load() indexCreationMode = (eIndexCreationMode) db_get_b(NULL, MODULE, "IndexCreationMode", 2);
if (db_get_b(NULL, MODULE, "AddAcceptConMenuItem", 1)) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.icolibItem = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_SHARE_NEW_FILE));
+ mi.hIcolibItem = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_SHARE_NEW_FILE));
mi.position = 1000085000;
mi.name.a = LPGENT("Enable HTTP server");
mi.pszService = MS_HTTP_ACCEPT_CONNECTIONS;
diff --git a/plugins/HistoryLinkListPlus/src/linklist.cpp b/plugins/HistoryLinkListPlus/src/linklist.cpp index 02e5bf8837..e610ebac92 100644 --- a/plugins/HistoryLinkListPlus/src/linklist.cpp +++ b/plugins/HistoryLinkListPlus/src/linklist.cpp @@ -58,9 +58,9 @@ extern "C" __declspec(dllexport) int Load(void) CreateServiceFunction("Linklist/MenuCommand", LinkList_Main);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_LINKLISTICON));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_LINKLISTICON));
mi.name.t = LPGENT("&Create Linklist");
mi.pszService = "Linklist/MenuCommand";
Menu_AddContactMenuItem(&mi);
diff --git a/plugins/HistoryPlusPlus/historypp.dpr b/plugins/HistoryPlusPlus/historypp.dpr index 844a9cef97..0230b15c99 100644 --- a/plugins/HistoryPlusPlus/historypp.dpr +++ b/plugins/HistoryPlusPlus/historypp.dpr @@ -234,7 +234,7 @@ end; // init plugin
function OnModulesLoad(awParam{0}:WPARAM; alParam{0}:LPARAM):integer; cdecl;
var
- menuItem:TCLISTMENUITEM;
+ menuItem:TMO_MenuItem;
begin
// register
hppRegisterGridOptions;
diff --git a/plugins/HistoryStats/src/mu_common.cpp b/plugins/HistoryStats/src/mu_common.cpp index 077bdc8c1d..393bf4ef5e 100644 --- a/plugins/HistoryStats/src/mu_common.cpp +++ b/plugins/HistoryStats/src/mu_common.cpp @@ -15,24 +15,24 @@ namespace mu HGENMENU addMainMenuItem(const TCHAR* pszName, DWORD flags, int position, HICON hIcon, const char* pszService, HGENMENU hRoot)
{
// TODO: support for unicode-core with unicode-aware CList
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = (TCHAR*)pszName;
mi.flags = flags | CMIF_TCHAR;
mi.position = position;
- mi.icolibItem = hIcon;
+ mi.hIcolibItem = hIcon;
mi.pszService = const_cast<char*>(pszService);
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
return Menu_AddMainMenuItem(&mi);
}
HGENMENU addContactMenuItem(const TCHAR* pszName, DWORD flags, int position, HICON hIcon, const char* pszService)
{
// TODO: support for unicode-core with unicode-aware CList
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = (TCHAR*)pszName;
mi.flags = flags | CMIF_TCHAR;
mi.position = position;
- mi.icolibItem = hIcon;
+ mi.hIcolibItem = hIcon;
mi.pszService = const_cast<char*>(pszService);
return Menu_AddContactMenuItem(&mi);
}
diff --git a/plugins/IEHistory/src/IEHistory.cpp b/plugins/IEHistory/src/IEHistory.cpp index 78c6b1c537..a89a5b20b0 100644 --- a/plugins/IEHistory/src/IEHistory.cpp +++ b/plugins/IEHistory/src/IEHistory.cpp @@ -75,11 +75,11 @@ extern "C" int __declspec(dllexport) Load(void) InitServices(); /// menu items - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.name.t = LPGENT("View &history"); mi.flags = CMIF_TCHAR; mi.position = 1000090000; - mi.icolibItem = hIcon; + mi.hIcolibItem = hIcon; mi.pszService = MS_HISTORY_SHOWCONTACTHISTORY; Menu_AddContactMenuItem(&mi); diff --git a/plugins/Import/src/main.cpp b/plugins/Import/src/main.cpp index 077367fa98..a67ba073b1 100644 --- a/plugins/Import/src/main.cpp +++ b/plugins/Import/src/main.cpp @@ -114,8 +114,8 @@ extern "C" __declspec(dllexport) int Load(void) RegisterIcons();
// menu item
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = GetIconHandle(IDI_IMPORT);
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = GetIconHandle(IDI_IMPORT);
mi.name.a = LPGEN("&Import...");
mi.position = 500050000;
mi.pszService = IMPORT_SERVICE;
diff --git a/plugins/ImportTXT/importtxt.dpr b/plugins/ImportTXT/importtxt.dpr index e5e8b896b2..bc21128b53 100644 --- a/plugins/ImportTXT/importtxt.dpr +++ b/plugins/ImportTXT/importtxt.dpr @@ -114,7 +114,7 @@ end; function Load(): int; cdecl;
var
- mi: TCListMenuItem;
+ mi:TMO_MenuItem;
begin
cp := Langpack_GetDefaultCodePage;
SrvITxt := CreateServiceFunction(IMPORT_TXT_SERVICE, @ContactMenuCommand);
diff --git a/plugins/ListeningTo/src/listeningto.cpp b/plugins/ListeningTo/src/listeningto.cpp index 76fbe3d140..cf48eb104d 100644 --- a/plugins/ListeningTo/src/listeningto.cpp +++ b/plugins/ListeningTo/src/listeningto.cpp @@ -192,9 +192,9 @@ void RebuildMenu() TCHAR text[512];
mir_sntprintf(text, TranslateT("Send to %s"), info->account);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 100000 + i;
- mi.hParentMenu = hMainMenuGroup;
+ mi.root = hMainMenuGroup;
mi.position = 500080000 + i;
mi.pszService = MS_LISTENINGTO_MAINMENU;
mi.name.t = text;
@@ -293,17 +293,17 @@ int ModulesLoaded(WPARAM, LPARAM) }
// Add main menu item
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500080000;
mi.name.t = LPGENT("Listening to");
mi.flags = CMIF_TCHAR;
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
hMainMenuGroup = Menu_AddMainMenuItem(&mi);
- mi.hParentMenu = hMainMenuGroup;
+ mi.root = hMainMenuGroup;
mi.position = 0;
mi.pszService = MS_LISTENINGTO_MAINMENU;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
// Add all protos
mi.name.t = LPGENT("Send to all protocols");
diff --git a/plugins/LotusNotify/src/LotusNotify.cpp b/plugins/LotusNotify/src/LotusNotify.cpp index 9ecaec708c..854ad888c3 100644 --- a/plugins/LotusNotify/src/LotusNotify.cpp +++ b/plugins/LotusNotify/src/LotusNotify.cpp @@ -1727,10 +1727,10 @@ extern "C" int __declspec(dllexport) Load(void) //function that will be called on menu click
hMenuService = CreateServiceFunction("LotusNotify/MenuCommand", PluginMenuCommand);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF; //on top menu position
mi.flags = CMIF_TCHAR;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ICON1));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ICON1));
mi.name.t = LPGENT("&Check Lotus");
mi.pszService = "LotusNotify/MenuCommand"; //service name thet listning for menu call
hMenuHandle = Menu_AddMainMenuItem(&mi); //create menu pos.
diff --git a/plugins/MenuItemEx/src/main.cpp b/plugins/MenuItemEx/src/main.cpp index bf686a5028..ddb951e06e 100644 --- a/plugins/MenuItemEx/src/main.cpp +++ b/plugins/MenuItemEx/src/main.cpp @@ -735,11 +735,11 @@ INT_PTR onIgnore(WPARAM wparam, LPARAM lparam) static HGENMENU AddSubmenuItem(HGENMENU hRoot, TCHAR* name, HICON icon, DWORD flag, char* service, int pos, int param)
{
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hRoot;
mi.position = pos;
mi.name.t = name;
- mi.icolibItem = icon;
+ mi.hIcolibItem = icon;
mi.flags = CMIF_UNICODE | flag;
mi.pszService = service;
@@ -960,7 +960,7 @@ static int PluginInit(WPARAM, LPARAM) ModuleLoad(0, 0);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_UNICODE;
mi.position = 120000;
@@ -981,7 +981,7 @@ static int PluginInit(WPARAM, LPARAM) mi.position++;
mi.name.t = LPGENT("Ignore");
mi.pszService = 0;
- mi.icolibItem = IcoLib_GetIcon("miex_ignore");
+ mi.hIcolibItem = IcoLib_GetIcon("miex_ignore");
hmenuIgnore = Menu_AddContactMenuItem(&mi);
hIgnoreItem[0] = AddSubmenuItem(hmenuIgnore, ii[0].name, Skin_LoadIcon(ii[0].icon), 0, MS_IGNORE, pos, ii[0].type);
@@ -998,7 +998,7 @@ static int PluginInit(WPARAM, LPARAM) mi.position++;
mi.name.t = LPGENT("Copy to Account");
mi.pszService = MS_PROTO;
- mi.icolibItem = IcoLib_GetIcon("miex_protocol");
+ mi.hIcolibItem = IcoLib_GetIcon("miex_protocol");
hmenuProto = Menu_AddContactMenuItem(&mi);
EnumProtoSubmenu(0, 0);
@@ -1008,13 +1008,13 @@ static int PluginInit(WPARAM, LPARAM) mi.position++;
mi.name.t = LPGENT("Send 'You were added'");
mi.pszService = MS_ADDED;
- mi.icolibItem = Skin_LoadIcon(SKINICON_AUTH_ADD);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_AUTH_ADD);
hmenuAdded = Menu_AddContactMenuItem(&mi);
mi.position++;
mi.name.t = LPGENT("Request authorization");
mi.pszService = MS_AUTHREQ;
- mi.icolibItem = Skin_LoadIcon(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_AUTH_REQUEST);
hmenuAuthReq = Menu_AddContactMenuItem(&mi);
mi.position++;
@@ -1025,13 +1025,13 @@ static int PluginInit(WPARAM, LPARAM) mi.position++;
mi.name.t = LPGENT("Browse Received Files");
mi.pszService = MS_RECVFILES;
- mi.icolibItem = IcoLib_GetIcon("miex_recfiles");
+ mi.hIcolibItem = IcoLib_GetIcon("miex_recfiles");
hmenuRecvFiles = Menu_AddContactMenuItem(&mi);
mi.position++;
mi.name.t = LPGENT("Copy Status Message");
mi.pszService = MS_STATUSMSG;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
hmenuStatusMsg = Menu_AddContactMenuItem(&mi);
mi.position++;
diff --git a/plugins/MirLua/src/m_genmenu.cpp b/plugins/MirLua/src/m_genmenu.cpp index 184b563265..1d03263970 100644 --- a/plugins/MirLua/src/m_genmenu.cpp +++ b/plugins/MirLua/src/m_genmenu.cpp @@ -1,8 +1,8 @@ #include "stdafx.h"
-static CLISTMENUITEM* MakeMenuItem(lua_State *L)
+static TMO_MenuItem* MakeMenuItem(lua_State *L)
{
- CLISTMENUITEM *pmi = (CLISTMENUITEM*)mir_calloc(sizeof(CLISTMENUITEM));
+ TMO_MenuItem *pmi = (TMO_MenuItem*)mir_calloc(sizeof(TMO_MenuItem));
pmi->hLangpack = hScriptsLangpack;
lua_pushstring(L, "Flags");
@@ -25,7 +25,7 @@ static CLISTMENUITEM* MakeMenuItem(lua_State *L) lua_pushstring(L, "Icon");
lua_gettable(L, -2);
- pmi->icolibItem = (HANDLE)lua_touserdata(L, -1);
+ pmi->hIcolibItem = (HANDLE)lua_touserdata(L, -1);
lua_pop(L, 1);
lua_pushstring(L, "Service");
@@ -35,7 +35,7 @@ static CLISTMENUITEM* MakeMenuItem(lua_State *L) lua_pushstring(L, "Parent");
lua_gettable(L, -2);
- pmi->hParentMenu = (HGENMENU)lua_touserdata(L, -1);
+ pmi->root = (HGENMENU)lua_touserdata(L, -1);
lua_pop(L, 1);
return pmi;
@@ -49,9 +49,9 @@ static int lua_AddMainMenuItem(lua_State *L) return 1;
}
- mir_ptr<CLISTMENUITEM> pmi(MakeMenuItem(L));
+ mir_ptr<TMO_MenuItem> pmi(MakeMenuItem(L));
- HGENMENU res = (HGENMENU)::CallService("CList/AddMainMenuItem", 0, (LPARAM)pmi);
+ HGENMENU res = Menu_AddMainMenuItem(pmi);
lua_pushlightuserdata(L, res);
return 1;
@@ -65,9 +65,9 @@ static int lua_AddContactMenuItem(lua_State *L) return 1;
}
- mir_ptr<CLISTMENUITEM> pmi(MakeMenuItem(L));
+ mir_ptr<TMO_MenuItem> pmi(MakeMenuItem(L));
- HGENMENU res = (HGENMENU)::CallService("CList/AddContactMenuItem", 0, (LPARAM)pmi);
+ HGENMENU res = Menu_AddContactMenuItem(pmi);
lua_pushlightuserdata(L, res);
return 1;
@@ -81,7 +81,7 @@ static int lua_AddTrayMenuItem(lua_State *L) return 1;
}
- mir_ptr<CLISTMENUITEM> pmi(MakeMenuItem(L));
+ mir_ptr<TMO_MenuItem> pmi(MakeMenuItem(L));
HGENMENU res = (HGENMENU)::CallService("CList/AddTrayMenuItem", 0, (LPARAM)pmi);
lua_pushlightuserdata(L, res);
@@ -99,9 +99,9 @@ static int lua_ModifyMenuItem(lua_State *L) return 1;
}
- mir_ptr<CLISTMENUITEM> pmi(MakeMenuItem(L));
+ mir_ptr<TMO_MenuItem> pmi(MakeMenuItem(L));
- INT_PTR res = ::Menu_ModifyItem(hMenuItem, pmi->name.t, pmi->icolibItem, pmi->flags);
+ INT_PTR res = ::Menu_ModifyItem(hMenuItem, pmi->name.t, pmi->hIcolibItem, pmi->flags);
lua_pushinteger(L, res);
return 1;
}
diff --git a/plugins/MirOTR/src/svcs_menu.cpp b/plugins/MirOTR/src/svcs_menu.cpp index 2bd606c90e..585463f2bd 100644 --- a/plugins/MirOTR/src/svcs_menu.cpp +++ b/plugins/MirOTR/src/svcs_menu.cpp @@ -158,19 +158,19 @@ void InitMenu() CreateServiceFunction(MS_OTR_MENUVERIFY, SVC_VerifyOTR); CreateServiceFunction(MS_OTR_MENUTOGGLEHTML, SVC_ToggleHTMLOTR); - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.flags = CMIF_NOTOFFLINE | CMIF_TCHAR; mi.position = -400000; mi.name.t = _T(LANG_STOP_OTR); mi.pszService = MS_OTR_MENUSTOP; - mi.icolibItem = IcoLib_GetIconHandle(ICON_PRIVATE); + mi.hIcolibItem = IcoLib_GetIconHandle(ICON_PRIVATE); hStopItem = Menu_AddContactMenuItem(&mi); mi.name.t = _T(LANG_START_OTR); mi.pszService = MS_OTR_MENUSTART; - mi.icolibItem = IcoLib_GetIconHandle(ICON_NOT_PRIVATE); + mi.hIcolibItem = IcoLib_GetIconHandle(ICON_NOT_PRIVATE); hStartItem = Menu_AddContactMenuItem(&mi); diff --git a/plugins/Msg_Export/src/main.cpp b/plugins/Msg_Export/src/main.cpp index e8ccc6572c..6ef3c4bd23 100755 --- a/plugins/Msg_Export/src/main.cpp +++ b/plugins/Msg_Export/src/main.cpp @@ -114,8 +114,8 @@ int MainInit(WPARAM /*wparam*/, LPARAM /*lparam*/) if (!bReplaceHistory)
{
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_EXPORT_MESSAGE));
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_EXPORT_MESSAGE));
mi.position = 1000090100;
mi.name.a = LPGEN("Open E&xported History");
mi.pszService = MS_SHOW_EXPORT_HISTORY;
diff --git a/plugins/MyDetails/src/frame.cpp b/plugins/MyDetails/src/frame.cpp index 0dc9c42f6f..4f51a056ce 100644 --- a/plugins/MyDetails/src/frame.cpp +++ b/plugins/MyDetails/src/frame.cpp @@ -327,11 +327,11 @@ int CreateFrame() // Create menu item
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("My details"), 500010000);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("My details"), 500010000);
mi.position = 1;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_USERDETAILS);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_USERDETAILS);
mi.name.t = LPGENT("Show my details");
mi.pszService = MODULE_NAME"/ShowHideMyDetails";
hMenuShowHideFrame = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/MyDetails/src/mydetails.cpp b/plugins/MyDetails/src/mydetails.cpp index 0182ea778f..cc23b3614b 100644 --- a/plugins/MyDetails/src/mydetails.cpp +++ b/plugins/MyDetails/src/mydetails.cpp @@ -87,16 +87,16 @@ static int MainInit(WPARAM, LPARAM) InitProtocolData();
// Add options to menu
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500050000;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_USERDETAILS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_USERDETAILS);
mi.name.t = LPGENT("My details");
HGENMENU hMenuRoot = Menu_AddMainMenuItem(&mi);
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = hMenuRoot;
- mi.icolibItem = NULL;
+ mi.root = hMenuRoot;
+ mi.hIcolibItem = NULL;
if (protocols->CanSetAvatars()) {
mi.position = 100001;
diff --git a/plugins/NewAwaySysMod/src/AwaySys.cpp b/plugins/NewAwaySysMod/src/AwaySys.cpp index 3f0326764e..4d17b5c912 100644 --- a/plugins/NewAwaySysMod/src/AwaySys.cpp +++ b/plugins/NewAwaySysMod/src/AwaySys.cpp @@ -611,10 +611,10 @@ int MirandaLoaded(WPARAM, LPARAM) int SendOnEvent = CContactSettings(g_ProtoStates[(char*)NULL].Status).Autoreply;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000020000;
mi.flags = CMIF_TCHAR | CMIF_NOTOFFLINE;
- mi.icolibItem = iconList[SendOnEvent ? 1 : 0].hIcolib;
+ mi.hIcolibItem = iconList[SendOnEvent ? 1 : 0].hIcolib;
mi.name.t = SendOnEvent ? DISABLE_SOE_COMMAND : ENABLE_SOE_COMMAND;
mi.pszService = MS_AWAYSYS_AUTOREPLY_TOGGLE;
g_hToggleSOEMenuItem = Menu_AddMainMenuItem(&mi);
@@ -631,32 +631,32 @@ int MirandaLoaded(WPARAM, LPARAM) mi.flags = CMIF_TCHAR | CMIF_HIDDEN;
mi.name.t = LPGENT("Set status message"); // will never be shown
mi.position = 1000020000;
- mi.icolibItem = LoadIcon(g_hInstance, MAKEINTRESOURCE(IDI_MSGICON));
+ mi.hIcolibItem = LoadIcon(g_hInstance, MAKEINTRESOURCE(IDI_MSGICON));
mi.pszService = MS_AWAYSYS_SETCONTACTSTATMSG;
g_hContactMenuItem = Menu_AddContactMenuItem(&mi);
memset(&mi, 0, sizeof(mi));
mi.flags = CMIF_TCHAR;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.position = 1000020000;
mi.name.t = LPGENT("Autoreply");
g_hToggleSOEContactMenuItem = Menu_AddContactMenuItem(&mi);
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = g_hToggleSOEContactMenuItem;
+ mi.root = g_hToggleSOEContactMenuItem;
mi.position = 1000020000;
- mi.icolibItem = iconList[1].hIcolib;
+ mi.hIcolibItem = iconList[1].hIcolib;
mi.name.t = LPGENT("On");
mi.pszService = MS_AWAYSYS_AUTOREPLY_ON;
g_hAutoreplyOnContactMenuItem = Menu_AddContactMenuItem(&mi);
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
mi.name.t = LPGENT("Off");
mi.pszService = MS_AWAYSYS_AUTOREPLY_OFF;
g_hAutoreplyOffContactMenuItem = Menu_AddContactMenuItem(&mi);
- mi.icolibItem = LoadIcon(g_hInstance, MAKEINTRESOURCE(IDI_DOT));
+ mi.hIcolibItem = LoadIcon(g_hInstance, MAKEINTRESOURCE(IDI_DOT));
mi.name.t = LPGENT("Use the default setting");
mi.pszService = MS_AWAYSYS_AUTOREPLY_USEDEFAULT;
g_hAutoreplyUseDefaultContactMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/NewEventNotify/src/menuitem.cpp b/plugins/NewEventNotify/src/menuitem.cpp index 26cd6248b1..793d817400 100644 --- a/plugins/NewEventNotify/src/menuitem.cpp +++ b/plugins/NewEventNotify/src/menuitem.cpp @@ -50,10 +50,10 @@ int MenuitemInit(BOOL bStatus) {
CreateServiceFunction(MS_NEN_MENUNOTIFY, MenuitemNotifyCmd);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
mi.position = 1;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ENABLED));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ENABLED));
mi.pszService = MS_NEN_MENUNOTIFY;
mi.flags = 0;
hMenuitemNotify = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/NewXstatusNotify/src/main.cpp b/plugins/NewXstatusNotify/src/main.cpp index 9740c84963..1526fb059a 100644 --- a/plugins/NewXstatusNotify/src/main.cpp +++ b/plugins/NewXstatusNotify/src/main.cpp @@ -1073,10 +1073,10 @@ INT_PTR EnableDisableMenuCommand(WPARAM, LPARAM) void InitMainMenuItem()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
if (ServiceExists(MS_POPUP_ADDPOPUPT))
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
mi.pszService = MS_STATUSCHANGE_MENUCOMMAND;
hEnableDisableMenu = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/New_GPG/src/init.cpp b/plugins/New_GPG/src/init.cpp index d4bfdbefae..bc25e2f519 100644 --- a/plugins/New_GPG/src/init.cpp +++ b/plugins/New_GPG/src/init.cpp @@ -177,10 +177,10 @@ extern "C" int __declspec(dllexport) Load() CreateServiceFunction("/ImportGPGKeys",ImportGpGKeys);
// !!!!!!!! check it later
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position=-0x7FFFFFFF;
mi.flags=CMIF_TCHAR;
- mi.icolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t=LPGENT("Load GPG public key");
mi.pszService="/LoadPubKey";
hLoadPubKey = Menu_AddContactMenuItem(&mi);
@@ -188,7 +188,7 @@ extern "C" int __declspec(dllexport) Load() memset(&mi, 0, sizeof(mi));
mi.position=-0x7FFFFFFe;
mi.flags=CMIF_TCHAR;
- mi.icolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t=LPGENT("Toggle GPG encryption");
mi.pszService="/ToggleEncryption";
hToggleEncryption = Menu_AddContactMenuItem(&mi);
@@ -196,7 +196,7 @@ extern "C" int __declspec(dllexport) Load() memset(&mi, 0, sizeof(mi));
mi.position=-0x7FFFFFFd;
mi.flags=CMIF_TCHAR;
- mi.icolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t=LPGENT("Send public key");
mi.pszService="/SendKey";
hSendKey = Menu_AddContactMenuItem(&mi);
@@ -204,7 +204,7 @@ extern "C" int __declspec(dllexport) Load() memset(&mi, 0, sizeof(mi));
mi.position=-0x7FFFFFFe;
mi.flags=CMIF_TCHAR;
- mi.icolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t=LPGENT("Export GPG Public keys");
mi.pszService="/ExportGPGKeys";
hExportGpgKeys = Menu_AddMainMenuItem(&mi);
@@ -212,7 +212,7 @@ extern "C" int __declspec(dllexport) Load() memset(&mi, 0, sizeof(mi));
mi.position=-0x7FFFFFFF;
mi.flags=CMIF_TCHAR;
- mi.icolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t=LPGENT("Import GPG Public keys");
mi.pszService="/ImportGPGKeys";
hImportGpgKeys = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/New_GPG/src/utilities.cpp b/plugins/New_GPG/src/utilities.cpp index c28eff9c32..9443362054 100755 --- a/plugins/New_GPG/src/utilities.cpp +++ b/plugins/New_GPG/src/utilities.cpp @@ -235,7 +235,7 @@ int OnPreBuildContactMenu(WPARAM w, LPARAM l) { MCONTACT hContact = db_mc_tryMeta(w); { - CLISTMENUITEM mi2 = { 0 }; + TMO_MenuItem mi2 = { 0 }; LPSTR proto = GetContactProto(hContact); PROTOACCOUNT *acc = Proto_GetAccount(proto); std::string setting; diff --git a/plugins/NewsAggregator/Src/Menus.cpp b/plugins/NewsAggregator/Src/Menus.cpp index 209e55bc19..c4b49cfb77 100644 --- a/plugins/NewsAggregator/Src/Menus.cpp +++ b/plugins/NewsAggregator/Src/Menus.cpp @@ -23,16 +23,16 @@ HGENMENU hService2[7]; void InitMenu()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR | CMIF_NOTOFFLINE;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("News Aggregator"), 500099000);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("News Aggregator"), 500099000);
mi.position = 10100001;
if (db_get_b(NULL, MODULE, "AutoUpdate", 1))
mi.name.t = LPGENT("Auto Update Enabled");
else
mi.name.t = LPGENT("Auto Update Disabled");
- mi.icolibItem = GetIconHandle("main");
+ mi.hIcolibItem = GetIconHandle("main");
mi.pszService = MS_NEWSAGGREGATOR_ENABLED;
hService2[0] = Menu_AddMainMenuItem(&mi);
@@ -42,28 +42,28 @@ void InitMenu() hService2[1] = Menu_AddMainMenuItem(&mi);
mi.position = 20100002;
- mi.icolibItem = GetIconHandle("addfeed");
+ mi.hIcolibItem = GetIconHandle("addfeed");
mi.name.t = LPGENT("Add Feed");
mi.pszService = MS_NEWSAGGREGATOR_ADDFEED;
hService2[2] = Menu_AddMainMenuItem(&mi);
mi.position = 20100003;
- mi.icolibItem = GetIconHandle("importfeeds");
+ mi.hIcolibItem = GetIconHandle("importfeeds");
mi.name.t = LPGENT("Import Feeds");
mi.pszService = MS_NEWSAGGREGATOR_IMPORTFEEDS;
hService2[3] = Menu_AddMainMenuItem(&mi);
mi.position = 20100004;
- mi.icolibItem = GetIconHandle("exportfeeds");
+ mi.hIcolibItem = GetIconHandle("exportfeeds");
mi.name.t = LPGENT("Export Feeds");
mi.pszService = MS_NEWSAGGREGATOR_EXPORTFEEDS;
hService2[4] = Menu_AddMainMenuItem(&mi);
// adding contact menu items
- mi.hParentMenu = NULL;
+ mi.root = NULL;
mi.position = -0x7FFFFFFA;
- mi.icolibItem = GetIconHandle("checkfeed");
+ mi.hIcolibItem = GetIconHandle("checkfeed");
mi.name.t = LPGENT("Check feed");
mi.pszService = MS_NEWSAGGREGATOR_CHECKFEED;
hService2[5] = Menu_AddContactMenuItem(&mi, MODULE);
diff --git a/plugins/NoHistory/src/dllmain.cpp b/plugins/NoHistory/src/dllmain.cpp index 9fdbb1dba3..a788d5495e 100644 --- a/plugins/NoHistory/src/dllmain.cpp +++ b/plugins/NoHistory/src/dllmain.cpp @@ -245,19 +245,19 @@ void SrmmMenu_Load() int ModulesLoaded(WPARAM wParam, LPARAM lParam)
{
// create contact menu item
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
mi.position = -300010;
mi.name.t = LPGENT("Disable History");
mi.pszService = MS_NOHISTORY_TOGGLE;
- mi.icolibItem = hIconRemove;
+ mi.hIcolibItem = hIconRemove;
hMenuToggle = Menu_AddContactMenuItem(&mi);
mi.position = -300005;
mi.name.t = LPGENT("Clear History");
mi.pszService = MS_NOHISTORY_CLEAR;
- mi.icolibItem = hIconClear;
+ mi.hIcolibItem = hIconClear;
hMenuClear = Menu_AddContactMenuItem(&mi);
// add icon to srmm status icons
diff --git a/plugins/Non-IM Contact/src/main.cpp b/plugins/Non-IM Contact/src/main.cpp index c14f80d8f1..bc0e18dddd 100644 --- a/plugins/Non-IM Contact/src/main.cpp +++ b/plugins/Non-IM Contact/src/main.cpp @@ -141,12 +141,12 @@ extern "C" __declspec(dllexport) int Load() CreateServiceFunction("TestStringReplaceLine", testStringReplacer);
CreateServiceFunction("NIM_Contact/DoubleClick", doubleClick);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 600090000;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("&Non-IM Contact"), 600090000);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("&Non-IM Contact"), 600090000);
mi.name.a = LPGEN("&Add Non-IM Contact");
mi.pszService = "AddLCcontact";
- mi.icolibItem = icoList[0].hIcolib;
+ mi.hIcolibItem = icoList[0].hIcolib;
Menu_AddMainMenuItem(&mi);
mi.position = 600090001;
@@ -171,7 +171,7 @@ extern "C" __declspec(dllexport) int Load() mi.pszService = "TestStringReplaceLine";
Menu_AddMainMenuItem(&mi);
- mi.hParentMenu = NULL;
+ mi.root = NULL;
mi.position = -2000080000;
mi.name.a = LPGEN("E&dit Contact Settings");
mi.pszService = "EditLCcontact";
diff --git a/plugins/NotesAndReminders/src/main.cpp b/plugins/NotesAndReminders/src/main.cpp index 84fa4fed13..447094b82d 100644 --- a/plugins/NotesAndReminders/src/main.cpp +++ b/plugins/NotesAndReminders/src/main.cpp @@ -175,12 +175,12 @@ static void InitServices() /////////////////////////////////////////////////////////////////////////////////////////
-static void addMenuItem(CLISTMENUITEM &mi)
+static void addMenuItem(TMO_MenuItem &mi)
{
if (g_AddContListMI) {
- HGENMENU save = mi.hParentMenu; mi.hParentMenu = NULL;
+ HGENMENU save = mi.root; mi.root = NULL;
Menu_AddContactMenuItem(&mi);
- mi.hParentMenu = save;
+ mi.root = save;
}
Menu_AddMainMenuItem(&mi);
}
@@ -194,54 +194,54 @@ int OnModulesLoaded(WPARAM wparam, LPARAM lparam) g_AddContListMI = (BOOL)db_get_dw(0,MODULENAME,"AddContactMenuItems",1);
// register menus
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENW("Notes && Reminders"), 1600000000);
mi.flags = CMIF_TCHAR;
mi.position = 1600000000;
- mi.icolibItem = iconList[2].hIcolib;
+ mi.hIcolibItem = iconList[2].hIcolib;
mi.name.t = LPGENT("New &Note");
mi.pszService = MODULENAME"/MenuCommandAddNew";
addMenuItem(mi);
mi.position = 1600000001;
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
mi.name.t = LPGENT("New &Reminder");
mi.pszService = MODULENAME"/MenuCommandNewReminder";
addMenuItem(mi);
mi.position = 1600100000;
- mi.icolibItem = iconList[3].hIcolib;
+ mi.hIcolibItem = iconList[3].hIcolib;
mi.name.t = LPGENT("&Show / Hide Notes");
mi.pszService = MODULENAME"/MenuCommandShowHide";
addMenuItem(mi);
mi.position = 1600100001;
- mi.icolibItem = iconList[13].hIcolib;
+ mi.hIcolibItem = iconList[13].hIcolib;
mi.name.t = LPGENT("Vie&w Notes");
mi.pszService = MODULENAME"/MenuCommandViewNotes";
addMenuItem(mi);
mi.position = 1600100002;
- mi.icolibItem = iconList[1].hIcolib;
+ mi.hIcolibItem = iconList[1].hIcolib;
mi.name.t = LPGENT("&Delete All Notes");
mi.pszService = MODULENAME"/MenuCommandDeleteAll";
addMenuItem(mi);
mi.position = 1600100003;
- mi.icolibItem = iconList[11].hIcolib;
+ mi.hIcolibItem = iconList[11].hIcolib;
mi.name.t = LPGENT("&Bring All to Front");
mi.pszService = MODULENAME"/MenuCommandBringAllFront";
addMenuItem(mi);
mi.position = 1600200000;
- mi.icolibItem = iconList[6].hIcolib;
+ mi.hIcolibItem = iconList[6].hIcolib;
mi.name.t = LPGENT("&View Reminders");
mi.pszService = MODULENAME"/MenuCommandViewReminders";
addMenuItem(mi);
mi.position = 1600200001;
- mi.icolibItem = iconList[5].hIcolib;
+ mi.hIcolibItem = iconList[5].hIcolib;
mi.name.t = LPGENT("D&elete All Reminders");
mi.pszService = MODULENAME"/MenuCommandDeleteReminders";
addMenuItem(mi);
diff --git a/plugins/Nudge/src/main.cpp b/plugins/Nudge/src/main.cpp index 0757e7a389..36265315f0 100644 --- a/plugins/Nudge/src/main.cpp +++ b/plugins/Nudge/src/main.cpp @@ -336,11 +336,11 @@ extern "C" int __declspec(dllexport) Load(void) CreateServiceFunction(MS_NUDGE_SHOWMENU, NudgeShowMenu);
// Add contact menu entry
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
// mi.popupPosition = 500085000; !!!!!!!!!!!!!!!!!!!!!
mi.flags = CMIF_NOTOFFLINE | CMIF_TCHAR;
mi.position = -500050004;
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
mi.name.t = LPGENT("Send &Nudge");
mi.pszService = MS_NUDGE_SEND;
g_hContactMenu = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/OpenFolder/src/openFolder.cpp b/plugins/OpenFolder/src/openFolder.cpp index 6731fdca09..646cb0b0b8 100644 --- a/plugins/OpenFolder/src/openFolder.cpp +++ b/plugins/OpenFolder/src/openFolder.cpp @@ -97,10 +97,10 @@ extern "C" int __declspec(dllexport) Load() hotkey.DefHotKey = MAKEWORD( 'O', HOTKEYF_SHIFT | HOTKEYF_ALT );
Hotkey_Register(&hotkey);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = icon.hIcolib;
+ mi.hIcolibItem = icon.hIcolib;
mi.name.t = LPGENT("Open Folder");
mi.pszService = MS_OPENFOLDER_OPEN;
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/PackUpdater/Src/PackUpdater.cpp b/plugins/PackUpdater/Src/PackUpdater.cpp index 80f6e60718..5f5934e58f 100644 --- a/plugins/PackUpdater/Src/PackUpdater.cpp +++ b/plugins/PackUpdater/Src/PackUpdater.cpp @@ -70,10 +70,10 @@ extern "C" __declspec(dllexport) int Load(void) // Add cheking update menu item
CreateServiceFunction(MODNAME"/CheckUpdates", MenuCommand);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = IcoLib_GetIcon("check_update");
+ mi.hIcolibItem = IcoLib_GetIcon("check_update");
mi.name.t = LPGENT("Check for pack updates");
mi.pszService = MODNAME"/CheckUpdates";
Menu_AddMainMenuItem(&mi);
@@ -82,7 +82,7 @@ extern "C" __declspec(dllexport) int Load(void) memset(&mi, 0, sizeof(mi));
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = IcoLib_GetIcon("empty_folder");
+ mi.hIcolibItem = IcoLib_GetIcon("empty_folder");
mi.name.t = LPGENT("Clear pack updates folder");
mi.pszService = MODNAME"/EmptyFolder";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/PasteIt/src/PasteIt.cpp b/plugins/PasteIt/src/PasteIt.cpp index 6ba4cf795c..7c0e1f1296 100644 --- a/plugins/PasteIt/src/PasteIt.cpp +++ b/plugins/PasteIt/src/PasteIt.cpp @@ -291,9 +291,9 @@ INT_PTR ContactMenuService(WPARAM hContact, LPARAM lParam) void InitMenuItems()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.icolibItem = icon.hIcolib;
+ mi.hIcolibItem = icon.hIcolib;
mi.position = 3000090005;
mi.name.t = LPGENT("Paste It");
@@ -302,7 +302,7 @@ void InitMenuItems() memset(&mi, 0, sizeof(mi));
mi.flags = CMIF_TCHAR;
mi.pszService = MS_PASTEIT_CONTACTMENU;
- mi.hParentMenu = hContactMenu;
+ mi.root = hContactMenu;
mi.name.t = LPGENT("Paste from clipboard");
Menu_ConfigureItem(Menu_AddContactMenuItem(&mi), MCI_OPT_EXECPARAM, FROM_CLIPBOARD);
@@ -313,9 +313,9 @@ void InitMenuItems() HGENMENU hDefWebMenu = Menu_AddContactMenuItem(&mi);
Menu_ConfigureItem(hDefWebMenu, MCI_OPT_EXECPARAM, DEF_PAGES_START - 1);
- CLISTMENUITEM mi2 = { 0 };
+ TMO_MenuItem mi2 = { 0 };
mi2.pszService = MS_PASTEIT_CONTACTMENU;
- mi2.hParentMenu = hDefWebMenu;
+ mi2.root = hDefWebMenu;
for (int i = 0; i < PasteToWeb::pages; ++i)
{
mi2.flags = CMIF_TCHAR;
diff --git a/plugins/Ping/src/menu.cpp b/plugins/Ping/src/menu.cpp index 4906dceeb4..d70e28aaa5 100644 --- a/plugins/Ping/src/menu.cpp +++ b/plugins/Ping/src/menu.cpp @@ -6,18 +6,18 @@ HANDLE hEventMenuBuild; void InitMenus()
{
// main menu
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Ping"), 500099900);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Ping"), 500099900);
mi.position = 2000060000;
- mi.icolibItem = hIconResponding;
+ mi.hIcolibItem = hIconResponding;
mi.name.t = LPGENT("Enable all pings");
mi.pszService = PLUG "/EnableAll";
Menu_AddMainMenuItem(&mi);
mi.position = 2000060001;
- mi.icolibItem = hIconDisabled;
+ mi.hIcolibItem = hIconDisabled;
mi.name.t = LPGENT("Disable all pings");
mi.pszService = PLUG "/DisableAll";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/Ping/src/pingthread.cpp b/plugins/Ping/src/pingthread.cpp index 272326edee..68a3821cb2 100644 --- a/plugins/Ping/src/pingthread.cpp +++ b/plugins/Ping/src/pingthread.cpp @@ -991,9 +991,9 @@ void InitList() CreateServiceFunction(PLUG "/ShowWindow", PingPlugShowWindow);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Ping"), 1000200001);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Ping"), 1000200001);
mi.position = 3000320001;
mi.name.t = LPGENT("Show/Hide &Ping Window");
mi.pszService = PLUG "/ShowWindow";
diff --git a/plugins/PluginUpdater/src/PluginUpdater.cpp b/plugins/PluginUpdater/src/PluginUpdater.cpp index b482a634a6..0653991da7 100644 --- a/plugins/PluginUpdater/src/PluginUpdater.cpp +++ b/plugins/PluginUpdater/src/PluginUpdater.cpp @@ -84,12 +84,12 @@ extern "C" __declspec(dllexport) int Load(void) // Add cheking update menu item
InitCheck();
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 400010000;
#if MIRANDA_VER >= 0x0A00
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
#else
- mi.icolibItem = IcoLib_GetIconHandle("check_update");
+ mi.hIcolibItem = IcoLib_GetIconHandle("check_update");
#endif
mi.name.a = LPGEN("Check for updates");
mi.pszService = MS_PU_CHECKUPDATES;
@@ -99,7 +99,7 @@ extern "C" __declspec(dllexport) int Load(void) InitListNew();
mi.position++;
- mi.icolibItem = iconList[2].hIcolib;
+ mi.hIcolibItem = iconList[2].hIcolib;
mi.name.a = LPGEN("Available components list");
mi.pszService = MS_PU_SHOWLIST;
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/Popup/src/main.cpp b/plugins/Popup/src/main.cpp index 1dbbcad7bc..88206532ed 100644 --- a/plugins/Popup/src/main.cpp +++ b/plugins/Popup/src/main.cpp @@ -179,18 +179,18 @@ INT_PTR svcShowHistory(WPARAM, LPARAM) void InitMenuItems(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
// support new genmenu style
mi.flags = CMIF_TCHAR;
// Build main menu
mi.position = -1000000000 /*1000001*/;
mi.name.t = LPGENT(MODULNAME_PLU);
- mi.icolibItem = IcoLib_GetIcon(PopupOptions.ModuleIsEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
+ mi.hIcolibItem = IcoLib_GetIcon(PopupOptions.ModuleIsEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
hMenuRoot = Menu_AddMainMenuItem(&mi);
// Add item to main menu
- mi.hParentMenu = (HGENMENU)hMenuRoot;
+ mi.root = (HGENMENU)hMenuRoot;
mi.pszService = MENUCOMMAND_SVC;
CreateServiceFunction(mi.pszService, svcEnableDisableMenuCommand);
@@ -202,7 +202,7 @@ void InitMenuItems(void) CreateServiceFunction(mi.pszService, svcShowHistory);
mi.position = 1000000000;
mi.name.t = LPGENT("Popup History");
- mi.icolibItem = IcoLib_GetIcon(ICO_HISTORY, 0);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_HISTORY, 0);
hMenuItemHistory = Menu_AddMainMenuItem(&mi);
}
diff --git a/plugins/ProfileManager/src/pmanagerEx.cpp b/plugins/ProfileManager/src/pmanagerEx.cpp index 50e0e8ad20..a0fb15e595 100644 --- a/plugins/ProfileManager/src/pmanagerEx.cpp +++ b/plugins/ProfileManager/src/pmanagerEx.cpp @@ -94,15 +94,15 @@ static IconItem iconList[] = static int OnModulesLoaded(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Database"), -500200000);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Database"), -500200000);
for (int i = 0; i < _countof(iconList); i++) {
mi.name.a = iconList[i].szDescr;
mi.pszService = iconList[i].szName;
- mi.icolibItem = iconList[i].hIcolib;
+ mi.hIcolibItem = iconList[i].hIcolib;
if (i == 3)
- mi.hParentMenu = NULL;
+ mi.root = NULL;
Menu_AddMainMenuItem(&mi);
}
return 0;
diff --git a/plugins/QuickContacts/src/quickcontacts.cpp b/plugins/QuickContacts/src/quickcontacts.cpp index e49a7a5318..3edd5741d8 100644 --- a/plugins/QuickContacts/src/quickcontacts.cpp +++ b/plugins/QuickContacts/src/quickcontacts.cpp @@ -184,7 +184,7 @@ int ModulesLoaded(WPARAM wParam, LPARAM lParam) hIml = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST,0,0);
// Add menu item
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500100001;
mi.flags = CMIF_TCHAR;
mi.name.t = LPGENT("Quick Contacts...");
diff --git a/plugins/QuickSearch/sr_global.pas b/plugins/QuickSearch/sr_global.pas index 578e631900..b4e18a1b92 100644 --- a/plugins/QuickSearch/sr_global.pas +++ b/plugins/QuickSearch/sr_global.pas @@ -236,16 +236,16 @@ end; procedure AddRemoveMenuItemToMainMenu;
var
- cmi:TCLISTMENUITEM;
+ mi:TMO_MenuItem;
begin
if MainMenuItem<>0 then exit;
- ZeroMemory(@cmi,sizeof(cmi));
- cmi.szName.a :=qs_name;
- cmi.position :=500050000;
- cmi.pszService :=QS_SHOWSERVICE;
- cmi.hIcon :=IcoLib_GetIcon(QS_QS,0);
- MainMenuItem :=Menu_AddMainMenuItem(@cmi);
+ ZeroMemory(@mi,sizeof(mi));
+ mi.szName.a :=qs_name;
+ mi.position :=500050000;
+ mi.pszService :=QS_SHOWSERVICE;
+ mi.hIcon :=IcoLib_GetIcon(QS_QS,0);
+ MainMenuItem :=Menu_AddMainMenuItem(@mi);
end;
// -------- column functions ---------
diff --git a/plugins/QuickSearch/sr_window.pas b/plugins/QuickSearch/sr_window.pas index 7399147902..6a6494a6dc 100644 --- a/plugins/QuickSearch/sr_window.pas +++ b/plugins/QuickSearch/sr_window.pas @@ -787,7 +787,7 @@ end; function ShowContactMenu(wnd:HWND;hContact:TMCONTACT;col:integer=-1):HMENU;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
pt:tpoint;
doit:bool;
begin
diff --git a/plugins/Quotes/src/Forex.cpp b/plugins/Quotes/src/Forex.cpp index 463075d995..6aea04d719 100644 --- a/plugins/Quotes/src/Forex.cpp +++ b/plugins/Quotes/src/Forex.cpp @@ -77,13 +77,13 @@ INT_PTR QuotesMenu_EnableDisable(WPARAM, LPARAM) void InitMenu()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Quotes"), 0, Quotes_GetIconHandle(IDI_ICON_MAIN));
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Quotes"), 0, Quotes_GetIconHandle(IDI_ICON_MAIN));
mi.name.t = LPGENT("Enable/Disable Auto Update");
mi.position = 10100001;
- mi.icolibItem = Quotes_GetIconHandle(IDI_ICON_MAIN);
+ mi.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_MAIN);
mi.pszService = g_pszAutoUpdateCmd;
g_hEnableDisableMenu = Menu_AddMainMenuItem(&mi);
CreateServiceFunction(mi.pszService, QuotesMenu_EnableDisable);
@@ -91,27 +91,27 @@ void InitMenu() mi.name.t = LPGENT("Refresh All Quotes\\Rates");
mi.position = 20100001;
- mi.icolibItem = Quotes_GetIconHandle(IDI_ICON_MAIN);
+ mi.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_MAIN);
mi.pszService = "Quotes/RefreshAll";
Menu_AddMainMenuItem(&mi);
CreateServiceFunction(mi.pszService, QuotesMenu_RefreshAll);
mi.name.t = LPGENT("Currency Converter...");
mi.position = 20100002;
- mi.icolibItem = Quotes_GetIconHandle(IDI_ICON_CURRENCY_CONVERTER);
+ mi.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_CURRENCY_CONVERTER);
mi.pszService = g_pszCurrencyConverter;
Menu_AddMainMenuItem(&mi);
CreateServiceFunction(mi.pszService, QuotesMenu_CurrencyConverter);
mi.name.t = LPGENT("Export All Quotes");
- mi.icolibItem = Quotes_GetIconHandle(IDI_ICON_EXPORT);
+ mi.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_EXPORT);
mi.pszService = "Quotes/ExportAll";
mi.position = 20100003;
Menu_AddMainMenuItem(&mi);
CreateServiceFunction(mi.pszService, QuotesMenu_ExportAll);
mi.name.t = LPGENT("Import All Quotes");
- mi.icolibItem = Quotes_GetIconHandle(IDI_ICON_IMPORT);
+ mi.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_IMPORT);
mi.pszService = "Quotes/ImportAll";
mi.position = 20100004;
Menu_AddMainMenuItem(&mi);
@@ -122,22 +122,22 @@ void InitMenu() HookEvent(ME_CLIST_PREBUILDCONTACTMENU, Quotes_PrebuildContactMenu);
if (bSubGroups) {
- CLISTMENUITEM miroot = { 0 };
- miroot.icolibItem = Quotes_GetIconHandle(IDI_ICON_MAIN);
+ TMO_MenuItem miroot = { 0 };
+ miroot.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_MAIN);
miroot.name.a = QUOTES_PROTOCOL_NAME;
- mi.hParentMenu = Menu_AddContactMenuItem(&miroot, QUOTES_PROTOCOL_NAME);
+ mi.root = Menu_AddContactMenuItem(&miroot, QUOTES_PROTOCOL_NAME);
}
- else mi.hParentMenu = NULL;
+ else mi.root = NULL;
mi.name.t = LPGENT("Refresh");
- mi.icolibItem = Quotes_GetIconHandle(IDI_ICON_REFRESH);
+ mi.hIcolibItem = Quotes_GetIconHandle(IDI_ICON_REFRESH);
mi.pszService = "Quotes/RefreshContact";
g_hMenuRefresh = Menu_AddContactMenuItem(&mi, QUOTES_PROTOCOL_NAME);
Menu_ConfigureItem(g_hMenuRefresh, MCI_OPT_EXECPARAM, INT_PTR(0));
CreateServiceFunction(mi.pszService, QuotesMenu_RefreshContact);
mi.name.t = LPGENT("Open Log File...");
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = "Quotes/OpenLogFile";
g_hMenuOpenLogFile = Menu_AddContactMenuItem(&mi, QUOTES_PROTOCOL_NAME);
Menu_ConfigureItem(g_hMenuOpenLogFile, MCI_OPT_EXECPARAM, 1);
@@ -146,14 +146,14 @@ void InitMenu() #ifdef CHART_IMPLEMENT
mi.name.t = LPGENT("Chart...");
mi.popupPosition = 2;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = "Quotes/Chart";
g_hMenuChart = Menu_AddContactMenuItem(&mi, QUOTES_PROTOCOL_NAME);
CreateServiceFunction(mi.pszService, QuotesMenu_Chart);
#endif
mi.name.t = LPGENT("Edit Settings...");
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.pszService = "Quotes/EditSettings";
g_hMenuEditSettings = Menu_AddContactMenuItem(&mi, QUOTES_PROTOCOL_NAME);
#ifdef CHART_IMPLEMENT
diff --git a/plugins/RecentContacts/src/RecentContacts.cpp b/plugins/RecentContacts/src/RecentContacts.cpp index b523991085..080f226031 100644 --- a/plugins/RecentContacts/src/RecentContacts.cpp +++ b/plugins/RecentContacts/src/RecentContacts.cpp @@ -460,14 +460,14 @@ int Create_TopToolbarShowList(WPARAM wParam, LPARAM lParam) int Create_MenuitemShowList(void)
{
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = icon.hIcolib;
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = icon.hIcolib;
mi.name.a = msLastUC_ShowListName;
mi.pszService = msLastUC_ShowList;
Menu_AddMainMenuItem(&mi);
mi.position = 0xFFFFF;
- mi.icolibItem = icon.hIcolib;
+ mi.hIcolibItem = icon.hIcolib;
mi.name.a = LPGEN("Toggle Ignore");
mi.pszService = V_RECENTCONTACTS_TOGGLE_IGNORE;
hMenuItemRemove = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/RemovePersonalSettings/src/rps.cpp b/plugins/RemovePersonalSettings/src/rps.cpp index 1cbeaf5b21..e7be2f3975 100644 --- a/plugins/RemovePersonalSettings/src/rps.cpp +++ b/plugins/RemovePersonalSettings/src/rps.cpp @@ -121,13 +121,13 @@ extern "C" int __declspec(dllexport) Load() {
mir_getLP(&pluginInfo);
- CLISTMENUITEM mi;
+ TMO_MenuItem mi;
char *strTmp;
CreateServiceFunction("RemovePersonalSettings/RemoveAll",RemoveAllService);
memset(&mi, 0, sizeof(mi));
mi.position = -0x7FFFFFFF;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.a = LPGEN("Remove Personal Settings...");
mi.pszService="RemovePersonalSettings/RemoveAll";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/Restart/src/restart.cpp b/plugins/Restart/src/restart.cpp index b29e34ca9b..f3dd444fcd 100644 --- a/plugins/Restart/src/restart.cpp +++ b/plugins/Restart/src/restart.cpp @@ -46,9 +46,9 @@ extern "C" __declspec(dllexport) int Load(void) hRestartMe = CreateServiceFunction("System/RestartMe", RestartMe);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
- mi.icolibItem = icon.hIcolib;
+ mi.hIcolibItem = icon.hIcolib;
mi.name.a = LPGEN("Restart");
mi.pszService = "System/RestartMe";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/SMS/src/SMS_svc.cpp b/plugins/SMS/src/SMS_svc.cpp index 640a696925..c7a6074922 100644 --- a/plugins/SMS/src/SMS_svc.cpp +++ b/plugins/SMS/src/SMS_svc.cpp @@ -28,16 +28,16 @@ int LoadModules(void) char szServiceFunction[MAX_PATH];
mir_snprintf(szServiceFunction,_countof(szServiceFunction),"%s%s",PROTOCOL_NAMEA,SMS_SEND);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 300050000;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_SMS);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_SMS);
mi.name.t = SMS_SEND_STR;
mi.pszService = szServiceFunction;
mi.flags = CMIF_TCHAR;
Menu_AddMainMenuItem(&mi);
mi.position = -2000070000;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_SMS);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_SMS);
mi.name.t = SMS_SEND_CM_STR;
mi.pszService = szServiceFunction;
mi.flags = CMIF_TCHAR;
diff --git a/plugins/Scriver/src/msgs.cpp b/plugins/Scriver/src/msgs.cpp index 85362d0906..9ef34f2939 100644 --- a/plugins/Scriver/src/msgs.cpp +++ b/plugins/Scriver/src/msgs.cpp @@ -447,14 +447,14 @@ static int OnModulesLoaded(WPARAM, LPARAM) LoadMsgLogIcons();
ModuleLoad(0, 0);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000090000;
mi.flags = CMIF_DEFAULT;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_MESSAGE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_MESSAGE);
mi.name.a = LPGEN("&Message");
mi.pszService = MS_MSG_SENDMESSAGE;
hMsgMenuItem = Menu_AddContactMenuItem(&mi);
- IcoLib_ReleaseIcon((HICON)mi.icolibItem);
+ IcoLib_ReleaseIcon((HICON)mi.hIcolibItem);
HookEvent(ME_SMILEYADD_OPTIONSCHANGED, SmileySettingsChanged);
HookEvent(ME_IEVIEW_OPTIONSCHANGED, SmileySettingsChanged);
diff --git a/plugins/SecureIM/src/main.cpp b/plugins/SecureIM/src/main.cpp index 6d7882de14..0766716cd2 100644 --- a/plugins/SecureIM/src/main.cpp +++ b/plugins/SecureIM/src/main.cpp @@ -38,10 +38,10 @@ BOOL APIENTRY DllMain(HINSTANCE hInst, DWORD dwReason, LPVOID) static HGENMENU MyAddMenuItem(LPCWSTR name, int pos, HICON hicon, LPCSTR service, int flags = 0, WPARAM wParam = 0)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = flags | CMIF_HIDDEN;
mi.position = pos;
- mi.icolibItem = hicon;
+ mi.hIcolibItem = hicon;
mi.name.a = (char*)name;
mi.pszService = (char*)service;
return Menu_AddContactMenuItem(&mi);
@@ -49,11 +49,11 @@ static HGENMENU MyAddMenuItem(LPCWSTR name, int pos, HICON hicon, LPCSTR service static HGENMENU MyAddSubItem(HGENMENU hRoot, LPCSTR name, int pos, int poppos, LPCSTR service, WPARAM wParam = 0)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_HIDDEN;
mi.position = pos;
mi.name.a = (char*)name;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.pszService = (char*)service;
HGENMENU res = Menu_AddContactMenuItem(&mi);
Menu_ConfigureItem(res, MCI_OPT_EXECPARAM, poppos);
diff --git a/plugins/SeenPlugin/src/menu.cpp b/plugins/SeenPlugin/src/menu.cpp index 1bb5192552..aeeb10883c 100644 --- a/plugins/SeenPlugin/src/menu.cpp +++ b/plugins/SeenPlugin/src/menu.cpp @@ -72,7 +72,7 @@ void InitMenuitem() {
CreateServiceFunction("LastSeenUserDetails", MenuitemClicked);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.name.a = LPGEN("Last seen");
mi.pszService = "LastSeenUserDetails";
diff --git a/plugins/SendScreenshotPlus/src/Main.cpp b/plugins/SendScreenshotPlus/src/Main.cpp index 82cb8e4cfa..92d3e2b25c 100644 --- a/plugins/SendScreenshotPlus/src/Main.cpp +++ b/plugins/SendScreenshotPlus/src/Main.cpp @@ -271,9 +271,9 @@ DLL_EXPORT int Load(void) srv_reg(EditBitmap); srv_reg(Send2ImageShack); /// menu items - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.flags = CMIF_TCHAR; - mi.icolibItem = GetIconHandle(ICO_MAINXS); + mi.hIcolibItem = GetIconHandle(ICO_MAINXS); mi.name.t = LPGENT("Take a screenshot"); mi.pszService = MS_SENDSS_OPENDIALOG; diff --git a/plugins/Sessions/Src/Main.cpp b/plugins/Sessions/Src/Main.cpp index a8f130e6e2..8ebfc562ed 100644 --- a/plugins/Sessions/Src/Main.cpp +++ b/plugins/Sessions/Src/Main.cpp @@ -793,28 +793,28 @@ static int PluginInit(WPARAM, LPARAM) Hotkey_Register(&hkd);
// Main menu
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000000000;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Sessions Manager"), 1000000000);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Sessions Manager"), 1000000000);
mi.name.a = LPGEN("Save session...");
- mi.icolibItem = iconList[4].hIcolib;
+ mi.hIcolibItem = iconList[4].hIcolib;
mi.pszService = MS_SESSIONS_SAVEUSERSESSION;
hmSaveCurrentSession = Menu_AddMainMenuItem(&mi);
mi.name.a = LPGEN("Load session...");
mi.pszService = MS_SESSIONS_OPENMANAGER;
- mi.icolibItem = iconList[3].hIcolib;
+ mi.hIcolibItem = iconList[3].hIcolib;
Menu_AddMainMenuItem(&mi);
mi.name.a = LPGEN("Close session");
mi.pszService = MS_SESSIONS_CLOSESESSION;
- mi.icolibItem = 0;
+ mi.hIcolibItem = 0;
Menu_AddMainMenuItem(&mi);
mi.name.a = LPGEN("Load last session");
mi.pszService = MS_SESSIONS_RESTORELASTSESSION;
- mi.icolibItem = iconList[5].hIcolib;
+ mi.hIcolibItem = iconList[5].hIcolib;
mi.position = 10100000;
Menu_AddMainMenuItem(&mi);
return 0;
diff --git a/plugins/SimpleAR/src/Main.cpp b/plugins/SimpleAR/src/Main.cpp index 9e446616bf..8224767e30 100644 --- a/plugins/SimpleAR/src/Main.cpp +++ b/plugins/SimpleAR/src/Main.cpp @@ -265,7 +265,7 @@ extern "C" int __declspec(dllexport)Load(void) CreateServiceFunction(protocolname"/ToggleEnable", ToggleEnable);
CreateServiceFunction(protocolname"/ToggleAutoanswer",Toggle);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500090000;
mi.name.t = _T("");
mi.pszService = protocolname"/ToggleEnable";
diff --git a/plugins/SimpleStatusMsg/src/awaymsg.cpp b/plugins/SimpleStatusMsg/src/awaymsg.cpp index 98a9ca6e50..c01c5a5ea0 100644 --- a/plugins/SimpleStatusMsg/src/awaymsg.cpp +++ b/plugins/SimpleStatusMsg/src/awaymsg.cpp @@ -416,7 +416,7 @@ int LoadAwayMsgModule(void) hWindowList = WindowList_Create();
hWindowList2 = WindowList_Create();
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
CreateServiceFunction(MS_AWAYMSG_SHOWAWAYMSG, GetMessageCommand);
@@ -427,14 +427,14 @@ int LoadAwayMsgModule(void) CreateServiceFunction(MS_SIMPLESTATUSMSG_COPYMSG, CopyAwayMsgCommand);
mi.position = -2000006000;
- mi.icolibItem = GetIconHandle(IDI_COPY);
+ mi.hIcolibItem = GetIconHandle(IDI_COPY);
mi.name.t = LPGENT("Copy Away message");
mi.pszService = MS_SIMPLESTATUSMSG_COPYMSG;
hCopyMsgMenuItem = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(MS_SIMPLESTATUSMSG_GOTOURLMSG, GoToURLMsgCommand);
mi.position = -2000007000;
- mi.icolibItem = GetIconHandle(IDI_GOTOURL);
+ mi.hIcolibItem = GetIconHandle(IDI_GOTOURL);
mi.name.t = LPGENT("&Go to URL in Away message");
mi.pszService = MS_SIMPLESTATUSMSG_GOTOURLMSG;
hGoToURLMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/SimpleStatusMsg/src/main.cpp b/plugins/SimpleStatusMsg/src/main.cpp index e017f3b7ec..d3244f34be 100644 --- a/plugins/SimpleStatusMsg/src/main.cpp +++ b/plugins/SimpleStatusMsg/src/main.cpp @@ -1453,11 +1453,11 @@ static int ChangeStatusMsgPrebuild(WPARAM wParam, LPARAM lParam) if (!iStatusMsgFlags || !iStatusMenuItemCount)
return 0;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
if (!db_get_b(NULL, "SimpleStatusMsg", "ShowStatusMenuItem", 1))
mi.flags |= CMIF_HIDDEN;
- mi.icolibItem = GetIconHandle(IDI_CSMSG);
+ mi.hIcolibItem = GetIconHandle(IDI_CSMSG);
mi.pszService = MS_SIMPLESTATUSMSG_SHOWDIALOGINT;
mi.name.t = LPGENT("Status message...");
mi.position = 2000200000;
@@ -1490,9 +1490,9 @@ static int ChangeStatusMsgPrebuild(WPARAM wParam, LPARAM lParam) if (Proto_IsAccountLocked(pa[i]))
{
mir_sntprintf(szBuffer, TranslateT("%s (locked)"), pa[i]->tszAccountName);
- mi.hParentMenu = Menu_CreateRoot(MO_STATUS, szBuffer, mi.position);
+ mi.root = Menu_CreateRoot(MO_STATUS, szBuffer, mi.position);
}
- else mi.hParentMenu = Menu_CreateRoot(MO_STATUS, pa[i]->tszAccountName, mi.position);
+ else mi.root = Menu_CreateRoot(MO_STATUS, pa[i]->tszAccountName, mi.position);
hProtoStatusMenuItem[i] = Menu_AddStatusMenuItem(&mi);
}
diff --git a/plugins/SmileyAdd/src/main.cpp b/plugins/SmileyAdd/src/main.cpp index 506d4be669..fdbd12442b 100644 --- a/plugins/SmileyAdd/src/main.cpp +++ b/plugins/SmileyAdd/src/main.cpp @@ -50,9 +50,9 @@ static IconItem icon = { LPGEN("Button smiley"), "SmileyAdd_ButtonSmiley", IDI_S static int ModulesLoaded(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 2000070050;
- mi.icolibItem = icon.hIcolib;
+ mi.hIcolibItem = icon.hIcolib;
mi.name.a = LPGEN("Assign smiley category");
hContactMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/SmileyAdd/src/services.cpp b/plugins/SmileyAdd/src/services.cpp index dd3c679bad..f557f55256 100644 --- a/plugins/SmileyAdd/src/services.cpp +++ b/plugins/SmileyAdd/src/services.cpp @@ -292,8 +292,8 @@ int RebuildContactMenu(WPARAM wParam, LPARAM) CMString cat;
opt.ReadContactCategory(wParam, cat);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hContactMenuItem;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hContactMenuItem;
mi.flags = CMIF_TCHAR;
mi.pszService = MS_SMILEYADD_CUSTOMCATMENU;
diff --git a/plugins/StartupSilence/src/main.cpp b/plugins/StartupSilence/src/main.cpp index 442e47617e..864ca1bb5e 100644 --- a/plugins/StartupSilence/src/main.cpp +++ b/plugins/StartupSilence/src/main.cpp @@ -289,9 +289,9 @@ static INT_PTR SilenceConnection(WPARAM wParam, LPARAM lParam) static INT_PTR InitMenu()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 100000000;
- mi.icolibItem = GetIconHandle(MENU_NAME);
+ mi.hIcolibItem = GetIconHandle(MENU_NAME);
mi.name.a = MENU_NAME;
mi.pszService = SS_SERVICE_NAME;
hSSMenuToggleOnOff = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/StatusPlugins/StartupStatus/profiles.cpp b/plugins/StatusPlugins/StartupStatus/profiles.cpp index 2f74d8cbc1..03fd184191 100644 --- a/plugins/StatusPlugins/StartupStatus/profiles.cpp +++ b/plugins/StatusPlugins/StartupStatus/profiles.cpp @@ -92,7 +92,7 @@ static int CreateMainMenuItems(WPARAM, LPARAM) char servicename[128]; int i, count; - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.position = 2000100000; mi.flags = CMIF_TCHAR; mcount = 0; @@ -103,7 +103,7 @@ static int CreateMainMenuItems(WPARAM, LPARAM) continue; if (db_get_b(NULL, MODULENAME, OptName(i, SETTING_INSUBMENU), 1)) - mi.hParentMenu = Menu_CreateRoot(MO_STATUS, LPGENT("Status profiles"), 2000100000); + mi.root = Menu_CreateRoot(MO_STATUS, LPGENT("Status profiles"), 2000100000); mi.name.t = profilename; mi.position = 2000100000 + mcount; diff --git a/plugins/StopSpamMod/src/init.cpp b/plugins/StopSpamMod/src/init.cpp index 4e59ed963e..473a5676ba 100755 --- a/plugins/StopSpamMod/src/init.cpp +++ b/plugins/StopSpamMod/src/init.cpp @@ -148,10 +148,10 @@ extern "C" int __declspec(dllexport) Load() CreateServiceFunction("/RemoveTmp", (MIRANDASERVICE)RemoveTmp);
HookEvent(ME_SYSTEM_MODULESLOADED, OnSystemModulesLoaded);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position=-0x7FFFFFFF;
mi.flags=0;
- mi.icolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem=Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.a=LPGEN("Remove Temporary Contacts");
mi.pszService="/RemoveTmp";
diff --git a/plugins/StopSpamPlus/src/stopspam.cpp b/plugins/StopSpamPlus/src/stopspam.cpp index d36e5f709a..246b3f23cc 100644 --- a/plugins/StopSpamPlus/src/stopspam.cpp +++ b/plugins/StopSpamPlus/src/stopspam.cpp @@ -48,10 +48,10 @@ extern "C" int __declspec(dllexport) Load(void) // Add deliting temporary contacts
hTempRemove = CreateServiceFunction(MS_STOPSPAM_REMTEMPCONTACTS, RemoveTempContacts);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t = LPGENT("Remove Temporary Contacts");
mi.pszService = pluginName"/RemoveTempContacts";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/TabSRMM/src/globals.cpp b/plugins/TabSRMM/src/globals.cpp index 39f7ee160e..d9db30b9d6 100644 --- a/plugins/TabSRMM/src/globals.cpp +++ b/plugins/TabSRMM/src/globals.cpp @@ -135,10 +135,10 @@ void CGlobals::reloadSystemModulesChanged() g_bPopupAvail = ServiceExists(MS_POPUP_ADDPOPUPT) != 0;
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000090000;
mi.flags = CMIF_DEFAULT;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_MESSAGE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_MESSAGE);
mi.name.a = LPGEN("&Message");
mi.pszService = MS_MSG_SENDMESSAGE;
PluginConfig.m_hMenuItem = Menu_AddContactMenuItem(&mi);
@@ -324,16 +324,16 @@ int CGlobals::ModulesLoaded(WPARAM, LPARAM) if (nen_options.bTraySupport)
::CreateSystrayIcon(TRUE);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -500050005;
- mi.icolibItem = PluginConfig.g_iconContainer;
+ mi.hIcolibItem = PluginConfig.g_iconContainer;
mi.name.a = LPGEN("&Messaging settings...");
mi.pszService = MS_TABMSG_SETUSERPREFS;
PluginConfig.m_UserMenuItem = Menu_AddContactMenuItem(&mi);
if (sendLater->isAvail()) {
mi.position = -500050006;
- mi.icolibItem = 0;
+ mi.hIcolibItem = 0;
mi.name.a = LPGEN("&Send later job list...");
mi.pszService = MS_TABMSG_SLQMGR;
PluginConfig.m_UserMenuItem = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/TabSRMM/src/typingnotify.cpp b/plugins/TabSRMM/src/typingnotify.cpp index e64e83ddee..8068bd44c8 100644 --- a/plugins/TabSRMM/src/typingnotify.cpp +++ b/plugins/TabSRMM/src/typingnotify.cpp @@ -536,17 +536,17 @@ int TN_ModuleInit() if (PluginConfig.g_bPopupAvail && ShowMenu) {
hTypingNotify = CreateServiceFunction("TypingNotify/EnableDisableMenuCommand", EnableDisableMenuCommand);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
if (!Disabled) {
mi.name.a = LPGEN("Disable &typing notification");
- mi.icolibItem = LoadIcon(g_hInst, MAKEINTRESOURCE(IDI_ENABLED));
+ mi.hIcolibItem = LoadIcon(g_hInst, MAKEINTRESOURCE(IDI_ENABLED));
}
else {
mi.name.a = LPGEN("Enable &typing notification");
- mi.icolibItem = LoadIcon(g_hInst, MAKEINTRESOURCE(IDI_DISABLED));
+ mi.hIcolibItem = LoadIcon(g_hInst, MAKEINTRESOURCE(IDI_DISABLED));
}
mi.pszService = "TypingNotify/EnableDisableMenuCommand";
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
hDisableMenu = Menu_AddMainMenuItem(&mi);
}
diff --git a/plugins/TrafficCounter/src/TrafficCounter.cpp b/plugins/TrafficCounter/src/TrafficCounter.cpp index a21efb2458..9f54eb7782 100644 --- a/plugins/TrafficCounter/src/TrafficCounter.cpp +++ b/plugins/TrafficCounter/src/TrafficCounter.cpp @@ -1047,10 +1047,10 @@ INT_PTR MenuCommand_TrafficShowHide(WPARAM wParam, LPARAM lParam) void Traffic_AddMainMenuItem(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.flags = 0;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
mi.name.a = LPGEN("Toggle traffic counter");
mi.pszService = "TrafficCounter/ShowHide";
diff --git a/plugins/UserGuide/src/main.cpp b/plugins/UserGuide/src/main.cpp index 45d97293a0..36d8af5a7a 100644 --- a/plugins/UserGuide/src/main.cpp +++ b/plugins/UserGuide/src/main.cpp @@ -84,10 +84,10 @@ extern "C" __declspec(dllexport) int Load(void) mir_getLP(&pluginInfo);
hShowGuide = CreateServiceFunction("UserGuide/ShowGuide", ShowGuideFile);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500000;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_HELP);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_HELP);
mi.name.t = LPGENT("User Guide");
mi.pszService = "UserGuide/ShowGuide";
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/UserInfoEx/src/mir_menuitems.cpp b/plugins/UserInfoEx/src/mir_menuitems.cpp index 4a5d161909..15e464cdb6 100644 --- a/plugins/UserInfoEx/src/mir_menuitems.cpp +++ b/plugins/UserInfoEx/src/mir_menuitems.cpp @@ -85,7 +85,7 @@ void RebuildContact() RemoveMenuItems (hMenuItem, _countof(hMenuItem));
// support new genmenu style
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
switch (flag) {
case 3:
@@ -96,7 +96,7 @@ void RebuildContact() case 5:
//cascade all
mi.position = 1000050000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.name.a = MODULELONGNAME;
mhRoot = Menu_AddContactMenuItem(&mi);
hMenuItem[0] = mhRoot;
@@ -105,7 +105,7 @@ void RebuildContact() case 9:
//cascade Ex/Import
mi.position = 1000050100;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.name.a = LPGEN("Export/import contact");
mhExIm = Menu_AddContactMenuItem(&mi);
hMenuItem[0] = mhExIm;
@@ -117,30 +117,30 @@ void RebuildContact() }
// ContactDetailsPS's menuitem
- mi.hParentMenu = mhRoot;
+ mi.root = mhRoot;
mi.pszService = MS_USERINFO_SHOWDIALOG;
mi.name.a = LPGEN("User &details");
mi.position = 1000050000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
hMenuItem[1] = Menu_AddContactMenuItem(&mi);
Menu_ConfigureItem(hMenuItem[1], MCI_OPT_HOTKEY, MAKELPARAM(VK_F3, MOD_ALT));
// VCard's Ex/Import menuitems
- mi.hParentMenu = mhExIm;
+ mi.root = mhExIm;
// Export
mi.pszService = MS_USERINFO_VCARD_EXPORT;
mi.name.a = mhExIm != NULL ? LPGEN("&Export") : LPGEN("&Export user details");
mi.position = 1000050200;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItem[2] = Menu_AddContactMenuItem(&mi);
// Import
mi.pszService = MS_USERINFO_VCARD_IMPORT;
mi.name.a = mhExIm != NULL ? LPGEN("&Import") : LPGEN("&Import user details");
mi.position = 1000050300;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItem[3] = Menu_AddContactMenuItem(&mi);
}
@@ -172,7 +172,7 @@ void RebuildMain() RemoveMenuItems (hMenuItem, _countof(hMenuItem));
// support new genmenu style
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
switch (flag) {
case 3:
@@ -183,7 +183,7 @@ void RebuildMain() case 5:
//cascade all
mi.position = 500050000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.name.a = MODULELONGNAME;
mhRoot = Menu_AddMainMenuItem(&mi);
hMenuItem[item++] = mhRoot;
@@ -192,7 +192,7 @@ void RebuildMain() case 9:
//cascade Ex/Import
mi.position = 500050000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.name.a = LPGEN("Export/import contact");
mhExIm = Menu_AddMainMenuItem(&mi);
hMenuItem[item++] = mhExIm;
@@ -204,32 +204,32 @@ void RebuildMain() }
// details dialog
- mi.hParentMenu = mhRoot;
+ mi.root = mhRoot;
mi.pszService = MS_USERINFO_SHOWDIALOG;
mi.name.a = LPGEN("View/change my &details...");
mi.position = 500050000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// VCard's Ex/Import menuitems
- mi.hParentMenu = mhExIm;
+ mi.root = mhExIm;
// Export
mi.pszService = MS_USERINFO_VCARD_EXPORTALL;
mi.name.a = LPGEN("Export all contacts");
mi.position = 500150000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// Import
mi.pszService = MS_USERINFO_VCARD_IMPORTALL;
mi.name.a = LPGEN("Import all contacts");
mi.position = 500151000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// reminder
- mi.hParentMenu = mhRoot;
+ mi.root = mhRoot;
const BYTE bRemindMenus =
db_get_b(NULL, MODNAME, SET_REMIND_ENABLED, DEFVAL_REMIND_ENABLED) &&
db_get_b(NULL, MODNAME, SET_REMIND_MENUENABLED, DEFVAL_REMIND_MENUENABLED);
@@ -238,13 +238,13 @@ void RebuildMain() mi.pszService = MS_USERINFO_REMINDER_AGGRASIVEBACKUP;
mi.name.a = LPGEN("Backup birthdays");
mi.position = 500253000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_BDAY_BACKUP);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_BDAY_BACKUP);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// Check anniversaries
mi.pszService = MS_USERINFO_REMINDER_CHECK;
mi.name.a = LPGEN("Check anniversaries");
mi.position = 500251000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_SEARCH);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_SEARCH);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
else {
@@ -256,14 +256,14 @@ void RebuildMain() mi.pszService = MS_USERINFO_REFRESH;
mi.name.a = LPGEN("Refresh contact details");
mi.position = 500254000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_UPDATE);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_UPDATE);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
// anniversary list
mi.pszService = MS_USERINFO_REMINDER_LIST;
mi.name.a = LPGEN("Anniversary list");
mi.position = 500252000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_ANNIVERSARY);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_ANNIVERSARY);
hMenuItem[item++] = Menu_AddMainMenuItem(&mi);
}
@@ -300,7 +300,7 @@ void RebuildGroup() char text[200];
mir_strcpy(text, "UserInfo");
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = text;
char* tDest = text + mir_strlen(text);
@@ -314,7 +314,7 @@ void RebuildGroup() case 5:
//cascade all
mi.position = 250000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.name.a = MODULELONGNAME;
mhRoot = Menu_AddGroupMenuItem(0, &mi);
hMenuItem[item++] = mhRoot;
@@ -323,7 +323,7 @@ void RebuildGroup() case 9:
//cascade Ex/Import
mi.position = 250100;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.name.a = LPGEN("Export/import contact");
mhExIm = Menu_AddGroupMenuItem(0, &mi);
hMenuItem[item++] = mhExIm;
@@ -335,20 +335,20 @@ void RebuildGroup() }
// VCard's Ex/Import menuitems
- mi.hParentMenu = mhExIm;
+ mi.root = mhExIm;
// Export
mi.pszService = MS_USERINFO_VCARD_EXPORTALL;
mi.name.a = LPGEN("Export all contacts");
mi.position = 250200;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItem[item++] = Menu_AddGroupMenuItem(0, &mi);
// Import
mi.pszService = MS_USERINFO_VCARD_IMPORTALL;
mi.name.a = LPGEN("Import all contacts");
mi.position = 250300;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItem[item++] = Menu_AddGroupMenuItem(0, &mi);
}
@@ -389,7 +389,7 @@ void RebuildSubGroup() char text[200];
mir_strcpy(text, "UserInfo");
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = text;
char* tDest = text + mir_strlen(text);
@@ -402,7 +402,7 @@ void RebuildSubGroup() case 5:
//cascade all
mi.position = 1050000;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.name.a = MODULELONGNAME;
mhRoot = Menu_AddSubGroupMenuItem(0, &mi);
hMenuItem[item++] = mhRoot;
@@ -411,7 +411,7 @@ void RebuildSubGroup() case 9:
//cascade Ex/Import
mi.position = 1050100;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.name.a = LPGEN("Export/import group");
mhExIm = Menu_AddSubGroupMenuItem(0, &mi);
hMenuItem[item++] = mhExIm;
@@ -423,14 +423,14 @@ void RebuildSubGroup() }
// VCard's Ex/Import menuitems
- mi.hParentMenu = mhExIm;
+ mi.root = mhExIm;
// Export
mir_strcpy(tDest, "/ExportGroup"); //mi.pszService
if (!ServiceExists(mi.pszService)) CreateServiceFunction(mi.pszService, svcExIm_Group_Service);
mi.name.a = mhExIm != NULL ? LPGEN("&Export") : LPGEN("&Export group");
mi.position = 1050200;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
gmp.lParam=0;
gmp.wParam=TRUE;
hMenuItem[item++] = Menu_AddSubGroupMenuItem(&gmp, &mi);
@@ -440,7 +440,7 @@ void RebuildSubGroup() if (!ServiceExists(mi.pszService)) CreateServiceFunction(mi.pszService, svcExIm_Group_Service);
mi.name.a = mhExIm != NULL ? LPGEN("&Import") : LPGEN("&Import group");
mi.position = 1050300;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
gmp.lParam=0;
gmp.wParam=FALSE;
hMenuItem[item++] = Menu_AddSubGroupMenuItem(&gmp, &mi);
@@ -502,12 +502,12 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam) char text[ 200 ];
mir_strcpy(text, pcli->menuProtos[i].szProto);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = text;
char* tDest = text + mir_strlen( text );
// support new genmenu style
- mi.hParentMenu = mhRoot;
+ mi.root = mhRoot;
switch (flag) {
case 3:
@@ -520,7 +520,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam) case 5:
// cascade all
mi.position = 50100;
- mi.icolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_COMMON_MAIN);
mi.name.a = MODULELONGNAME;
hMenuItemAccount[mItems*i + item] = Menu_AddStatusMenuItem(&mi);
mhRoot = hMenuItemAccount[mItems*i + item++];
@@ -529,7 +529,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam) case 9:
// cascade Ex/Import
mi.position = 50100;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXIMPORT);
mi.name.a = LPGEN("Export/import");
hMenuItemAccount[mItems*i + item] = Menu_AddStatusMenuItem(&mi);
mhRoot = hMenuItemAccount[mItems*i + item++];
@@ -541,14 +541,14 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam) }
// VCard's Ex/Import menuitems
- mi.hParentMenu = mhExIm;
+ mi.root = mhExIm;
// Export
mir_strcpy(tDest, "/ExportAccount");
CreateServiceFunction(mi.pszService, svcExIm_Account_Service);
mi.name.a = LPGEN("&Export xml");
mi.position = 50200;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EXPORT);
hMenuItemAccount[mItems*i + item++] = Menu_AddStatusMenuItem(&mi);
// Import
@@ -556,7 +556,7 @@ INT_PTR RebuildAccount(WPARAM wParam, LPARAM lParam) CreateServiceFunction(mi.pszService, svcExIm_Account_Service);
mi.name.a = LPGEN("&Import xml");
mi.position = 50300;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_IMPORT);
hMenuItemAccount[mItems*i + item++] = Menu_AddStatusMenuItem(&mi);
}
return 0;
diff --git a/plugins/UserInfoEx/src/svc_email.cpp b/plugins/UserInfoEx/src/svc_email.cpp index 91a2515650..e431bf84bb 100644 --- a/plugins/UserInfoEx/src/svc_email.cpp +++ b/plugins/UserInfoEx/src/svc_email.cpp @@ -183,9 +183,9 @@ void SvcEMailRebuildMenu() if (!ghMenuItem) {
// insert contact menuitem
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000010000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_EMAIL);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_EMAIL);
mi.name.a = "&E-mail";
mi.pszService = MS_EMAIL_SENDEMAIL;
ghMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/UserInfoEx/src/svc_homepage.cpp b/plugins/UserInfoEx/src/svc_homepage.cpp index 0e47f1e8bd..e0a2f9e01b 100644 --- a/plugins/UserInfoEx/src/svc_homepage.cpp +++ b/plugins/UserInfoEx/src/svc_homepage.cpp @@ -153,9 +153,9 @@ void SvcHomepageRebuildMenu() if (!ghMenuItem) {
// insert contact menuitem
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000010000;
- mi.icolibItem = IcoLib_GetIcon(ICO_BTN_GOTO);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_BTN_GOTO);
mi.name.a = LPGEN("&Homepage");
mi.pszService = MS_USERINFO_HOMEPAGE_OPENURL;
ghMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/Watrack/i_gui.inc b/plugins/Watrack/i_gui.inc index 2f2f249c14..3e41d6e6e9 100644 --- a/plugins/Watrack/i_gui.inc +++ b/plugins/Watrack/i_gui.inc @@ -27,11 +27,10 @@ end; procedure CreateMenus;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
begin
FillChar(mi, sizeof(mi), 0);
- mi.hParentMenu:=Menu_CreateRoot(MO_MAIN, 'Watrack', 0, 0, 0);
-
+ mi.root :=Menu_CreateRoot(MO_MAIN, 'Watrack', 0, 0, 0);
mi.hIcon :=IcoLib_GetIcon(IcoBtnEnable,0);
mi.szName.a :='Disable WATrack';
mi.pszService:=MS_WAT_PLUGINSTATUS;
diff --git a/plugins/Watrack/lastfm/lastfm.pas b/plugins/Watrack/lastfm/lastfm.pas index 8cb51a855c..def0009b08 100644 --- a/plugins/Watrack/lastfm/lastfm.pas +++ b/plugins/Watrack/lastfm/lastfm.pas @@ -166,7 +166,7 @@ end; procedure CreateMenus;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
sid:TSKINICONDESC;
begin
FillChar(sid,SizeOf(TSKINICONDESC),0);
@@ -181,8 +181,7 @@ begin DestroyIcon(sid.hDefaultIcon);
FillChar(mi, sizeof(mi), 0);
- mi.hParentMenu:=Menu_CreateRoot(MO_MAIN, 'Watrack', 500050000, 0, 0);
-
+ mi.root :=Menu_CreateRoot(MO_MAIN, 'Watrack', 500050000, 0, 0);
mi.hIcon :=IcoLib_GetIcon(IcoLastFM,0);
mi.szName.a :='Disable scrobbling';
mi.pszService:=MS_WAT_LASTFM;
diff --git a/plugins/Watrack/myshows/myshows.pas b/plugins/Watrack/myshows/myshows.pas index 054d9a6010..28f8398cd3 100644 --- a/plugins/Watrack/myshows/myshows.pas +++ b/plugins/Watrack/myshows/myshows.pas @@ -197,7 +197,7 @@ end; procedure CreateMenus;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
sid:TSKINICONDESC;
begin
FillChar(sid,SizeOf(TSKINICONDESC),0);
@@ -212,8 +212,7 @@ begin DestroyIcon(sid.hDefaultIcon);
FillChar(mi, sizeof(mi), 0);
- mi.hParentMenu:=Menu_CreateRoot(MO_MAIN, 'Watrack', 500050000, 0, 0);
-
+ mi.root :=Menu_CreateRoot(MO_MAIN, 'Watrack', 500050000, 0, 0);
mi.hIcon :=IcoLib_GetIcon(IcoMyShows,0);
mi.szName.a :='Disable scrobbling';
mi.pszService:=MS_WAT_MYSHOWS;
diff --git a/plugins/Watrack/popup/popups.pas b/plugins/Watrack/popup/popups.pas index fb6f9d1b53..4e1b041682 100644 --- a/plugins/Watrack/popup/popups.pas +++ b/plugins/Watrack/popup/popups.pas @@ -443,7 +443,7 @@ end; function InitProc(aGetStatus:boolean=false):integer;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
sid:TSKINICONDESC;
begin
if aGetStatus then
@@ -472,7 +472,7 @@ begin HookEvent(ME_SKIN2_ICONSCHANGED,@IconChanged);
FillChar(mi,SizeOf(mi),0);
- mi.hParentMenu:=Menu_CreateRoot(MO_MAIN, 'Watrack', MenuInfoPos, 0, 0);
+ mi.root :=Menu_CreateRoot(MO_MAIN, 'Watrack', MenuInfoPos, 0, 0);
mi.hIcon :=IcoLib_GetIcon(IcoBtnInfo,0);
mi.szName.a :='Music Info';
mi.pszService:=MS_WAT_SHOWMUSICINFO;
diff --git a/plugins/Watrack/proto/proto.pas b/plugins/Watrack/proto/proto.pas index 25408aeba0..c3d993f0ce 100644 --- a/plugins/Watrack/proto/proto.pas +++ b/plugins/Watrack/proto/proto.pas @@ -336,7 +336,7 @@ end; function InitProc(aGetStatus:boolean=false):integer;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
begin
if aGetStatus then
begin
@@ -354,7 +354,7 @@ begin RegisterIcons;
FillChar(mi, sizeof(mi), 0);
- mi.hParentMenu:=Menu_CreateRoot(MO_MAIN, 'Watrack', 0, 0, 0);
+ mi.root :=Menu_CreateRoot(MO_MAIN, 'Watrack', 0, 0, 0);
mi.flags :=CMIF_NOTOFFLINE or CMIF_NOTOFFLIST;
mi.hIcon :=IcoLib_GetIcon(IcoBtnContext,0);
mi.szName.a :='Get user''s Music Info';
diff --git a/plugins/Watrack/stat/statlog.pas b/plugins/Watrack/stat/statlog.pas index fe5418017f..ffa1626ac0 100644 --- a/plugins/Watrack/stat/statlog.pas +++ b/plugins/Watrack/stat/statlog.pas @@ -551,7 +551,7 @@ end; function InitProc(aGetStatus:boolean=false):integer;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
sid:TSKINICONDESC;
begin
if aGetStatus then
@@ -582,7 +582,7 @@ begin DestroyIcon(sid.hDefaultIcon);
FillChar(mi, sizeof(mi), 0);
- mi.hParentMenu:=Menu_CreateRoot(MO_MAIN, 'Watrack', MenuReportPos, 0, 0);
+ mi.root :=Menu_CreateRoot(MO_MAIN, 'Watrack', MenuReportPos, 0, 0);
mi.hIcon :=IcoLib_GetIcon(IcoBtnReport,0);
mi.szName.a :='Create WATrack report';
mi.pszService:=MS_WAT_MAKEREPORT;
diff --git a/plugins/Weather/src/weather_svcs.cpp b/plugins/Weather/src/weather_svcs.cpp index 4095dd9522..46ea0ce783 100644 --- a/plugins/Weather/src/weather_svcs.cpp +++ b/plugins/Weather/src/weather_svcs.cpp @@ -268,64 +268,64 @@ INT_PTR MenuitemNotifyCmd(WPARAM wParam,LPARAM lParam) // copied and modified form "modified MSN Protocol"
void AddMenuItems(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
// contact menu
CreateServiceFunction(MS_WEATHER_UPDATE, UpdateSingleStation);
mi.position = -0x7FFFFFFA;
- mi.icolibItem = GetIconHandle("update");
+ mi.hIcolibItem = GetIconHandle("update");
mi.name.a = LPGEN("Update Weather");
mi.pszService = MS_WEATHER_UPDATE;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
CreateServiceFunction(MS_WEATHER_REFRESH, UpdateSingleRemove);
mi.position = -0x7FFFFFF9;
- mi.icolibItem = GetIconHandle("update2");
+ mi.hIcolibItem = GetIconHandle("update2");
mi.name.a = LPGEN("Remove Old Data then Update");
mi.pszService = MS_WEATHER_REFRESH;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
CreateServiceFunction(MS_WEATHER_BRIEF, BriefInfoSvc);
mi.position = -0x7FFFFFF8;
- mi.icolibItem = GetIconHandle("brief");
+ mi.hIcolibItem = GetIconHandle("brief");
mi.name.a = LPGEN("Brief Information");
mi.pszService = MS_WEATHER_BRIEF;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
CreateServiceFunction(MS_WEATHER_COMPLETE, LoadForecast);
mi.position = -0x7FFFFFF7;
- mi.icolibItem = GetIconHandle("read");
+ mi.hIcolibItem = GetIconHandle("read");
mi.name.a = LPGEN("Read Complete Forecast");
mi.pszService = MS_WEATHER_COMPLETE;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
CreateServiceFunction(MS_WEATHER_MAP, WeatherMap);
mi.position = -0x7FFFFFF6;
- mi.icolibItem = GetIconHandle("map");
+ mi.hIcolibItem = GetIconHandle("map");
mi.name.a = LPGEN("Weather Map");
mi.pszService = MS_WEATHER_MAP;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
CreateServiceFunction(MS_WEATHER_LOG, ViewLog);
mi.position = -0x7FFFFFF5;
- mi.icolibItem = GetIconHandle("log");
+ mi.hIcolibItem = GetIconHandle("log");
mi.name.a = LPGEN("View Log");
mi.pszService = MS_WEATHER_LOG;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
CreateServiceFunction(MS_WEATHER_EDIT, EditSettings);
mi.position = -0x7FFFFFF4;
- mi.icolibItem = GetIconHandle("edit");
+ mi.hIcolibItem = GetIconHandle("edit");
mi.name.a = LPGEN("Edit Settings");
mi.pszService = MS_WEATHER_EDIT;
Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
// adding main menu items
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Weather"), 500099000);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Weather"), 500099000);
CreateServiceFunction(MS_WEATHER_ENABLED, EnableDisableCmd);
mi.name.a = LPGEN("Enable/Disable Weather Update");
- mi.icolibItem = GetIconHandle("main");
+ mi.hIcolibItem = GetIconHandle("main");
mi.position = 10100001;
mi.pszService = MS_WEATHER_ENABLED;
hEnableDisableMenu = Menu_AddMainMenuItem(&mi);
@@ -333,14 +333,14 @@ void AddMenuItems(void) CreateServiceFunction(MS_WEATHER_UPDATEALL, UpdateAllInfo);
mi.position = 20100001;
- mi.icolibItem = GetIconHandle("update");
+ mi.hIcolibItem = GetIconHandle("update");
mi.name.a = LPGEN("Update All Weather");
mi.pszService = MS_WEATHER_UPDATEALL;
Menu_AddMainMenuItem(&mi);
CreateServiceFunction(MS_WEATHER_REFRESHALL, UpdateAllRemove);
mi.position = 20100002;
- mi.icolibItem = GetIconHandle("update2");
+ mi.hIcolibItem = GetIconHandle("update2");
mi.name.a = LPGEN("Remove Old Data then Update All");
mi.pszService = MS_WEATHER_REFRESHALL;
Menu_AddMainMenuItem(&mi);
@@ -349,9 +349,9 @@ void AddMenuItems(void) if (ServiceExists(MS_POPUP_ADDPOPUPT)) {
CreateServiceFunction(WEATHERPROTONAME "/PopupMenu", MenuitemNotifyCmd);
mi.name.a = LPGEN("Weather Notification");
- mi.icolibItem = GetIconHandle("popup");
+ mi.hIcolibItem = GetIconHandle("popup");
mi.position = 0;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 0);
mi.pszService = WEATHERPROTONAME "/PopupMenu";
hEnableDisablePopupMenu = Menu_AddMainMenuItem(&mi);
UpdatePopupMenu(opt.UsePopup);
@@ -361,8 +361,8 @@ void AddMenuItems(void) mi.pszService = "Weather/mwin_menu";
CreateServiceFunction(mi.pszService, Mwin_MenuClicked);
mi.position = -0x7FFFFFF0;
- mi.icolibItem = NULL;
- mi.hParentMenu = NULL;
+ mi.hIcolibItem = NULL;
+ mi.root = NULL;
mi.name.a = LPGEN("Display in a frame");
hMwinMenu = Menu_AddContactMenuItem(&mi, WEATHERPROTONAME);
}
diff --git a/plugins/WebView/src/main.cpp b/plugins/WebView/src/main.cpp index b3367ff3d8..8f035e4ea3 100644 --- a/plugins/WebView/src/main.cpp +++ b/plugins/WebView/src/main.cpp @@ -169,7 +169,7 @@ extern "C" int __declspec(dllexport) Load() //value is 1 if menu is disabled
db_set_b(NULL, MODULENAME, MENU_IS_DISABLED_KEY, 1);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
if ( db_get_b(NULL, MODULENAME, MENU_OFF, 0)) {
//value is 0 if menu is enabled
@@ -178,8 +178,8 @@ extern "C" int __declspec(dllexport) Load() /*DISABLE WEBVIEW*/
CreateServiceFunction("DisableWebview", AutoUpdateMCmd);
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, _T(MODULENAME), 20200001);
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_SITE));
+ mi.root = Menu_CreateRoot(MO_MAIN, _T(MODULENAME), 20200001);
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_SITE));
if (db_get_b(NULL, MODULENAME, DISABLE_AUTOUPDATE_KEY, 0))
mi.name.t = LPGENT("Auto update disabled");
else
@@ -191,7 +191,7 @@ extern "C" int __declspec(dllexport) Load() // Update all webview contacts
CreateServiceFunction("UpdateAll", UpdateAllMenuCommand);
mi.position = 500090002;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_UPDATEALL));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_UPDATEALL));
mi.name.t = LPGENT("Update all Webview sites");
mi.pszService = "UpdateAll";
Menu_AddMainMenuItem(&mi);
@@ -199,7 +199,7 @@ extern "C" int __declspec(dllexport) Load() // Mark All Webview Sites As Read
CreateServiceFunction("MarkAllSitesRead", MarkAllReadMenuCommand);
mi.position = 500090099;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_MARKALLREAD));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_MARKALLREAD));
mi.name.t = LPGENT("Mark all Webview sites as read");
mi.pszService = "MarkAllSitesRead";
Menu_AddMainMenuItem(&mi);
@@ -207,7 +207,7 @@ extern "C" int __declspec(dllexport) Load() // open cache directory
CreateServiceFunction("OpenCacheFolder", OpenCacheDir);
mi.position = 500090099;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_FOLDER));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_FOLDER));
mi.name.t = LPGENT("Open cache folder");
mi.pszService = "OpenCacheFolder";
Menu_AddMainMenuItem(&mi);
@@ -218,7 +218,7 @@ extern "C" int __declspec(dllexport) Load() TCHAR countername[100];
mir_sntprintf(countername, _countof(countername), TranslateT("%d minutes to update"), db_get_dw(NULL, MODULENAME, COUNTDOWN_KEY, 0));
mi.position = 600090099;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_UPDATEALL));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_UPDATEALL));
mi.name.t = countername;
mi.pszService = "Countdown";
hMenuItemCountdown = Menu_AddMainMenuItem(&mi);
@@ -229,44 +229,44 @@ extern "C" int __declspec(dllexport) Load() CreateServiceFunction("Open web page", WebsiteMenuCommand);
mi.position = 100;
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_URL));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_URL));
mi.pszService = "Open web page";
mi.name.t = LPGENT("Open web page");
Menu_AddContactMenuItem(&mi, MODULENAME);
CreateServiceFunction("OpenClose Window", DataWndMenuCommand);
mi.pszService = "OpenClose Window";
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_SHOW_HIDE));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_SHOW_HIDE));
mi.name.t = LPGENT("Open/Close window");
Menu_AddContactMenuItem(&mi, MODULENAME);
mi.position = 2222220;
mi.pszService = "UpdateData";
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_UPDATE));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_UPDATE));
mi.name.t = LPGENT("Update data");
Menu_AddContactMenuItem(&mi, MODULENAME);
CreateServiceFunction("ContactOptions", CntOptionsMenuCommand);
mi.pszService = "ContactOptions";
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_OPTIONS));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_OPTIONS));
mi.name.t = LPGENT("Contact options");
Menu_AddContactMenuItem(&mi, MODULENAME);
CreateServiceFunction("ContactAlertOpts", CntAlertMenuCommand);
mi.pszService = "ContactAlertOpts";
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ALERT));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_ALERT));
mi.name.t = LPGENT("Contact alert options");
Menu_AddContactMenuItem(&mi, MODULENAME);
CreateServiceFunction("PingWebsite", PingWebsiteMenuCommand);
mi.pszService = "PingWebsite";
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_PING));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_PING));
mi.name.t = LPGENT("Ping web site");
Menu_AddContactMenuItem(&mi, MODULENAME);
CreateServiceFunction("StopDataProcessing", StpPrcssMenuCommand);
mi.pszService = "StopDataProcessing";
- mi.icolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_STOP));
+ mi.hIcolibItem = LoadIcon(hInst, MAKEINTRESOURCE(IDI_STOP));
mi.name.t = LPGENT("Stop data processing");
Menu_AddContactMenuItem(&mi, MODULENAME);
diff --git a/plugins/WhenWasIt/src/WhenWasIt.cpp b/plugins/WhenWasIt/src/WhenWasIt.cpp index d2c224f0c8..0f629bad44 100644 --- a/plugins/WhenWasIt/src/WhenWasIt.cpp +++ b/plugins/WhenWasIt/src/WhenWasIt.cpp @@ -72,41 +72,41 @@ extern "C" int __declspec(dllexport) Load(void) hAddBirthdayWndsList = WindowList_Create();
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 10000000;
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Birthdays (When Was It)"), mi.position);
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Birthdays (When Was It)"), mi.position);
mi.pszService = MS_WWI_CHECK_BIRTHDAYS;
- mi.icolibItem = hCheckMenu;
+ mi.hIcolibItem = hCheckMenu;
mi.name.a = LPGEN("Check for birthdays");
Menu_AddMainMenuItem(&mi);
mi.pszService = MS_WWI_LIST_SHOW;
mi.name.a = LPGEN("Birthday list");
- mi.icolibItem = hListMenu;
+ mi.hIcolibItem = hListMenu;
Menu_AddMainMenuItem(&mi);
mi.pszService = MS_WWI_REFRESH_USERDETAILS;
mi.position = 10100000;
mi.name.a = LPGEN("Refresh user details");
- mi.icolibItem = hRefreshUserDetails;
+ mi.hIcolibItem = hRefreshUserDetails;
Menu_AddMainMenuItem(&mi);
mi.pszService = MS_WWI_IMPORT_BIRTHDAYS;
mi.position = 10200000;
mi.name.a = LPGEN("Import birthdays");
- mi.icolibItem = hImportBirthdays;
+ mi.hIcolibItem = hImportBirthdays;
Menu_AddMainMenuItem(&mi);
mi.pszService = MS_WWI_EXPORT_BIRTHDAYS;
mi.name.a = LPGEN("Export birthdays");
- mi.icolibItem = hExportBirthdays;
+ mi.hIcolibItem = hExportBirthdays;
Menu_AddMainMenuItem(&mi);
- mi.hParentMenu = 0;
+ mi.root = 0;
mi.pszService = MS_WWI_ADD_BIRTHDAY;
mi.position = 10000000;
- mi.icolibItem = hAddBirthdayContact;
+ mi.hIcolibItem = hAddBirthdayContact;
mi.name.a = LPGEN("Add/change user &birthday");
Menu_AddContactMenuItem(&mi);
diff --git a/plugins/WhoUsesMyFiles/src/wumfplug.cpp b/plugins/WhoUsesMyFiles/src/wumfplug.cpp index c7e697f5f1..df611cb989 100644 --- a/plugins/WhoUsesMyFiles/src/wumfplug.cpp +++ b/plugins/WhoUsesMyFiles/src/wumfplug.cpp @@ -492,22 +492,22 @@ extern "C" __declspec(dllexport) int Load(void) CreateServiceFunction(MS_WUMF_SWITCHPOPUP, WumfMenuCommand);
CreateServiceFunction(MS_WUMF_CONNECTIONSSHOW, WumfShowConnections);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 1999990000);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 1999990000);
if (WumfOptions.PopupsEnabled == FALSE) {
mi.name.a = LPGEN("Enable WUMF popups");
- mi.icolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_NOPOPUP));
+ mi.hIcolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_NOPOPUP));
}
else {
mi.name.a = LPGEN("Disable WUMF popups");
- mi.icolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_POPUP));
+ mi.hIcolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_POPUP));
}
mi.pszService = MS_WUMF_SWITCHPOPUP;
hMenuItem = Menu_AddMainMenuItem(&mi);
mi.name.a = LPGEN("WUMF: Show connections");
- mi.icolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_DRIVE));
+ mi.hIcolibItem = LoadIcon(hInst,MAKEINTRESOURCE(IDI_DRIVE));
mi.pszService = MS_WUMF_CONNECTIONSSHOW;
Menu_AddMainMenuItem(&mi);
diff --git a/plugins/XSoundNotify/src/xsn_main.cpp b/plugins/XSoundNotify/src/xsn_main.cpp index fb46121077..51a06b95a3 100644 --- a/plugins/XSoundNotify/src/xsn_main.cpp +++ b/plugins/XSoundNotify/src/xsn_main.cpp @@ -176,10 +176,10 @@ static int OnLoadInit(WPARAM, LPARAM) {
mir_getCI(NULL);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_LoadIcon(SKINICON_OTHER_MIRANDA);
mi.name.t = LPGENT("Custom contact sound");
mi.pszService = "XSoundNotify/ContactMenuCommand";
hChangeSound = Menu_AddContactMenuItem(&mi);
diff --git a/plugins/YAMN/src/main.cpp b/plugins/YAMN/src/main.cpp index c657a7a5ce..ab5ba36e86 100644 --- a/plugins/YAMN/src/main.cpp +++ b/plugins/YAMN/src/main.cpp @@ -141,9 +141,9 @@ void CheckMenuItems() int SystemModulesLoaded(WPARAM, LPARAM) { //Insert "Check mail (YAMN)" item to Miranda's menu - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.position = 0xb0000000; - mi.icolibItem = g_GetIconHandle(0); + mi.hIcolibItem = g_GetIconHandle(0); mi.name.a = LPGEN("Check &mail (All Account)"); mi.pszService = MS_YAMN_FORCECHECK; hMenuItemMain = Menu_AddMainMenuItem(&mi); @@ -152,7 +152,7 @@ int SystemModulesLoaded(WPARAM, LPARAM) mi.pszService = MS_YAMN_CLISTCONTEXT; hMenuItemCont = Menu_AddContactMenuItem(&mi, YAMN_DBMODULE); - mi.icolibItem = g_GetIconHandle(1); + mi.hIcolibItem = g_GetIconHandle(1); mi.name.a = LPGEN("Launch application"); mi.pszService = MS_YAMN_CLISTCONTEXTAPP; hMenuItemContApp = Menu_AddContactMenuItem(&mi, YAMN_DBMODULE); diff --git a/plugins/YAPP/src/yapp.cpp b/plugins/YAPP/src/yapp.cpp index f51ce242cf..cd3f8ab1de 100644 --- a/plugins/YAPP/src/yapp.cpp +++ b/plugins/YAPP/src/yapp.cpp @@ -170,16 +170,16 @@ void InitMenuItems(void) hMenuRoot = Menu_CreateRoot(MO_MAIN, LPGENT("Popups"), 500010000, IcoLib_GetIcon(isEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0));
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = hMenuRoot;
+ mi.root = hMenuRoot;
- mi.icolibItem = IcoLib_GetIcon(ICO_HISTORY, 0);
+ mi.hIcolibItem = IcoLib_GetIcon(ICO_HISTORY, 0);
mi.pszService= MS_POPUP_SHOWHISTORY;
mi.name.t = LPGENT("Popup History");
hMenuItemHistory = Menu_AddMainMenuItem(&mi);
- mi.icolibItem = IcoLib_GetIcon(isEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
+ mi.hIcolibItem = IcoLib_GetIcon(isEnabled ? ICO_POPUP_ON : ICO_POPUP_OFF, 0);
mi.pszService = "Popup/EnableDisableMenuCommand";
mi.name.t = (isEnabled ? LPGENT("Disable Popups") : LPGENT("Enable Popups"));
hMenuItem = Menu_AddMainMenuItem(&mi);
diff --git a/plugins/ZeroNotification/src/main.cpp b/plugins/ZeroNotification/src/main.cpp index 6e82bd43c8..9d07895dcb 100644 --- a/plugins/ZeroNotification/src/main.cpp +++ b/plugins/ZeroNotification/src/main.cpp @@ -234,7 +234,7 @@ extern "C" __declspec(dllexport) int Load(void) if (!db_get_b(NULL, MODNAME, "HideMenu", 1)) {
hSoundMenu = CreateServiceFunction(MODNAME "/MenuCommand", NoSoundMenuCommand);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -0x7FFFFFFF;
mi.flags = CMIF_TCHAR;
UpdateMenuItem();
diff --git a/plugins/mRadio/i_tray.inc b/plugins/mRadio/i_tray.inc index 5312e6b26b..7784e42e1f 100644 --- a/plugins/mRadio/i_tray.inc +++ b/plugins/mRadio/i_tray.inc @@ -41,7 +41,7 @@ var srch:tTrayRadioStation;
pc:pAnsiChar;
buf:array [0..63] of AnsiChar;
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
begin
trayStations.sortFunc:=@MyStrSort;
@@ -91,7 +91,7 @@ begin // build menu from sorted list
FillChar(mi,SizeOf(mi),0);
mi.Flags :=CMIF_KEEPUNTRANSLATED or CMIF_UNICODE;
- mi.hParentMenu:=trayparent;
+ mi.root:=trayparent;
pc:=StrCopyE(@buf,'mRadio/Choose');
for i:=0 to trayStations.realCount-1 do
begin
@@ -132,7 +132,7 @@ end; procedure CreateTrayMenu;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
playstr:pWideChar;
ico:pAnsiChar;
begin
@@ -146,7 +146,7 @@ begin trayradioparent:=Menu_AddMainMenuItem(@mi);
FillChar(mi, sizeof(mi), 0);
- mi.hParentMenu:=trayradioparent;
+ mi.root:=trayradioparent;
if PluginStatus=ID_STATUS_ONLINE then
begin
diff --git a/plugins/mRadio/i_visual.inc b/plugins/mRadio/i_visual.inc index 6495962d9d..768412d7ef 100644 --- a/plugins/mRadio/i_visual.inc +++ b/plugins/mRadio/i_visual.inc @@ -30,7 +30,7 @@ end; procedure CreateMenu;
var
- mi:TCListMenuItem;
+ mi:TMO_MenuItem;
begin
FillChar(mi, sizeof(mi), 0);
mi.pszService:=MS_RADIO_RECORD;
diff --git a/protocols/AimOscar/src/theme.cpp b/protocols/AimOscar/src/theme.cpp index 321630221c..7a36990d79 100644 --- a/protocols/AimOscar/src/theme.cpp +++ b/protocols/AimOscar/src/theme.cpp @@ -211,9 +211,9 @@ void CAimProto::InitMainMenus(void) {
HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = GetIconHandle("aim");
+ mi.hIcolibItem = GetIconHandle("aim");
mi.name.t = m_tszUserName;
mi.position = 500090000;
hRoot = hMenuRoot = Menu_AddProtoMenuItem(&mi);
@@ -225,39 +225,39 @@ void CAimProto::InitMainMenus(void) }
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hRoot;
mi.pszService = "/ManageAccount";
CreateProtoService(mi.pszService, &CAimProto::ManageAccount);
mi.position = 201001;
- mi.icolibItem = GetIconHandle("aim");
+ mi.hIcolibItem = GetIconHandle("aim");
mi.name.a = LPGEN("Manage Account");
hMainMenu[0] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/InstantIdle";
CreateProtoService(mi.pszService, &CAimProto::InstantIdle);
mi.position = 201002;
- mi.icolibItem = GetIconHandle("idle");
+ mi.hIcolibItem = GetIconHandle("idle");
mi.name.a = LPGEN("Instant Idle");
hMainMenu[1] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/JoinChatRoom";
CreateProtoService(mi.pszService, &CAimProto::JoinChatUI);
mi.position = 201003;
- mi.icolibItem = GetIconHandle("aol");
+ mi.hIcolibItem = GetIconHandle("aol");
mi.name.a = LPGEN( "Join Chat Room" );
hMainMenu[2] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
}
void CAimProto::InitContactMenus(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
CreateProtoService("/GetHTMLAwayMsg",&CAimProto::GetHTMLAwayMsg);
mi.pszService = "/GetHTMLAwayMsg";
mi.position = -2000006000;
- mi.icolibItem = GetIconHandle("away");
+ mi.hIcolibItem = GetIconHandle("away");
mi.name.a = LPGEN("Read &HTML Away Message");
mi.flags = CMIF_NOTOFFLINE | CMIF_HIDDEN;
hHTMLAwayContextMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
@@ -265,7 +265,7 @@ void CAimProto::InitContactMenus(void) CreateProtoService("/GetProfile", &CAimProto::GetProfile);
mi.pszService = "/GetProfile";
mi.position = -2000005090;
- mi.icolibItem = GetIconHandle("profile");
+ mi.hIcolibItem = GetIconHandle("profile");
mi.name.a = LPGEN("Read Profile");
mi.flags = CMIF_NOTOFFLINE;
Menu_AddContactMenuItem(&mi, m_szModuleName);
@@ -273,7 +273,7 @@ void CAimProto::InitContactMenus(void) CreateProtoService("/AddToServerList", &CAimProto::AddToServerList);
mi.pszService = "/AddToServerList";
mi.position = -2000005080;
- mi.icolibItem = GetIconHandle("add");
+ mi.hIcolibItem = GetIconHandle("add");
mi.name.a = LPGEN("Add To Server List");
mi.flags = CMIF_NOTONLINE | CMIF_HIDDEN;
hAddToServerListContextMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
@@ -281,7 +281,7 @@ void CAimProto::InitContactMenus(void) CreateProtoService("/BlockCommand", &CAimProto::BlockBuddy);
mi.pszService = "/BlockCommand";
mi.position = -2000005060;
- mi.icolibItem = GetIconHandle("block");
+ mi.hIcolibItem = GetIconHandle("block");
mi.name.a = LPGEN("&Block");
mi.flags = CMIF_HIDDEN;
hBlockContextMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
diff --git a/protocols/FacebookRM/src/theme.cpp b/protocols/FacebookRM/src/theme.cpp index 88e8d3ded4..3a4cbbf803 100644 --- a/protocols/FacebookRM/src/theme.cpp +++ b/protocols/FacebookRM/src/theme.cpp @@ -107,72 +107,72 @@ void InitContactMenus() {
HookEvent(ME_CLIST_PREBUILDCONTACTMENU, PrebuildContactMenu);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000006000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
mi.name.a = LPGEN("Visit profile");
mi.pszService = "FacebookProto/VisitProfile";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::VisitProfile>);
g_hContactMenuVisitProfile = Menu_AddContactMenuItem(&mi);
mi.position = -2000006001;
- mi.icolibItem = GetIconHandle("friendship");
+ mi.hIcolibItem = GetIconHandle("friendship");
mi.name.a = LPGEN("Visit friendship details");
mi.pszService = "FacebookProto/VisitFriendship";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::VisitFriendship>);
g_hContactMenuVisitFriendship = Menu_AddContactMenuItem(&mi);
mi.position = -2000006002;
- mi.icolibItem = GetIconHandle("conversation");
+ mi.hIcolibItem = GetIconHandle("conversation");
mi.name.a = LPGEN("Visit conversation");
mi.pszService = "FacebookProto/VisitConversation";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::VisitConversation>);
g_hContactMenuVisitConversation = Menu_AddContactMenuItem(&mi);
mi.position = -2000006003;
- mi.icolibItem = GetIconHandle("mind");
+ mi.hIcolibItem = GetIconHandle("mind");
mi.name.a = LPGEN("Share status...");
mi.pszService = "FacebookProto/Mind";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::OnMind>);
g_hContactMenuPostStatus = Menu_AddContactMenuItem(&mi);
mi.position = -2000006004;
- mi.icolibItem = GetIconHandle("poke");
+ mi.hIcolibItem = GetIconHandle("poke");
mi.name.a = LPGEN("Poke");
mi.pszService = "FacebookProto/Poke";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::Poke>);
g_hContactMenuPoke = Menu_AddContactMenuItem(&mi);
mi.position = -2000006010;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
mi.name.a = LPGEN("Cancel friendship");
mi.pszService = "FacebookProto/CancelFriendship";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::CancelFriendship>);
g_hContactMenuAuthRevoke = Menu_AddContactMenuItem(&mi);
mi.position = -2000006011;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
mi.name.a = LPGEN("Cancel friendship request");
mi.pszService = "FacebookProto/CancelFriendshipRequest";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::OnCancelFriendshipRequest>);
g_hContactMenuAuthCancel = Menu_AddContactMenuItem(&mi);
mi.position = -2000006012;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
mi.name.a = LPGEN("Request friendship");
mi.pszService = "FacebookProto/RequestFriendship";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::RequestFriendship>);
g_hContactMenuAuthAsk = Menu_AddContactMenuItem(&mi);
mi.position = -2000006013;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
mi.name.a = LPGEN("Approve friendship");
mi.pszService = "FacebookProto/ApproveFriendship";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::ApproveFriendship>);
g_hContactMenuAuthGrant = Menu_AddContactMenuItem(&mi);
mi.position = -2000006014;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
mi.name.a = LPGEN("Deny friendship request");
mi.pszService = "FacebookProto/DenyFriendship";
CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::DenyFriendship>);
@@ -210,10 +210,10 @@ int FacebookProto::OnBuildStatusMenu(WPARAM, LPARAM) {
HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
- CLISTMENUITEM miRoot = { 0 };
+ TMO_MenuItem miRoot = { 0 };
miRoot.position = 500085000;
miRoot.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED | (this->isOnline() ? 0 : CMIF_GRAYED);
- miRoot.icolibItem = GetIconHandle("facebook");
+ miRoot.hIcolibItem = GetIconHandle("facebook");
miRoot.name.t = m_tszUserName;
hRoot = m_hMenuRoot = Menu_AddProtoMenuItem(&miRoot);
}
@@ -224,48 +224,48 @@ int FacebookProto::OnBuildStatusMenu(WPARAM, LPARAM) }
}
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = (this->isOnline() ? 0 : CMIF_GRAYED);
mi.position = 201001;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.pszService = "/Mind";
- CreateProtoService(mi.pszService, &FacebookProto::OnMind); + CreateProtoService(mi.pszService, &FacebookProto::OnMind);
mi.name.a = LPGEN("Share status...");
- mi.icolibItem = GetIconHandle("mind");
+ mi.hIcolibItem = GetIconHandle("mind");
m_hStatusMind = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/VisitProfile";
- CreateProtoService(mi.pszService, &FacebookProto::VisitProfile); + CreateProtoService(mi.pszService, &FacebookProto::VisitProfile);
mi.name.a = LPGEN("Visit profile");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/VisitNotifications";
- CreateProtoService(mi.pszService, &FacebookProto::VisitNotifications); + CreateProtoService(mi.pszService, &FacebookProto::VisitNotifications);
mi.name.a = LPGEN("Visit notifications");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
Menu_AddProtoMenuItem(&mi, m_szModuleName);
// Services...
- mi.hParentMenu = m_hMenuServicesRoot = Menu_CreateRoot(MO_PROTO, LPGENT("Services..."), mi.position, Skin_GetIconHandle(SKINICON_OTHER_HELP));
+ mi.root = m_hMenuServicesRoot = Menu_CreateRoot(MO_PROTO, LPGENT("Services..."), mi.position, Skin_GetIconHandle(SKINICON_OTHER_HELP));
mi.pszService = "/RefreshBuddyList";
CreateProtoService(mi.pszService, &FacebookProto::RefreshBuddyList);
mi.name.a = LPGEN("Refresh Buddy List");
- mi.icolibItem = GetIconHandle("friendship");
+ mi.hIcolibItem = GetIconHandle("friendship");
Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/CheckFriendRequests";
CreateProtoService(mi.pszService, &FacebookProto::CheckFriendRequests);
mi.name.a = LPGEN("Check Friends Requests");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/CheckNewsfeeds";
CreateProtoService(mi.pszService, &FacebookProto::CheckNewsfeeds);
mi.name.a = LPGEN("Check Newsfeeds");
- mi.icolibItem = GetIconHandle("newsfeed");
+ mi.hIcolibItem = GetIconHandle("newsfeed");
Menu_AddProtoMenuItem(&mi, m_szModuleName);
return 0;
}
diff --git a/protocols/GTalkExt/src/menu.cpp b/protocols/GTalkExt/src/menu.cpp index e9da9939d3..549619069d 100644 --- a/protocols/GTalkExt/src/menu.cpp +++ b/protocols/GTalkExt/src/menu.cpp @@ -44,9 +44,9 @@ int InitMenus(WPARAM wParam, LPARAM lParam) mir_snprintf(szServiceName, _countof(szServiceName), "%s/%s", szModuleName, MS_GTALKEXT_OPENMAILBOX);
CreateServiceFunctionParam(szServiceName, OpenMailboxMenuHandler, (LPARAM)szModuleName);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = HGENMENU(wParam);
- mi.icolibItem = g_hPopupIcon;
+ TMO_MenuItem mi = { 0 };
+ mi.root = HGENMENU(wParam);
+ mi.hIcolibItem = g_hPopupIcon;
mi.position = 200101;
mi.name.a = LPGEN("Open mailbox");
mi.pszService = szServiceName;
diff --git a/protocols/Gadu-Gadu/src/gg.cpp b/protocols/Gadu-Gadu/src/gg.cpp index 0e8d5463b0..3c496a0263 100644 --- a/protocols/Gadu-Gadu/src/gg.cpp +++ b/protocols/Gadu-Gadu/src/gg.cpp @@ -235,9 +235,9 @@ INT_PTR GGPROTO::blockuser(WPARAM hContact, LPARAM lParam) #define GGS_BLOCKUSER "/BlockUser"
void GGPROTO::block_init()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -500050000;
- mi.icolibItem = iconList[8].hIcolib;
+ mi.hIcolibItem = iconList[8].hIcolib;
mi.name.a = LPGEN("&Block");
mi.pszService = GGS_BLOCKUSER;
hBlockMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
@@ -257,28 +257,28 @@ void GGPROTO::block_uninit() // Menus initialization
void GGPROTO::menus_init()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
HGENMENU hGCRoot, hCLRoot, hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
mi.name.t = m_tszUserName;
mi.position = 500090000;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = iconList[0].hIcolib;
+ mi.hIcolibItem = iconList[0].hIcolib;
hGCRoot = hCLRoot = hRoot = hMenuRoot = Menu_AddProtoMenuItem(&mi);
}
else {
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.flags = CMIF_TCHAR;
mi.name.t = LPGENT("Conference");
mi.position = 200001;
- mi.icolibItem = iconList[14].hIcolib;
+ mi.hIcolibItem = iconList[14].hIcolib;
hGCRoot = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.name.t = LPGENT("Contact list");
mi.position = 200002;
- mi.icolibItem = iconList[7].hIcolib;
+ mi.hIcolibItem = iconList[7].hIcolib;
hCLRoot = Menu_AddProtoMenuItem(&mi, m_szModuleName);
if (hMenuRoot)
diff --git a/protocols/Gadu-Gadu/src/groupchat.cpp b/protocols/Gadu-Gadu/src/groupchat.cpp index 61e1318022..5f1b0ec623 100644 --- a/protocols/Gadu-Gadu/src/groupchat.cpp +++ b/protocols/Gadu-Gadu/src/groupchat.cpp @@ -57,15 +57,15 @@ int GGPROTO::gc_init() void GGPROTO::gc_menus_init(HGENMENU hRoot)
{
if (gc_enabled) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
// Conferencing
mi.pszService = GGS_OPEN_CONF;
CreateProtoService(mi.pszService, &GGPROTO::gc_openconf);
mi.position = 2000050001;
- mi.icolibItem = iconList[14].hIcolib;
+ mi.hIcolibItem = iconList[14].hIcolib;
mi.name.t = LPGENT("Open &conference...");
hMainMenu[0] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -73,7 +73,7 @@ void GGPROTO::gc_menus_init(HGENMENU hRoot) mi.pszService = GGS_CLEAR_IGNORED;
CreateProtoService(mi.pszService, &GGPROTO::gc_clearignored);
mi.position = 2000050002;
- mi.icolibItem = iconList[15].hIcolib;
+ mi.hIcolibItem = iconList[15].hIcolib;
mi.name.t = LPGENT("&Clear ignored conferences");
hMainMenu[1] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
}
diff --git a/protocols/Gadu-Gadu/src/image.cpp b/protocols/Gadu-Gadu/src/image.cpp index 6591861af4..860cc2f965 100644 --- a/protocols/Gadu-Gadu/src/image.cpp +++ b/protocols/Gadu-Gadu/src/image.cpp @@ -69,9 +69,9 @@ int gg_img_remove(GGIMAGEDLGDATA *dat); int GGPROTO::img_init()
{
// Send image contact menu item
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000010000;
- mi.icolibItem = iconList[11].hIcolib;
+ mi.hIcolibItem = iconList[11].hIcolib;
mi.name.a = LPGEN("&Image");
mi.pszService = GGS_SENDIMAGE;
hImageMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
diff --git a/protocols/Gadu-Gadu/src/import.cpp b/protocols/Gadu-Gadu/src/import.cpp index 7a4cea35cd..c44e098383 100644 --- a/protocols/Gadu-Gadu/src/import.cpp +++ b/protocols/Gadu-Gadu/src/import.cpp @@ -514,15 +514,15 @@ INT_PTR GGPROTO::export_server(WPARAM wParam, LPARAM lParam) void GGPROTO::import_init(HGENMENU hRoot)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
// Import from server item
mi.pszService = GGS_IMPORT_SERVER;
CreateProtoService(mi.pszService, &GGPROTO::import_server);
mi.position = 2000500001;
- mi.icolibItem = iconList[1].hIcolib;
+ mi.hIcolibItem = iconList[1].hIcolib;
mi.name.t = LPGENT("Import List From &Server");
hMainMenu[2] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -530,7 +530,7 @@ void GGPROTO::import_init(HGENMENU hRoot) mi.pszService = GGS_IMPORT_TEXT;
CreateProtoService(mi.pszService, &GGPROTO::import_text);
mi.position = 2000500002;
- mi.icolibItem = iconList[2].hIcolib;
+ mi.hIcolibItem = iconList[2].hIcolib;
mi.name.t = LPGENT("Import List From &Text File...");
hMainMenu[3] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -538,7 +538,7 @@ void GGPROTO::import_init(HGENMENU hRoot) mi.pszService = GGS_REMOVE_SERVER;
CreateProtoService(mi.pszService, &GGPROTO::remove_server);
mi.position = 2000500003;
- mi.icolibItem = iconList[3].hIcolib;
+ mi.hIcolibItem = iconList[3].hIcolib;
mi.name.t = LPGENT("&Remove List From Server");
hMainMenu[4] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -546,7 +546,7 @@ void GGPROTO::import_init(HGENMENU hRoot) mi.pszService = GGS_EXPORT_SERVER;
CreateProtoService(mi.pszService, &GGPROTO::export_server);
mi.position = 2005000001;
- mi.icolibItem = iconList[4].hIcolib;
+ mi.hIcolibItem = iconList[4].hIcolib;
mi.name.t = LPGENT("Export List To &Server");
hMainMenu[5] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -554,7 +554,7 @@ void GGPROTO::import_init(HGENMENU hRoot) mi.pszService = GGS_EXPORT_TEXT;
CreateProtoService(mi.pszService, &GGPROTO::export_text);
mi.position = 2005000002;
- mi.icolibItem = iconList[5].hIcolib;
+ mi.hIcolibItem = iconList[5].hIcolib;
mi.name.t = LPGENT("Export List To &Text File...");
hMainMenu[6] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
}
diff --git a/protocols/Gadu-Gadu/src/sessions.cpp b/protocols/Gadu-Gadu/src/sessions.cpp index 4823849635..6364386820 100644 --- a/protocols/Gadu-Gadu/src/sessions.cpp +++ b/protocols/Gadu-Gadu/src/sessions.cpp @@ -416,14 +416,14 @@ BOOL GGPROTO::sessions_closedlg() void GGPROTO::sessions_menus_init(HGENMENU hRoot)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.pszService = GGS_CONCUR_SESS;
CreateProtoService(mi.pszService, &GGPROTO::sessions_view);
mi.position = (hMenuRoot) ? 2050000001 : 200003;
- mi.icolibItem = iconList[16].hIcolib;
+ mi.hIcolibItem = iconList[16].hIcolib;
mi.name.t = LPGENT("Concurrent &sessions");
Menu_AddProtoMenuItem(&mi, m_szModuleName);
}
diff --git a/protocols/IRCG/src/services.cpp b/protocols/IRCG/src/services.cpp index 095b23b114..f77fa7312f 100644 --- a/protocols/IRCG/src/services.cpp +++ b/protocols/IRCG/src/services.cpp @@ -26,11 +26,11 @@ void CIrcProto::InitMainMenus(void) HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
// Root popupmenuitem
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = m_tszUserName;
mi.position = -1999901010;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = GetIconHandle(IDI_MAIN);
+ mi.hIcolibItem = GetIconHandle(IDI_MAIN);
hRoot = hMenuRoot = Menu_AddProtoMenuItem(&mi);
}
else {
@@ -40,11 +40,11 @@ void CIrcProto::InitMainMenus(void) }
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hRoot;
mi.name.a = LPGEN("&Quick connect");
- mi.icolibItem = GetIconHandle(IDI_QUICK);
+ mi.hIcolibItem = GetIconHandle(IDI_QUICK);
mi.pszService = IRC_QUICKCONNECT;
mi.position = 201001;
hMenuQuick = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -52,26 +52,26 @@ void CIrcProto::InitMainMenus(void) if (m_iStatus != ID_STATUS_OFFLINE) mi.flags |= CMIF_GRAYED;
mi.name.a = LPGEN("&Join channel");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_CHAT_JOIN);//GetIconHandle(IDI_JOIN);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_CHAT_JOIN);//GetIconHandle(IDI_JOIN);
mi.pszService = IRC_JOINCHANNEL;
mi.position = 201002;
hMenuJoin = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.name.a = LPGEN("&Change your nickname");
- mi.icolibItem = GetIconHandle(IDI_RENAME);
+ mi.hIcolibItem = GetIconHandle(IDI_RENAME);
mi.pszService = IRC_CHANGENICK;
mi.position = 201003;
hMenuNick = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.name.a = LPGEN("Show the &list of available channels");
- mi.icolibItem = GetIconHandle(IDI_LIST);
+ mi.hIcolibItem = GetIconHandle(IDI_LIST);
mi.pszService = IRC_SHOWLIST;
mi.position = 201004;
hMenuList = Menu_AddProtoMenuItem(&mi, m_szModuleName);
if (m_useServer) mi.flags &= ~CMIF_GRAYED;
mi.name.a = LPGEN("&Show the server window");
- mi.icolibItem = GetIconHandle(IDI_SERVER);
+ mi.hIcolibItem = GetIconHandle(IDI_SERVER);
mi.pszService = IRC_SHOWSERVER;
mi.position = 201005;
hMenuServer = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -135,32 +135,32 @@ void InitContactMenus(void) char temp[MAXMODULELABELLENGTH];
char *d = temp + mir_snprintf(temp, _countof(temp), "IRC");
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = temp;
mi.name.a = LPGEN("Channel &settings");
- mi.icolibItem = GetIconHandle(IDI_MANAGER);
+ mi.hIcolibItem = GetIconHandle(IDI_MANAGER);
mir_strcpy(d, IRC_UM_CHANSETTINGS);
mi.position = 500090002;
hUMenuChanSettings = Menu_AddContactMenuItem(&mi);
hMenuChanSettings = CreateServiceFunction(temp, IrcMenuChanSettings);
mi.name.a = LPGEN("&WhoIs info");
- mi.icolibItem = GetIconHandle(IDI_WHOIS);
+ mi.hIcolibItem = GetIconHandle(IDI_WHOIS);
mir_strcpy(d, IRC_UM_WHOIS);
mi.position = 500090001;
hUMenuWhois = Menu_AddContactMenuItem(&mi);
hMenuWhois = CreateServiceFunction(temp, IrcMenuWhois);
mi.name.a = LPGEN("Di&sconnect");
- mi.icolibItem = GetIconHandle(IDI_DELETE);
+ mi.hIcolibItem = GetIconHandle(IDI_DELETE);
mir_strcpy(d, IRC_UM_DISCONNECT);
mi.position = 500090001;
hUMenuDisconnect = Menu_AddContactMenuItem(&mi);
hMenuDisconnect = CreateServiceFunction(temp, IrcMenuDisconnect);
mi.name.a = LPGEN("&Add to ignore list");
- mi.icolibItem = GetIconHandle(IDI_BLOCK);
+ mi.hIcolibItem = GetIconHandle(IDI_BLOCK);
mir_strcpy(d, IRC_UM_IGNORE);
mi.position = 500090002;
hUMenuIgnore = Menu_AddContactMenuItem(&mi);
diff --git a/protocols/IcqOscarJ/src/icq_menu.cpp b/protocols/IcqOscarJ/src/icq_menu.cpp index 6de74333e1..055ab5ecde 100644 --- a/protocols/IcqOscarJ/src/icq_menu.cpp +++ b/protocols/IcqOscarJ/src/icq_menu.cpp @@ -111,7 +111,7 @@ void g_MenuInit(void) char str[MAXMODULELABELLENGTH], *pszDest = str + 3;
mir_strcpy(str, "ICQ");
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = str;
// "Request authorization"
@@ -119,7 +119,7 @@ void g_MenuInit(void) mi.name.a = LPGEN("Request authorization");
mi.position = 1000030000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
g_hContactMenuItems[ICMI_AUTH_REQUEST] = Menu_AddContactMenuItem(&mi);
// "Grant authorization"
@@ -127,7 +127,7 @@ void g_MenuInit(void) mi.name.a = LPGEN("Grant authorization");
mi.position = 1000029999;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
g_hContactMenuItems[ICMI_AUTH_GRANT] = Menu_AddContactMenuItem(&mi);
// "Revoke authorization"
@@ -135,7 +135,7 @@ void g_MenuInit(void) mi.name.a = LPGEN("Revoke authorization");
mi.position = 1000029998;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
g_hContactMenuItems[ICMI_AUTH_REVOKE] = Menu_AddContactMenuItem(&mi);
// "Add to server list"
@@ -143,7 +143,7 @@ void g_MenuInit(void) mi.name.a = LPGEN("Add to server list");
mi.position = -2049999999;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_ADD);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_ADD);
g_hContactMenuItems[ICMI_ADD_TO_SERVLIST] = Menu_AddContactMenuItem(&mi);
// "Show custom status details"
@@ -151,7 +151,7 @@ void g_MenuInit(void) mi.name.a = LPGEN("Show custom status details");
mi.position = -2000004999;
- mi.icolibItem = 0;
+ mi.hIcolibItem = 0;
g_hContactMenuItems[ICMI_XSTATUS_DETAILS] = Menu_AddContactMenuItem(&mi);
// "Open ICQ profile"
diff --git a/protocols/IcqOscarJ/src/icq_xstatus.cpp b/protocols/IcqOscarJ/src/icq_xstatus.cpp index 2283dadbfa..725eb5ca87 100644 --- a/protocols/IcqOscarJ/src/icq_xstatus.cpp +++ b/protocols/IcqOscarJ/src/icq_xstatus.cpp @@ -853,16 +853,16 @@ void CIcqProto::InitXStatusItems(BOOL bAllowStatus) TCHAR szItem[MAX_PATH + 64];
mir_sntprintf(szItem, _countof(szItem), TranslateT("%s Custom Status"), m_tszUserName);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_GetProtocolRoot(m_szModuleName);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_GetProtocolRoot(m_szModuleName);
mi.name.t = szItem;
mi.position = 10001;
hRoot = Menu_AddStatusMenuItem(&mi);
}
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 2000040000;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
int bXStatusMenuBuilt = 0;
for (int i = 0; i <= XSTATUS_COUNT; i++) {
@@ -877,7 +877,7 @@ void CIcqProto::InitXStatusItems(BOOL bAllowStatus) CreateProtoServiceParam(srvFce, &CIcqProto::menuXStatus, i);
mi.flags = (bXStatus == i ? CMIF_CHECKED : 0);
- mi.icolibItem = i ? hXStatusIcons[i-1] : NULL;
+ mi.hIcolibItem = i ? hXStatusIcons[i-1] : NULL;
mi.name.a = i ? (char*)nameXStatus[i-1] : (char *)LPGEN("None");
mi.pszService = srvFce;
diff --git a/protocols/JabberG/src/jabber_menu.cpp b/protocols/JabberG/src/jabber_menu.cpp index 313bc40593..ebf46c4838 100644 --- a/protocols/JabberG/src/jabber_menu.cpp +++ b/protocols/JabberG/src/jabber_menu.cpp @@ -198,12 +198,12 @@ void g_MenuInit(void) //////////////////////////////////////////////////////////////////////////////////////
// Contact menu initialization
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
// "Request authorization"
mi.name.a = LPGEN("Request authorization");
mi.position = -2000001000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
mi.pszService = "Jabber/ReqAuth";
g_hMenuRequestAuth = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuHandleRequestAuth);
@@ -212,7 +212,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/GrantAuth";
mi.name.a = LPGEN("Grant authorization");
mi.position = -2000001001;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
g_hMenuGrantAuth = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuHandleGrantAuth);
@@ -220,7 +220,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/RevokeAuth";
mi.name.a = LPGEN("Revoke authorization");
mi.position = -2000001002;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE);
g_hMenuRevokeAuth = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuRevokeAuth);
@@ -228,7 +228,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/ConvertChatContact";
mi.name.a = LPGEN("Convert");
mi.position = -1999901004;
- mi.icolibItem = g_GetIconHandle(IDI_USER2ROOM);
+ mi.hIcolibItem = g_GetIconHandle(IDI_USER2ROOM);
g_hMenuConvert = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuConvertChatContact);
@@ -236,7 +236,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/AddToRoster";
mi.name.a = LPGEN("Add to roster");
mi.position = -1999901005;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_ADD);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_ADD);
g_hMenuRosterAdd = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuRosterAdd);
@@ -244,7 +244,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/AddToBookmarks";
mi.name.a = LPGEN("Add to Bookmarks");
mi.position = -1999901006;
- mi.icolibItem = g_GetIconHandle(IDI_BOOKMARKS);
+ mi.hIcolibItem = g_GetIconHandle(IDI_BOOKMARKS);
g_hMenuAddBookmark = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuBookmarkAdd);
@@ -252,7 +252,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/TransportLogin";
mi.name.a = LPGEN("Login/logout");
mi.position = -1999901007;
- mi.icolibItem = g_GetIconHandle(IDI_LOGIN);
+ mi.hIcolibItem = g_GetIconHandle(IDI_LOGIN);
g_hMenuLogin = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuTransportLogin);
@@ -260,7 +260,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/TransportGetNicks";
mi.name.a = LPGEN("Resolve nicks");
mi.position = -1999901008;
- mi.icolibItem = g_GetIconHandle(IDI_REFRESH);
+ mi.hIcolibItem = g_GetIconHandle(IDI_REFRESH);
g_hMenuRefresh = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuTransportResolve);
@@ -268,7 +268,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/RunCommands";
mi.name.a = LPGEN("Commands");
mi.position = -1999901009;
- mi.icolibItem = g_GetIconHandle(IDI_COMMAND);
+ mi.hIcolibItem = g_GetIconHandle(IDI_COMMAND);
g_hMenuCommands = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberContactMenuRunCommands);
@@ -276,7 +276,7 @@ void g_MenuInit(void) mi.pszService = "Jabber/SendNote";
mi.name.a = LPGEN("Send Note");
mi.position = -1999901010;
- mi.icolibItem = g_GetIconHandle(IDI_SEND_NOTE);
+ mi.hIcolibItem = g_GetIconHandle(IDI_SEND_NOTE);
g_hMenuSendNote = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, JabberMenuSendNote);
@@ -284,44 +284,44 @@ void g_MenuInit(void) mi.pszService = "Jabber/DirectPresenceDummySvc";
mi.name.a = LPGEN("Send Presence");
mi.position = -1999901011;
- mi.icolibItem = g_GetIconHandle(IDI_NOTES);
+ mi.hIcolibItem = g_GetIconHandle(IDI_NOTES);
g_hMenuDirectPresence[0] = Menu_AddContactMenuItem(&mi);
mi.flags |= CMIF_TCHAR;
- mi.hParentMenu = g_hMenuDirectPresence[0];
+ mi.root = g_hMenuDirectPresence[0];
for (int i = 0; i < _countof(PresenceModeArray); i++) {
char buf[] = "Jabber/DirectPresenceX";
buf[_countof(buf) - 2] = '0' + i;
mi.pszService = buf;
mi.name.t = pcli->pfnGetStatusModeDescription(PresenceModeArray[i].mode, 0);
mi.position = -1999901000;
- mi.icolibItem = Skin_LoadIcon(PresenceModeArray[i].icon);
+ mi.hIcolibItem = Skin_LoadIcon(PresenceModeArray[i].icon);
g_hMenuDirectPresence[i + 1] = Menu_AddContactMenuItem(&mi);
CreateServiceFunctionParam(mi.pszService, JabberMenuHandleDirectPresence, PresenceModeArray[i].mode);
}
mi.flags &= ~(CMIF_TCHAR);
- mi.hParentMenu = NULL;
+ mi.root = NULL;
// Resource selector
mi.pszService = "Jabber/ResourceSelectorDummySvc";
mi.name.a = LPGEN("Jabber Resource");
mi.position = -1999901011;
- mi.icolibItem = g_GetIconHandle(IDI_JABBER);
+ mi.hIcolibItem = g_GetIconHandle(IDI_JABBER);
g_hMenuResourcesRoot = Menu_AddContactMenuItem(&mi);
mi.pszService = "Jabber/UseResource_last";
mi.name.a = LPGEN("Last Active");
mi.position = -1999901000;
- mi.hParentMenu = g_hMenuResourcesRoot;
- mi.icolibItem = g_GetIconHandle(IDI_JABBER);
+ mi.root = g_hMenuResourcesRoot;
+ mi.hIcolibItem = g_GetIconHandle(IDI_JABBER);
g_hMenuResourcesActive = Menu_AddContactMenuItem(&mi);
CreateServiceFunctionParam(mi.pszService, JabberMenuHandleResource, MENUITEM_LASTSEEN);
mi.pszService = "Jabber/UseResource_server";
mi.name.a = LPGEN("Server's Choice");
mi.position = -1999901000;
- mi.icolibItem = g_GetIconHandle(IDI_NODE_SERVER);
+ mi.hIcolibItem = g_GetIconHandle(IDI_NODE_SERVER);
g_hMenuResourcesServer = Menu_AddContactMenuItem(&mi);
CreateServiceFunctionParam(mi.pszService, JabberMenuHandleResource, MENUITEM_SERVER);
}
@@ -417,7 +417,7 @@ int CJabberProto::OnPrebuildContactMenu(WPARAM hContact, LPARAM) }
char text[256];
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = text;
CMString szTmp;
@@ -427,7 +427,7 @@ int CJabberProto::OnPrebuildContactMenu(WPARAM hContact, LPARAM) CreateProtoServiceParam(text, &CJabberProto::OnMenuHandleResource, MENUITEM_RESOURCES + i);
mi.name.a = "";
mi.position = i;
- mi.hParentMenu = g_hMenuResourcesRoot;
+ mi.root = g_hMenuResourcesRoot;
m_phMenuResourceItems[i] = Menu_AddContactMenuItem(&mi, m_szModuleName);
}
if (i < item->arResources.getCount()) {
@@ -580,11 +580,11 @@ void CJabberProto::MenuInit() {
HGENMENU hJabberRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hJabberRoot == NULL) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = m_tszUserName;
mi.position = -1999901006;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = m_hProtoIcon;
+ mi.hIcolibItem = m_hProtoIcon;
hJabberRoot = m_hMenuRoot = Menu_AddProtoMenuItem(&mi);
}
else {
@@ -594,59 +594,59 @@ void CJabberProto::MenuInit() }
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hJabberRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hJabberRoot;
// "Bookmarks..."
mi.pszService = "/Bookmarks";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleBookmarks);
mi.name.a = LPGEN("Bookmarks");
mi.position = 200001;
- mi.icolibItem = GetIconHandle(IDI_BOOKMARKS);
+ mi.hIcolibItem = GetIconHandle(IDI_BOOKMARKS);
m_hMenuBookmarks = Menu_AddProtoMenuItem(&mi, m_szModuleName);
// "Services..."
mi.pszService = NULL;
mi.name.a = LPGEN("Services...");
mi.position = 200003;
- mi.icolibItem = GetIconHandle(IDI_SERVICE_DISCOVERY);
+ mi.hIcolibItem = GetIconHandle(IDI_SERVICE_DISCOVERY);
HGENMENU hMenuServicesRoot = Menu_AddProtoMenuItem(&mi, m_szModuleName);
// "Service Discovery..."
- mi.hParentMenu = hMenuServicesRoot;
+ mi.root = hMenuServicesRoot;
mi.pszService = "/ServiceDiscovery";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleServiceDiscovery);
mi.name.a = LPGEN("Service Discovery");
mi.position = 2000050001;
- mi.icolibItem = GetIconHandle(IDI_SERVICE_DISCOVERY);
+ mi.hIcolibItem = GetIconHandle(IDI_SERVICE_DISCOVERY);
m_hMenuServiceDiscovery = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/SD/MyTransports";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleServiceDiscoveryMyTransports);
mi.name.a = LPGEN("Registered Transports");
mi.position = 2000050003;
- mi.icolibItem = GetIconHandle(IDI_TRANSPORTL);
+ mi.hIcolibItem = GetIconHandle(IDI_TRANSPORTL);
m_hMenuSDMyTransports = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/SD/Transports";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleServiceDiscoveryTransports);
mi.name.a = LPGEN("Local Server Transports");
mi.position = 2000050004;
- mi.icolibItem = GetIconHandle(IDI_TRANSPORT);
+ mi.hIcolibItem = GetIconHandle(IDI_TRANSPORT);
m_hMenuSDTransports = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/SD/Conferences";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleServiceDiscoveryConferences);
mi.name.a = LPGEN("Browse chatrooms");
mi.position = 2000050005;
- mi.icolibItem = GetIconHandle(IDI_GROUP);
+ mi.hIcolibItem = GetIconHandle(IDI_GROUP);
m_hMenuSDConferences = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/Groupchat";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleJoinGroupchat);
mi.name.a = LPGEN("Create/Join group chat");
mi.position = 2000050006;
- mi.icolibItem = GetIconHandle(IDI_GROUP);
+ mi.hIcolibItem = GetIconHandle(IDI_GROUP);
m_hMenuGroupchat = Menu_AddProtoMenuItem(&mi, m_szModuleName);
// "Change Password..."
@@ -654,7 +654,7 @@ void CJabberProto::MenuInit() CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleChangePassword);
mi.name.a = LPGEN("Change Password");
mi.position = 2000050007;
- mi.icolibItem = GetIconHandle(IDI_KEYS);
+ mi.hIcolibItem = GetIconHandle(IDI_KEYS);
m_hMenuChangePassword = Menu_AddProtoMenuItem(&mi, m_szModuleName);
// "Roster editor"
@@ -662,7 +662,7 @@ void CJabberProto::MenuInit() CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleRosterControl);
mi.name.a = LPGEN("Roster editor");
mi.position = 2000050009;
- mi.icolibItem = GetIconHandle(IDI_AGENTS);
+ mi.hIcolibItem = GetIconHandle(IDI_AGENTS);
m_hMenuRosterControl = Menu_AddProtoMenuItem(&mi, m_szModuleName);
// "XML Console"
@@ -670,14 +670,14 @@ void CJabberProto::MenuInit() CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleConsole);
mi.name.a = LPGEN("XML Console");
mi.position = 2000050010;
- mi.icolibItem = GetIconHandle(IDI_CONSOLE);
+ mi.hIcolibItem = GetIconHandle(IDI_CONSOLE);
Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = "/Notes";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandleNotes);
mi.name.a = LPGEN("Notes");
mi.position = 2000050011;
- mi.icolibItem = GetIconHandle(IDI_NOTES);
+ mi.hIcolibItem = GetIconHandle(IDI_NOTES);
m_hMenuNotes = Menu_AddProtoMenuItem(&mi, m_szModuleName);
BuildPrivacyMenu();
@@ -692,7 +692,7 @@ void CJabberProto::MenuInit() mi.pszService = NULL;
mi.position = 200006;
- mi.hParentMenu = hJabberRoot;
+ mi.root = hJabberRoot;
mi.name.a = LPGEN("Resource priority");
mi.flags = CMIF_HIDDEN;
m_hMenuPriorityRoot = Menu_AddProtoMenuItem(&mi);
@@ -703,7 +703,7 @@ void CJabberProto::MenuInit() mi.name.t = szName;
mi.position = 2000040000;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.hParentMenu = m_hMenuPriorityRoot;
+ mi.root = m_hMenuPriorityRoot;
mir_snprintf(srvFce, _countof(srvFce), "/menuSetPriority/%d", 0);
bool needServices = !ProtoServiceExists(m_szModuleName, srvFce);
@@ -720,11 +720,11 @@ void CJabberProto::MenuInit() mir_snprintf(srvFce, _countof(srvFce), "/menuSetPriority/%d", steps[i]);
if (steps[i] > 0) {
mir_sntprintf(szName, TranslateT("Increase priority by %d"), steps[i]);
- mi.icolibItem = GetIconHandle(IDI_ARROW_UP);
+ mi.hIcolibItem = GetIconHandle(IDI_ARROW_UP);
}
else {
mir_sntprintf(szName, TranslateT("Decrease priority by %d"), -steps[i]);
- mi.icolibItem = GetIconHandle(IDI_ARROW_DOWN);
+ mi.hIcolibItem = GetIconHandle(IDI_ARROW_DOWN);
}
if (needServices)
diff --git a/protocols/JabberG/src/jabber_privacy.cpp b/protocols/JabberG/src/jabber_privacy.cpp index 48b3900a8d..f102978ef8 100644 --- a/protocols/JabberG/src/jabber_privacy.cpp +++ b/protocols/JabberG/src/jabber_privacy.cpp @@ -2090,21 +2090,21 @@ INT_PTR __cdecl CJabberProto::menuSetPrivacyList(WPARAM, LPARAM, LPARAM iList) void CJabberProto::BuildPrivacyMenu()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 200005;
- mi.icolibItem = GetIconHandle(IDI_AGENTS);
+ mi.hIcolibItem = GetIconHandle(IDI_AGENTS);
mi.flags = CMIF_HIDDEN;
mi.name.a = LPGEN("Privacy Lists");
- mi.hParentMenu = Menu_GetProtocolRoot(m_szModuleName);
+ mi.root = Menu_GetProtocolRoot(m_szModuleName);
m_hPrivacyMenuRoot = Menu_AddProtoMenuItem(&mi);
mi.pszService = "/PrivacyLists";
CreateProtoService(mi.pszService, &CJabberProto::OnMenuHandlePrivacyLists);
mi.position = 3000040000;
mi.flags = CMIF_TCHAR;
- mi.icolibItem = GetIconHandle(IDI_PRIVACY_LISTS);
+ mi.hIcolibItem = GetIconHandle(IDI_PRIVACY_LISTS);
mi.name.t = LPGENT("List Editor...");
- mi.hParentMenu = m_hPrivacyMenuRoot;
+ mi.root = m_hPrivacyMenuRoot;
Menu_AddProtoMenuItem(&mi, m_szModuleName);
}
@@ -2120,10 +2120,10 @@ void CJabberProto::BuildPrivacyListsMenu(bool bDeleteOld) char srvFce[MAX_PATH + 64];
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 2000040000;
mi.flags = CMIF_TCHAR;
- mi.hParentMenu = m_hPrivacyMenuRoot;
+ mi.root = m_hPrivacyMenuRoot;
mi.pszService = srvFce;
int i = 0;
@@ -2133,7 +2133,7 @@ void CJabberProto::BuildPrivacyListsMenu(bool bDeleteOld) m_privacyMenuServiceAllocated = i;
}
mi.position++;
- mi.icolibItem = Skin_GetIconHandle(m_privacyListManager.GetActiveListName() ? SKINICON_OTHER_SMALLDOT : SKINICON_OTHER_EMPTYBLOB);
+ mi.hIcolibItem = Skin_GetIconHandle(m_privacyListManager.GetActiveListName() ? SKINICON_OTHER_SMALLDOT : SKINICON_OTHER_EMPTYBLOB);
mi.name.t = LPGENT("<none>");
m_hPrivacyMenuItems.insert(Menu_AddProtoMenuItem(&mi, m_szModuleName));
@@ -2147,7 +2147,7 @@ void CJabberProto::BuildPrivacyListsMenu(bool bDeleteOld) }
mi.position++;
- mi.icolibItem = Skin_GetIconHandle(
+ mi.hIcolibItem = Skin_GetIconHandle(
mir_tstrcmp(m_privacyListManager.GetActiveListName(), pList->GetListName()) ? SKINICON_OTHER_SMALLDOT : SKINICON_OTHER_EMPTYBLOB);
mi.name.t = pList->GetListName();
m_hPrivacyMenuItems.insert(Menu_AddProtoMenuItem(&mi, m_szModuleName));
diff --git a/protocols/JabberG/src/jabber_xstatus.cpp b/protocols/JabberG/src/jabber_xstatus.cpp index 93aad6d7e3..a9454ec559 100644 --- a/protocols/JabberG/src/jabber_xstatus.cpp +++ b/protocols/JabberG/src/jabber_xstatus.cpp @@ -465,12 +465,12 @@ void CPepGuiService::RebuildMenu() char szService[128];
mir_snprintf(szService, "/AdvStatusSet/%s", m_name);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hJabberRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hJabberRoot;
mi.pszService = szService;
mi.position = 200010;
mi.flags = CMIF_TCHAR | CMIF_HIDDEN;
- mi.icolibItem = m_hIcolibItem;
+ mi.hIcolibItem = m_hIcolibItem;
mi.name.t = m_szText ? m_szText : _T("<advanced status slot>");
m_hMenuItem = Menu_AddProtoMenuItem(&mi, m_proto->m_szModuleName);
}
diff --git a/protocols/MRA/src/Mra_menus.cpp b/protocols/MRA/src/Mra_menus.cpp index c935384d93..41563e74bb 100644 --- a/protocols/MRA/src/Mra_menus.cpp +++ b/protocols/MRA/src/Mra_menus.cpp @@ -284,16 +284,16 @@ int CMraProto::MraRebuildStatusMenu(WPARAM, LPARAM) TCHAR szItem[MAX_PATH + 64];
mir_sntprintf(szItem, _countof(szItem), _T("%s Custom Status"), m_tszUserName);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_GetProtocolRoot(m_szModuleName);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_GetProtocolRoot(m_szModuleName);
mi.name.t = szItem;
mi.position = 10001;
hRoot = Menu_AddStatusMenuItem(&mi);
}
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 2000060000;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.flags = CMIF_UNICODE;
mi.pszService = szServiceFunction;
@@ -312,11 +312,11 @@ int CMraProto::MraRebuildStatusMenu(WPARAM, LPARAM) else
mi.name.t = (TCHAR*)lpcszXStatusNameDef[i];
- mi.icolibItem = hXStatusAdvancedStatusIcons[i];
+ mi.hIcolibItem = hXStatusAdvancedStatusIcons[i];
}
else {
mi.name.t = (TCHAR*)lpcszXStatusNameDef[i];
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
}
hXStatusMenuItems[i] = Menu_AddStatusMenuItem(&mi, m_szModuleName);
}
@@ -332,9 +332,9 @@ HGENMENU CMraProto::CListCreateMenu(LONG lPosition, LONG lPopupPosition, BOOL bI char szServiceFunction[MAX_PATH];
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
- HGENMENU hRootMenu, (__stdcall *fnAddFunc)(CLISTMENUITEM*, const char*, int);
+ HGENMENU hRootMenu, (__stdcall *fnAddFunc)(TMO_MenuItem*, const char*, int);
if (bIsMain) {
fnAddFunc = Menu_AddProtoMenuItem;
@@ -342,12 +342,12 @@ HGENMENU CMraProto::CListCreateMenu(LONG lPosition, LONG lPopupPosition, BOOL bI if (hRootMenu == NULL) {
mi.name.t = m_tszUserName;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = g_hMainIcon;
+ mi.hIcolibItem = g_hMainIcon;
hRootMenu = Menu_AddProtoMenuItem(&mi);
}
mi.position = 20003;
- mi.hParentMenu = hRootMenu;
+ mi.root = hRootMenu;
}
else {
fnAddFunc = Menu_AddContactMenuItem;
@@ -356,16 +356,16 @@ HGENMENU CMraProto::CListCreateMenu(LONG lPosition, LONG lPopupPosition, BOOL bI mi.flags = 0;
mi.name.a = LPGEN("Services...");
- mi.icolibItem = g_hMainIcon;
+ mi.hIcolibItem = g_hMainIcon;
hRootMenu = fnAddFunc(&mi, m_szModuleName, hLangpack);
- mi.hParentMenu = hRootMenu;
+ mi.root = hRootMenu;
mi.pszService = szServiceFunction;
for (size_t i = 0; i < dwCount; i++) {
mi.pszService = pgdiItems[i].szName;
mi.position = int(lPosition + i);
- mi.icolibItem = pgdiItems[i].hIcolib;
+ mi.hIcolibItem = pgdiItems[i].hIcolib;
mi.name.a = pgdiItems[i].szDescr;
hResult[i] = fnAddFunc(&mi, m_szModuleName, hLangpack);
Menu_ConfigureItem(hResult[i], MCI_OPT_EXECPARAM, lPopupPosition);
diff --git a/protocols/MSN/src/msn_menu.cpp b/protocols/MSN/src/msn_menu.cpp index 334d51c66f..877c5a2f5d 100644 --- a/protocols/MSN/src/msn_menu.cpp +++ b/protocols/MSN/src/msn_menu.cpp @@ -268,13 +268,13 @@ INT_PTR CMsnProto::SetNicknameUI(WPARAM, LPARAM) void CMsnProto::MsnInitMainMenu(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
mi.position = 500085000;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = GetIconHandle(IDI_MSN);
+ mi.hIcolibItem = GetIconHandle(IDI_MSN);
mi.name.t = m_tszUserName;
hRoot = mainMenuRoot = Menu_AddProtoMenuItem(&mi);
}
@@ -284,13 +284,13 @@ void CMsnProto::MsnInitMainMenu(void) }
mi.flags = 0;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
#ifdef OBSOLETE
mi.pszService = MS_SET_NICKNAME_UI;
CreateProtoService(mi.pszService, &CMsnProto::SetNicknameUI);
mi.position = 201001;
- mi.icolibItem = GetIconHandle(IDI_MSN);
+ mi.hIcolibItem = GetIconHandle(IDI_MSN);
mi.name.a = LPGEN("Set &Nickname");
menuItemsMain[0] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
#endif
@@ -298,28 +298,28 @@ void CMsnProto::MsnInitMainMenu(void) mi.pszService = MSN_INVITE;
CreateProtoService(mi.pszService, &CMsnProto::MsnInviteCommand);
mi.position = 201002;
- mi.icolibItem = GetIconHandle(IDI_INVITE);
+ mi.hIcolibItem = GetIconHandle(IDI_INVITE);
mi.name.a = LPGEN("Create &Chat");
menuItemsMain[0] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = MS_GOTO_INBOX;
CreateProtoService(mi.pszService, &CMsnProto::MsnGotoInbox);
mi.position = 201003;
- mi.icolibItem = GetIconHandle(IDI_INBOX);
+ mi.hIcolibItem = GetIconHandle(IDI_INBOX);
mi.name.a = LPGEN("Display &Hotmail Inbox");
menuItemsMain[1] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = MS_EDIT_PROFILE;
CreateProtoService(mi.pszService, &CMsnProto::MsnEditProfile);
mi.position = 201004;
- mi.icolibItem = GetIconHandle(IDI_PROFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_PROFILE);
mi.name.a = LPGEN("View &Profile");
menuItemsMain[2] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = MS_EDIT_ALERTS;
CreateProtoService(mi.pszService, &CMsnProto::MsnSetupAlerts);
mi.position = 201004;
- mi.icolibItem = GetIconHandle(IDI_PROFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_PROFILE);
mi.name.a = LPGEN("Setup Live &Alerts");
menuItemsMain[3] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -398,20 +398,20 @@ void MSN_InitContactMenu(void) mir_strcpy(servicefunction, "MSN");
char* tDest = servicefunction + mir_strlen(servicefunction);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = servicefunction;
mir_strcpy(tDest, MSN_BLOCK);
hBlockCom = CreateServiceFunction(servicefunction, MsnMenuBlockCommand);
mi.position = -500050000;
- mi.icolibItem = GetIconHandle(IDI_MSNBLOCK);
+ mi.hIcolibItem = GetIconHandle(IDI_MSNBLOCK);
mi.name.a = LPGEN("&Block");
hBlockMenuItem = Menu_AddContactMenuItem(&mi);
mir_strcpy(tDest, MSN_VIEW_PROFILE);
hViewProfile = CreateServiceFunction(servicefunction, MsnMenuViewProfile);
mi.position = -500050003;
- mi.icolibItem = GetIconHandle(IDI_PROFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_PROFILE);
mi.name.a = LPGEN("View &Profile");
hLiveSpaceMenuItem = Menu_AddContactMenuItem(&mi);
@@ -420,7 +420,7 @@ void MSN_InitContactMenu(void) hNetMeeting = CreateServiceFunction(servicefunction, MsnMenuSendNetMeeting);
mi.flags = CMIF_NOTOFFLINE;
mi.position = -500050002;
- mi.icolibItem = GetIconHandle(IDI_NETMEETING);
+ mi.hIcolibItem = GetIconHandle(IDI_NETMEETING);
mi.name.a = LPGEN("&Start Netmeeting");
hNetmeetingMenuItem = Menu_AddContactMenuItem(&mi);
#endif
@@ -429,7 +429,7 @@ void MSN_InitContactMenu(void) hSendHotMail = CreateServiceFunction(servicefunction, MsnMenuSendHotmail);
mi.position = -2000010005;
mi.flags = CMIF_HIDDEN;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_SENDEMAIL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_SENDEMAIL);
mi.name.a = LPGEN("Open &Hotmail Inbox");
hOpenInboxMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/protocols/Sametime/src/conference.cpp b/protocols/Sametime/src/conference.cpp index 3ac009dc6e..0eebe780b6 100644 --- a/protocols/Sametime/src/conference.cpp +++ b/protocols/Sametime/src/conference.cpp @@ -508,17 +508,17 @@ void CSametimeProto::InitConferenceMenu() CreateProtoService(MS_SAMETIME_MENULEAVECHAT, &CSametimeProto::onMenuLeaveChat);
CreateProtoService(MS_SAMETIME_MENUCREATECHAT, &CSametimeProto::onMenuCreateChat);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR | CMIF_NOTOFFLINE;
mi.name.t = LPGENT("Leave conference");
mi.pszService = MS_SAMETIME_MENULEAVECHAT;
- mi.icolibItem = GetIconHandle(IDI_ICON_LEAVE);
+ mi.hIcolibItem = GetIconHandle(IDI_ICON_LEAVE);
hLeaveChatMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.name.t = LPGENT("Start conference");
mi.pszService = MS_SAMETIME_MENUCREATECHAT;
- mi.icolibItem = GetIconHandle(IDI_ICON_INVITE);
+ mi.hIcolibItem = GetIconHandle(IDI_ICON_INVITE);
hCreateChatMenuItem = Menu_AddContactMenuItem(&mi);
HookProtoEvent(ME_CLIST_PREBUILDCONTACTMENU, &CSametimeProto::PrebuildContactMenu);
diff --git a/protocols/Sametime/src/sametime_session.cpp b/protocols/Sametime/src/sametime_session.cpp index 96826d75d9..4b49c436ea 100644 --- a/protocols/Sametime/src/sametime_session.cpp +++ b/protocols/Sametime/src/sametime_session.cpp @@ -560,11 +560,11 @@ void CSametimeProto::InitSessionMenu() CreateProtoService(MS_SAMETIME_MENUANNOUNCESESSION, &CSametimeProto::SessionAnnounce);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
mi.position = 2000060000;
mi.name.t = LPGENT("Send announcement...");
mi.pszService = MS_SAMETIME_MENUANNOUNCESESSION;
- mi.icolibItem = GetIconHandle(IDI_ICON_ANNOUNCE);
+ mi.hIcolibItem = GetIconHandle(IDI_ICON_ANNOUNCE);
Menu_AddContactMenuItem(&mi, m_szModuleName);
}
diff --git a/protocols/SkypeWeb/src/skype_menus.cpp b/protocols/SkypeWeb/src/skype_menus.cpp index 15700ec21a..8400cc483a 100644 --- a/protocols/SkypeWeb/src/skype_menus.cpp +++ b/protocols/SkypeWeb/src/skype_menus.cpp @@ -60,14 +60,14 @@ void CSkypeProto::InitMenus() //hChooserMenu = Menu_AddObject("SkypeAccountChooser", LPGEN("Skype menu chooser"), 0, "Skype/MenuChoose");
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
// Request authorization
mi.pszService = MODULE"/RequestAuth";
mi.name.t = LPGENT("Request authorization");
mi.position = CMI_POSITION + CMI_AUTH_REQUEST;
- mi.icolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
ContactMenuItems[CMI_AUTH_REQUEST] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSkypeProto::OnRequestAuth>);
@@ -75,28 +75,28 @@ void CSkypeProto::InitMenus() mi.pszService = MODULE"/GrantAuth";
mi.name.t = LPGENT("Grant authorization");
mi.position = CMI_POSITION + CMI_AUTH_GRANT;
- mi.icolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_GRANT);
+ mi.hIcolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_GRANT);
ContactMenuItems[CMI_AUTH_GRANT] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSkypeProto::OnGrantAuth>);
mi.pszService = MODULE"/GetHistory";
mi.name.t = LPGENT("Get server history");
mi.position = CMI_POSITION + CMI_GETSERVERHISTORY;
- mi.icolibItem = GetIconHandle("synchistory");
+ mi.hIcolibItem = GetIconHandle("synchistory");
ContactMenuItems[CMI_GETSERVERHISTORY] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSkypeProto::GetContactHistory>);
mi.pszService = MODULE"/BlockContact";
mi.name.t = LPGENT("Block contact");
mi.position = CMI_POSITION + CMI_BLOCK;
- mi.icolibItem = GetIconHandle("user_block");
+ mi.hIcolibItem = GetIconHandle("user_block");
ContactMenuItems[CMI_BLOCK] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSkypeProto::BlockContact>);
mi.pszService = MODULE"/UnblockContact";
mi.name.t = LPGENT("Unblock contact");
mi.position = CMI_POSITION + CMI_UNBLOCK;
- mi.icolibItem = GetIconHandle("user_unblock");
+ mi.hIcolibItem = GetIconHandle("user_unblock");
ContactMenuItems[CMI_UNBLOCK] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSkypeProto::UnblockContact>);
}
@@ -111,22 +111,22 @@ int CSkypeProto::OnInitStatusMenu() HGENMENU hStatusMenuRoot = Menu_GetProtocolRoot(m_szModuleName);
if (!hStatusMenuRoot)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = m_tszUserName;
mi.position = -1999901006;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = Skin_GetIconHandle("main");
+ mi.hIcolibItem = Skin_GetIconHandle("main");
hStatusMenuRoot = Menu_AddProtoMenuItem(&mi);
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hStatusMenuRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hStatusMenuRoot;
mi.pszService = "/CreateNewChat";
CreateProtoService(mi.pszService, &CSkypeProto::SvcCreateChat);
mi.name.a = LPGEN("Create new chat");
mi.position = SMI_POSITION + SMI_CREATECHAT;
- mi.icolibItem = GetIconHandle("conference");
+ mi.hIcolibItem = GetIconHandle("conference");
Menu_AddProtoMenuItem(&mi, m_szModuleName);
return 0;
}
\ No newline at end of file diff --git a/protocols/Steam/src/steam_menus.cpp b/protocols/Steam/src/steam_menus.cpp index 5ec4a180b1..ce37b63de8 100644 --- a/protocols/Steam/src/steam_menus.cpp +++ b/protocols/Steam/src/steam_menus.cpp @@ -98,7 +98,7 @@ void CSteamProto::OnInitStatusMenu() {
HGENMENU hSteamRoot = Menu_GetProtocolRoot(m_szModuleName);
if (!hSteamRoot) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = m_tszUserName;
mi.position = -1999901006;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
@@ -109,8 +109,8 @@ void CSteamProto::OnInitStatusMenu() m_hMenuRoot = NULL;
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hSteamRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hSteamRoot;
// Show block list
mi.pszService = "/BlockList";
@@ -126,14 +126,14 @@ void CSteamProto::InitMenus() //////////////////////////////////////////////////////////////////////////////////////
// Contact menu initialization
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
// "Request authorization"
mi.pszService = MODULE "/AuthRequest";
mi.name.t = LPGENT("Request authorization");
mi.position = -201001000 + CMI_AUTH_REQUEST;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
contactMenuItems[CMI_AUTH_REQUEST] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSteamProto::AuthRequestCommand>);
@@ -141,7 +141,7 @@ void CSteamProto::InitMenus() mi.pszService = MODULE "/Block";
mi.name.t = LPGENT("Block");
mi.position = -201001001 + CMI_BLOCK;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
contactMenuItems[CMI_BLOCK] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSteamProto::BlockCommand>);
@@ -151,7 +151,7 @@ void CSteamProto::InitMenus() mi.pszService = MODULE "/JoinToGame";
mi.name.t = LPGENT("Join to game");
mi.position = -200001000 + CMI_JOIN_GAME;
- mi.icolibItem = NULL;
+ mi.hIcolibItem = NULL;
contactMenuItems[CMI_JOIN_GAME] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CSteamProto::JoinToGameCommand>);
}
diff --git a/protocols/Tlen/src/tlen.cpp b/protocols/Tlen/src/tlen.cpp index 9476cb3f37..da55e2f5f2 100644 --- a/protocols/Tlen/src/tlen.cpp +++ b/protocols/Tlen/src/tlen.cpp @@ -264,8 +264,8 @@ void TlenProtocol::initMenuItems() strncpy_s(text, m_szModuleName, _TRUNCATE);
char *pSvcName = text + mir_strlen(text);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hMenuRoot = Menu_CreateRoot(MO_MAIN, m_tszUserName, -1999901009, GetIconHandle(IDI_TLEN));
+ TMO_MenuItem mi = { 0 };
+ mi.root = hMenuRoot = Menu_CreateRoot(MO_MAIN, m_tszUserName, -1999901009, GetIconHandle(IDI_TLEN));
mi.pszService = text;
hMenuChats = NULL;
@@ -275,7 +275,7 @@ void TlenProtocol::initMenuItems() CreateProtoService(pSvcName, &TlenProtocol::MUCMenuHandleMUC);
mi.name.a = LPGEN("Multi-User Conference");
mi.position = 2000050002;
- mi.icolibItem = GetIconHandle(IDI_MUC);
+ mi.hIcolibItem = GetIconHandle(IDI_MUC);
mi.pszService = text;
hMenuMUC = Menu_AddMainMenuItem(&mi);
@@ -283,19 +283,19 @@ void TlenProtocol::initMenuItems() CreateProtoService(pSvcName, &TlenProtocol::MenuHandleInbox);
mi.name.a = LPGEN("Tlen Mail");
mi.position = 2000050003;
- mi.icolibItem = GetIconHandle(IDI_MAIL);
+ mi.hIcolibItem = GetIconHandle(IDI_MAIL);
mi.pszService = text;
hMenuInbox = Menu_AddMainMenuItem(&mi);
// contact menu items
- mi.hParentMenu = NULL;
+ mi.root = NULL;
// "Send picture"
mi.pszService = "/SendPicture";
CreateProtoService(mi.pszService, &TlenProtocol::ContactMenuHandleSendPicture);
mi.name.a = LPGEN("Send picture");
mi.position = -2000019030;
- mi.icolibItem = GetIconHandle(IDI_IMAGE);
+ mi.hIcolibItem = GetIconHandle(IDI_IMAGE);
hMenuPicture = Menu_AddContactMenuItem(&mi, m_szModuleName);
// "Invite to MUC"
@@ -303,7 +303,7 @@ void TlenProtocol::initMenuItems() CreateProtoService(mi.pszService, &TlenProtocol::MUCContactMenuHandleMUC);
mi.name.a = LPGEN("Multi-User Conference");
mi.position = -2000019020;
- mi.icolibItem = GetIconHandle(IDI_MUC);
+ mi.hIcolibItem = GetIconHandle(IDI_MUC);
hMenuContactMUC = Menu_AddContactMenuItem(&mi, m_szModuleName);
// "Invite to voice chat"
@@ -311,7 +311,7 @@ void TlenProtocol::initMenuItems() CreateProtoService(mi.pszService, &TlenProtocol::VoiceContactMenuHandleVoice);
mi.name.a = LPGEN("Voice Chat");
mi.position = -2000019010;
- mi.icolibItem = GetIconHandle(IDI_VOICE);
+ mi.hIcolibItem = GetIconHandle(IDI_VOICE);
hMenuContactVoice = Menu_AddContactMenuItem(&mi, m_szModuleName);
// "Request authorization"
@@ -319,7 +319,7 @@ void TlenProtocol::initMenuItems() CreateProtoService(mi.pszService, &TlenProtocol::ContactMenuHandleRequestAuth);
mi.name.a = LPGEN("Request authorization");
mi.position = -2000001001;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
hMenuContactRequestAuth = Menu_AddContactMenuItem(&mi, m_szModuleName);
// "Grant authorization"
@@ -327,7 +327,7 @@ void TlenProtocol::initMenuItems() CreateProtoService(mi.pszService, &TlenProtocol::ContactMenuHandleGrantAuth);
mi.name.a = LPGEN("Grant authorization");
mi.position = -2000001000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_GRANT);
hMenuContactGrantAuth = Menu_AddContactMenuItem(&mi, m_szModuleName);
}
diff --git a/protocols/Tox/src/tox_menus.cpp b/protocols/Tox/src/tox_menus.cpp index fd99f26022..22852b5b4d 100644 --- a/protocols/Tox/src/tox_menus.cpp +++ b/protocols/Tox/src/tox_menus.cpp @@ -41,14 +41,14 @@ void CToxProto::InitMenus() //hChooserMenu = Menu_AddObject("SkypeAccountChooser", LPGEN("Skype menu chooser"), 0, "Skype/MenuChoose");
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_TCHAR;
// Request authorization
mi.pszService = MODULE"/RequestAuth";
mi.name.t = LPGENT("Request authorization");
mi.position = CMI_POSITION + CMI_AUTH_REQUEST;
- mi.icolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
+ mi.hIcolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_REQUEST);
ContactMenuItems[CMI_AUTH_REQUEST] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CToxProto::OnRequestAuth>);
@@ -56,7 +56,7 @@ void CToxProto::InitMenus() mi.pszService = MODULE"/GrantAuth";
mi.name.t = LPGENT("Grant authorization");
mi.position = CMI_POSITION + CMI_AUTH_GRANT;
- mi.icolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_GRANT);
+ mi.hIcolibItem = ::Skin_GetIconHandle(SKINICON_AUTH_GRANT);
ContactMenuItems[CMI_AUTH_GRANT] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CToxProto::OnGrantAuth>);
@@ -64,7 +64,7 @@ void CToxProto::InitMenus() mi.pszService = MODULE"/Audio/Call";
mi.name.t = LPGENT("Call");
mi.position = -2000020000 + CMI_AUDIO_CALL;
- mi.icolibItem = GetIconHandle("audio_start");
+ mi.hIcolibItem = GetIconHandle("audio_start");
ContactMenuItems[CMI_AUDIO_CALL] = Menu_AddContactMenuItem(&mi);
CreateServiceFunction(mi.pszService, GlobalService<&CToxProto::OnSendAudioCall>);
}
@@ -79,16 +79,16 @@ int CToxProto::OnInitStatusMenu() HGENMENU hStatusMenuRoot = Menu_GetProtocolRoot(m_szModuleName);
if (!hStatusMenuRoot)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.name.t = m_tszUserName;
mi.position = -1999901006;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = Skin_GetIconHandle("main");
+ mi.hIcolibItem = Skin_GetIconHandle("main");
hStatusMenuRoot = Menu_AddProtoMenuItem(&mi);
}
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hStatusMenuRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hStatusMenuRoot;
// Create copy tox id command
mi.pszService = "/CopyToxID";
@@ -103,7 +103,7 @@ int CToxProto::OnInitStatusMenu() CreateProtoService(mi.pszService, &CToxProto::OnCreateChatRoom);
mi.name.t = LPGENT("Create group chat");
mi.position = SMI_POSITION + SMI_GROUPCHAT_CREATE;
- mi.icolibItem = Skin_GetIconHandle("conference");
+ mi.hIcolibItem = Skin_GetIconHandle("conference");
HGENMENU hCreateChatRoom = Menu_AddProtoMenuItem(&mi, m_szModuleName);*/
return 0;
diff --git a/protocols/Twitter/src/proto.cpp b/protocols/Twitter/src/proto.cpp index ba5ebc4672..0d65b25b0c 100644 --- a/protocols/Twitter/src/proto.cpp +++ b/protocols/Twitter/src/proto.cpp @@ -260,10 +260,10 @@ int TwitterProto::OnBuildStatusMenu(WPARAM, LPARAM) mir_strcpy(text, m_szModuleName);
char *tDest = text + mir_strlen(text);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.pszService = text;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.flags = CMIF_TCHAR;
mi.position = 1001;
Menu_AddStatusMenuItem(&mi);
@@ -274,7 +274,7 @@ int TwitterProto::OnBuildStatusMenu(WPARAM, LPARAM) mir_strcpy(tDest, "/Tweet");
mi.name.t = LPGENT("Send Tweet...");
mi.position = 200001;
- mi.icolibItem = GetIconHandle("tweet");
+ mi.hIcolibItem = GetIconHandle("tweet");
Menu_AddStatusMenuItem(&mi);
return 0;
}
diff --git a/protocols/Twitter/src/theme.cpp b/protocols/Twitter/src/theme.cpp index 53606e35a5..30e88a23b0 100644 --- a/protocols/Twitter/src/theme.cpp +++ b/protocols/Twitter/src/theme.cpp @@ -86,18 +86,18 @@ void InitContactMenus() {
g_hMenuEvts[0] = HookEvent(ME_CLIST_PREBUILDCONTACTMENU, PrebuildContactMenu);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = CMIF_NOTOFFLINE | CMIF_TCHAR;
mi.position = -2000006000;
- mi.icolibItem = GetIconHandle("reply");
+ mi.hIcolibItem = GetIconHandle("reply");
mi.name.t = LPGENT("Reply...");
mi.pszService = "Twitter/ReplyToTweet";
g_hMenuEvts[1] = CreateServiceFunction(mi.pszService, GlobalService<&TwitterProto::ReplyToTweet>);
g_hMenuItems[0] = Menu_AddContactMenuItem(&mi);
mi.position = -2000006000;
- mi.icolibItem = GetIconHandle("homepage");
+ mi.hIcolibItem = GetIconHandle("homepage");
mi.name.t = LPGENT("Visit Homepage");
mi.pszService = "Twitter/VisitHomepage";
g_hMenuEvts[2] = CreateServiceFunction(mi.pszService, GlobalService<&TwitterProto::VisitHomepage>);
diff --git a/protocols/VKontakte/src/vk_proto.cpp b/protocols/VKontakte/src/vk_proto.cpp index 1ab461cc26..bd1bf48bd5 100644 --- a/protocols/VKontakte/src/vk_proto.cpp +++ b/protocols/VKontakte/src/vk_proto.cpp @@ -191,42 +191,42 @@ void CVkProto::InitMenus() CreateProtoService(PS_SETSTATUSMSG, &CVkProto::SvcSetStatusMsg);
CreateProtoService(PS_WALLPOST, &CVkProto::SvcWallPost);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_GetProtocolRoot(m_szModuleName);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_GetProtocolRoot(m_szModuleName);
// Proto menu
mi.pszService = PS_CREATECHAT;
mi.position = 10009 + PMI_CREATECHAT;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_CHAT_JOIN);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_CHAT_JOIN);
mi.name.a = LPGEN("Create new chat");
g_hProtoMenuItems[PMI_CREATECHAT] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = PS_SETSTATUSMSG;
mi.position = 10009 + PMI_SETSTATUSMSG;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_STATUS));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_STATUS));
mi.name.a = LPGEN("Status message");
g_hProtoMenuItems[PMI_SETSTATUSMSG] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = PS_WALLPOST;
mi.position = 10009 + PMI_WALLPOST;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_WALL));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_WALL));
mi.name.a = LPGEN("Send message to my wall");
g_hProtoMenuItems[PMI_WALLPOST] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = PS_LOADVKNEWS;
mi.position = 10009 + PMI_LOADVKNEWS;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
mi.name.a = LPGEN("Load news from VK");
g_hProtoMenuItems[PMI_LOADVKNEWS] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
mi.pszService = PS_VISITPROFILE;
mi.position = 10009 + PMI_VISITPROFILE;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_VISITPROFILE));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_VISITPROFILE));
mi.name.a = LPGEN("Visit profile");
g_hProtoMenuItems[PMI_VISITPROFILE] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
// Contact Menu Items
- mi.hParentMenu = NULL;
+ mi.root = NULL;
mi.flags = CMIF_TCHAR;
mi.pszService = PS_VISITPROFILE;
@@ -236,94 +236,94 @@ void CVkProto::InitMenus() mi.pszService = PS_WALLPOST;
mi.position = -200001000 + CMI_WALLPOST;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_WALL));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_WALL));
mi.name.t = LPGENT("Send message to user\'s wall");
g_hContactMenuItems[CMI_WALLPOST] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_ADDASFRIEND;
mi.position = -200001000 + CMI_ADDASFRIEND;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDADD));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDADD));
mi.name.t = LPGENT("Add as friend");
g_hContactMenuItems[CMI_ADDASFRIEND] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_DELETEFRIEND;
mi.position = -200001000 + CMI_DELETEFRIEND;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
mi.name.t = LPGENT("Delete from friend list");
g_hContactMenuItems[CMI_DELETEFRIEND] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_BANUSER;
mi.position = -200001000 + CMI_BANUSER;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_BAN));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_BAN));
mi.name.t = LPGENT("Ban user");
g_hContactMenuItems[CMI_BANUSER] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_REPORTABUSE;
mi.position = -200001000 + CMI_REPORTABUSE;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_ABUSE));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_ABUSE));
mi.name.t = LPGENT("Report abuse");
g_hContactMenuItems[CMI_REPORTABUSE] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_DESTROYKICKCHAT;
mi.position = -200001000 + CMI_DESTROYKICKCHAT;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_FRIENDDEL));
mi.name.t = LPGENT("Destroy room");
g_hContactMenuItems[CMI_DESTROYKICKCHAT] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_OPENBROADCAST;
mi.position = -200001000 + CMI_OPENBROADCAST;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_BROADCAST));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_BROADCAST));
mi.name.t = LPGENT("Open broadcast");
g_hContactMenuItems[CMI_OPENBROADCAST] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_LOADVKNEWS;
mi.position = -200001000 + CMI_LOADVKNEWS;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_NOTIFICATION));
mi.name.t = LPGENT("Load news from VK");
g_hContactMenuItems[CMI_LOADVKNEWS] = Menu_AddContactMenuItem(&mi, m_szModuleName);
// Sync history menu
mi.pszService = PS_GETSERVERHISTORY;
mi.position = -200001000 + CMI_GETSERVERHISTORY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("Reload messages from vk.com...");
g_hContactMenuItems[CMI_GETSERVERHISTORY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
- mi.hParentMenu = g_hContactMenuItems[CMI_GETSERVERHISTORY];
+ mi.root = g_hContactMenuItems[CMI_GETSERVERHISTORY];
mi.pszService = PS_GETSERVERHISTORYLAST1DAY;
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST1DAY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("for last 1 day");
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST1DAY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_GETSERVERHISTORYLAST3DAY;
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST3DAY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("for last 3 days");
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST3DAY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_GETSERVERHISTORYLAST7DAY;
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST7DAY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("for last week");
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST7DAY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_GETSERVERHISTORYLAST30DAY;
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST30DAY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("for last 30 days");
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST30DAY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_GETSERVERHISTORYLAST90DAY;
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETSERVERHISTORYLAST90DAY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("for last 90 days");
g_hContactHistoryMenuItems[CHMI_GETSERVERHISTORYLAST90DAY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
mi.pszService = PS_GETALLSERVERHISTORY;
mi.position = -200001000 + CMI_GETSERVERHISTORY + 100 + CHMI_GETALLSERVERHISTORY;
- mi.icolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
+ mi.hIcolibItem = IcoLib_GetIconByHandle(GetIconHandle(IDI_HISTORY));
mi.name.t = LPGENT("for all time");
g_hContactHistoryMenuItems[CHMI_GETALLSERVERHISTORY] = Menu_AddContactMenuItem(&mi, m_szModuleName);
}
diff --git a/protocols/WhatsApp/src/theme.cpp b/protocols/WhatsApp/src/theme.cpp index b5fe0ad6b5..90d82bb60d 100644 --- a/protocols/WhatsApp/src/theme.cpp +++ b/protocols/WhatsApp/src/theme.cpp @@ -49,10 +49,10 @@ int WhatsAppProto::OnBuildStatusMenu(WPARAM wParam, LPARAM lParam) {
HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500085000;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED | (isOnline() ? 0 : CMIF_GRAYED);
- mi.icolibItem = GetIconHandle("whatsApp");
+ mi.hIcolibItem = GetIconHandle("whatsApp");
mi.name.t = m_tszUserName;
hRoot = m_hMenuRoot = Menu_AddProtoMenuItem(&mi);
}
@@ -63,15 +63,15 @@ int WhatsAppProto::OnBuildStatusMenu(WPARAM wParam, LPARAM lParam) }
}
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.flags = (isOnline() ? 0 : CMIF_GRAYED);
mi.position = 201001;
mi.pszService = "/CreateGroup";
CreateProtoService(mi.pszService, &WhatsAppProto::OnCreateGroup);
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
mi.name.a = LPGEN("Create group");
- mi.icolibItem = GetIconHandle("createGroup");
+ mi.hIcolibItem = GetIconHandle("createGroup");
m_hMenuCreateGroup = Menu_AddProtoMenuItem(&mi, m_szModuleName);
return 0;
}
diff --git a/protocols/Xfire/src/Xfire_game.cpp b/protocols/Xfire/src/Xfire_game.cpp index 44feae968d..2ae07c6912 100644 --- a/protocols/Xfire/src/Xfire_game.cpp +++ b/protocols/Xfire/src/Xfire_game.cpp @@ -436,8 +436,8 @@ void Xfire_game::createMenuitem(unsigned int pos, int dbid) if (dbid < 0)
dbid = pos;
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Start game"), 500084000);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Start game"), 500084000);
mir_snprintf(temp, _countof(temp), servicefunction, this->id);
//wenn die servicefunktion schon exisitert vernichten, hehe
@@ -446,7 +446,7 @@ void Xfire_game::createMenuitem(unsigned int pos, int dbid) CreateServiceFunctionParam(temp, StartGame, this->id);
mi.pszService = temp;
mi.position = 500090002 + pos;
- mi.icolibItem = this->hicon ? this->hicon : LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = this->hicon ? this->hicon : LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.a = menuitemtext(this->name);
this->menuhandle = Menu_AddMainMenuItem(&mi);
diff --git a/protocols/Xfire/src/Xfire_gamelist.cpp b/protocols/Xfire/src/Xfire_gamelist.cpp index 052f2fd624..a417177ad3 100644 --- a/protocols/Xfire/src/Xfire_gamelist.cpp +++ b/protocols/Xfire/src/Xfire_gamelist.cpp @@ -241,11 +241,11 @@ void Xfire_gamelist::clearGamelist() { //erstellt ein dummyeintrag
void Xfire_gamelist::createDummyMenuItem()
{
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("Start game"), 500084000);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("Start game"), 500084000);
mi.position = 500090001;
mi.name.a = Translate("Please wait...");
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
dummymenuitem = Menu_AddMainMenuItem(&mi);
}
diff --git a/protocols/Xfire/src/main.cpp b/protocols/Xfire/src/main.cpp index 3be2481fef..e14629a20e 100644 --- a/protocols/Xfire/src/main.cpp +++ b/protocols/Xfire/src/main.cpp @@ -1113,10 +1113,10 @@ extern "C" __declspec(dllexport) int Load(void) CreateDirectoryA(AvatarsFolder, NULL);
// erweiterte Kontextmenüpunkte
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 500090000;
mi.name.a = protocolname;
- mi.hParentMenu = Menu_AddContactMenuItem(&mi, protocolname);
+ mi.root = Menu_AddContactMenuItem(&mi, protocolname);
mi.flags = CMIF_TCHAR;
char servicefunction[100];
@@ -1124,42 +1124,42 @@ extern "C" __declspec(dllexport) int Load(void) // gotoprofilemenüpunkt
CreateProtoServiceFunction(protocolname, "/GotoProfile", GotoProfile);
mi.pszService = "/GotoProfile";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("&XFire Online Profile");
Menu_AddContactMenuItem(&mi, protocolname);
// gotoxfireclansitemenüpunkt
CreateProtoServiceFunction(protocolname, "/GotoXFireClanSite", GotoXFireClanSite);
mi.pszService = "/GotoXFireClanSite";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("XFire &Clan Site");
gotoclansite = Menu_AddContactMenuItem(&mi, protocolname);
// kopiermenüpunkt
CreateProtoServiceFunction(protocolname, "/GetIPPort", GetIPPort);
mi.pszService = "/GetIPPort";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("C&opy Server Address and Port");
copyipport = Menu_AddContactMenuItem(&mi, protocolname);
// kopiermenüpunkt
CreateProtoServiceFunction(protocolname, "/VoiceIPPort", GetVIPPort);
mi.pszService = "/VoiceIPPort";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("Cop&y Voice Server Address and Port");
vipport = Menu_AddContactMenuItem(&mi, protocolname);
// joinmenüpunkt
CreateProtoServiceFunction(protocolname, "/JoinGame", JoinGame);
mi.pszService = "/JoinGame";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("Join &Game...");
joingame = Menu_AddContactMenuItem(&mi, protocolname);
// playmenüpunkt
CreateProtoServiceFunction(protocolname, "/StartThisGame", StartThisGame);
mi.pszService = "/StartThisGame";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("Play this game...");
startthisgame = Menu_AddContactMenuItem(&mi, protocolname);
@@ -1167,25 +1167,25 @@ extern "C" __declspec(dllexport) int Load(void) CreateProtoServiceFunction(protocolname, "/RemoveFriend", RemoveFriend);
mi.pszService = "/RemoveFriend";
mi.position = 2000070000;
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("Remove F&riend...");
removefriend = Menu_AddContactMenuItem(&mi, protocolname);
// block user
CreateProtoServiceFunction(protocolname, "/BlockFriend", BlockFriend);
mi.pszService = "/BlockFriend";
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("Block U&ser...");
blockfriend = Menu_AddContactMenuItem(&mi, protocolname);
// main menu items
// my fire profile
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, _T(protocolname), 500090000);
+ mi.root = Menu_CreateRoot(MO_MAIN, _T(protocolname), 500090000);
strncpy_s(servicefunction, protocolname, _TRUNCATE);
strncat_s(servicefunction, "GotoProfile2", _TRUNCATE);
CreateServiceFunction(servicefunction, GotoProfile2);
mi.position = 500090000;
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("&My XFire Online Profile");
Menu_AddMainMenuItem(&mi);
@@ -1193,7 +1193,7 @@ extern "C" __declspec(dllexport) int Load(void) strncpy_s(servicefunction, protocolname, _TRUNCATE);
strncat_s(servicefunction, "GotoProfileAct", _TRUNCATE);
CreateServiceFunction(servicefunction, GotoProfileAct);
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("&Activity Report");
Menu_AddMainMenuItem(&mi);
@@ -1201,14 +1201,14 @@ extern "C" __declspec(dllexport) int Load(void) strncpy_s(servicefunction, protocolname, _TRUNCATE);
strncat_s(servicefunction, "ReScanMyGames", _TRUNCATE);
CreateServiceFunction(servicefunction, ReScanMyGames);
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("&Rescan my games...");
Menu_AddMainMenuItem(&mi);
strncpy_s(servicefunction, protocolname, _TRUNCATE);
strncat_s(servicefunction, "SetNick", _TRUNCATE);
CreateServiceFunction(servicefunction, SetNickDlg);
- mi.icolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
+ mi.hIcolibItem = LoadIcon(hinstance, MAKEINTRESOURCE(ID_OP));
mi.name.t = LPGENT("Set &Nickname");
Menu_AddMainMenuItem(&mi);
diff --git a/protocols/Yahoo/src/services.cpp b/protocols/Yahoo/src/services.cpp index d534f092d1..a0094138e9 100644 --- a/protocols/Yahoo/src/services.cpp +++ b/protocols/Yahoo/src/services.cpp @@ -358,13 +358,13 @@ INT_PTR __cdecl CYahooProto::GetUnreadEmailCount(WPARAM, LPARAM) void CYahooProto::MenuMainInit(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
if (hRoot == NULL) {
mi.position = 500015000;
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.icolibItem = GetIconHandle(IDI_YAHOO);
+ mi.hIcolibItem = GetIconHandle(IDI_YAHOO);
mi.name.t = m_tszUserName;
hRoot = mainMenuRoot = Menu_AddProtoMenuItem(&mi);
}
@@ -376,13 +376,13 @@ void CYahooProto::MenuMainInit(void) }
mi.flags = 0;
- mi.hParentMenu = hRoot;
+ mi.root = hRoot;
// Show custom status menu
mi.pszService = YAHOO_SET_CUST_STAT;
CreateProtoService(mi.pszService, &CYahooProto::SetCustomStatCommand);
mi.position = 290000;
- mi.icolibItem = GetIconHandle(IDI_SET_STATUS);
+ mi.hIcolibItem = GetIconHandle(IDI_SET_STATUS);
mi.name.a = LPGEN("Set &Custom Status");
menuItemsAll[0] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -390,7 +390,7 @@ void CYahooProto::MenuMainInit(void) mi.pszService = YAHOO_EDIT_MY_PROFILE;
CreateProtoService(mi.pszService, &CYahooProto::OnEditMyProfile);
mi.position = 290005;
- mi.icolibItem = GetIconHandle(IDI_PROFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_PROFILE);
mi.name.a = LPGEN("&Edit My Profile");
menuItemsAll[1] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -398,7 +398,7 @@ void CYahooProto::MenuMainInit(void) mi.pszService = YAHOO_SHOW_MY_PROFILE;
CreateProtoService(mi.pszService, &CYahooProto::OnShowMyProfileCommand);
mi.position = 290006;
- mi.icolibItem = GetIconHandle(IDI_PROFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_PROFILE);
mi.name.a = LPGEN("&My Profile");
menuItemsAll[2] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -406,7 +406,7 @@ void CYahooProto::MenuMainInit(void) mi.pszService = YAHOO_YAHOO_MAIL;
CreateProtoService(mi.pszService, &CYahooProto::OnGotoMailboxCommand);
mi.position = 290010;
- mi.icolibItem = GetIconHandle(IDI_INBOX);
+ mi.hIcolibItem = GetIconHandle(IDI_INBOX);
mi.name.a = LPGEN("&Yahoo Mail");
menuItemsAll[3] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -414,7 +414,7 @@ void CYahooProto::MenuMainInit(void) mi.pszService = YAHOO_AB;
CreateProtoService(mi.pszService, &CYahooProto::OnABCommand);
mi.position = 290015;
- mi.icolibItem = GetIconHandle(IDI_YAB);
+ mi.hIcolibItem = GetIconHandle(IDI_YAB);
mi.name.a = LPGEN("&Address Book");
menuItemsAll[4] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -422,7 +422,7 @@ void CYahooProto::MenuMainInit(void) mi.pszService = YAHOO_CALENDAR;
CreateProtoService(mi.pszService, &CYahooProto::OnCalendarCommand);
mi.position = 290017;
- mi.icolibItem = GetIconHandle(IDI_CALENDAR);
+ mi.hIcolibItem = GetIconHandle(IDI_CALENDAR);
mi.name.a = LPGEN("&Calendar");
menuItemsAll[5] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
@@ -430,21 +430,21 @@ void CYahooProto::MenuMainInit(void) mi.pszService = "/JoinChatRoom";
CreateProtoService(mi.pszService, &CYahooProto::CreateConference);
mi.position = 290018;
- mi.icolibItem = GetIconHandle(IDI_YAHOO);
+ mi.hIcolibItem = GetIconHandle(IDI_YAHOO);
mi.name.a = LPGEN("Create Conference");
menuItemsAll[6] = Menu_AddProtoMenuItem(&mi, m_szModuleName);
}
void CYahooProto::MenuContactInit(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
// Show Profile
CreateProtoService(YAHOO_SHOW_PROFILE, &CYahooProto::OnShowProfileCommand);
mi.pszService = YAHOO_SHOW_PROFILE;
mi.position = -2000006000;
- mi.icolibItem = GetIconHandle(IDI_PROFILE);
+ mi.hIcolibItem = GetIconHandle(IDI_PROFILE);
mi.name.a = LPGEN("&Show Profile");
hShowProfileMenuItem = Menu_AddContactMenuItem(&mi, m_szModuleName);
}
diff --git a/src/core/stdaway/src/awaymsg.cpp b/src/core/stdaway/src/awaymsg.cpp index b3c9f95c44..15ac55f682 100644 --- a/src/core/stdaway/src/awaymsg.cpp +++ b/src/core/stdaway/src/awaymsg.cpp @@ -167,7 +167,7 @@ int LoadAwayMsgModule(void) hWindowList = WindowList_Create();
CreateServiceFunction(MS_AWAYMSG_SHOWAWAYMSG, GetMessageCommand);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000005000;
mi.flags = CMIF_NOTOFFLINE;
mi.name.a = LPGEN("Re&ad status message");
diff --git a/src/core/stdemail/src/email.cpp b/src/core/stdemail/src/email.cpp index 87c505b6ea..42009eb606 100644 --- a/src/core/stdemail/src/email.cpp +++ b/src/core/stdemail/src/email.cpp @@ -66,9 +66,9 @@ static int EMailPreBuildMenu(WPARAM hContact, LPARAM) int LoadSendRecvEMailModule(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000010000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_SENDEMAIL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_SENDEMAIL);
mi.name.a = LPGEN("&E-mail");
mi.pszService = MS_EMAIL_SENDEMAIL;
hEMailMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/src/core/stdfile/src/file.cpp b/src/core/stdfile/src/file.cpp index 6c0c01c207..397034f2a9 100644 --- a/src/core/stdfile/src/file.cpp +++ b/src/core/stdfile/src/file.cpp @@ -336,9 +336,9 @@ static int SRFileProtoAck(WPARAM, LPARAM lParam) static int SRFileModulesLoaded(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000020000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_FILE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_FILE);
mi.name.a = LPGEN("&File");
mi.pszService = MS_FILE_SENDFILE;
hSRFileMenuItem = Menu_AddContactMenuItem(&mi);
@@ -434,8 +434,8 @@ int LoadSendRecvFileModule(void) {
CreateServiceFunction("FtMgr/Show", FtMgrShowCommand);
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_FILE);
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_FILE);
mi.position = 1900000000;
mi.name.a = LPGEN("File &transfers...");
mi.pszService = "FtMgr/Show"; //MS_PROTO_SHOWFTMGR;
diff --git a/src/core/stdhelp/src/help.cpp b/src/core/stdhelp/src/help.cpp index 300082ee57..d248c24d45 100644 --- a/src/core/stdhelp/src/help.cpp +++ b/src/core/stdhelp/src/help.cpp @@ -73,28 +73,28 @@ int LoadHelpModule(void) CreateServiceFunction("Help/WebsiteCommand", WebsiteCommand);
CreateServiceFunction("Help/BugCommand", BugCommand);
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = Menu_CreateRoot(MO_MAIN, LPGENT("&Help"), 2000090000);
+ TMO_MenuItem mi = { 0 };
+ mi.root = Menu_CreateRoot(MO_MAIN, LPGENT("&Help"), 2000090000);
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDA);
mi.position = 2000090000;
mi.name.a = LPGEN("&About...");
mi.pszService = "Help/AboutCommand";
Menu_AddMainMenuItem(&mi);
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_HELP);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_HELP);
mi.position = -500050000;
mi.name.a = LPGEN("&Support");
mi.pszService = "Help/IndexCommand";
Menu_AddMainMenuItem(&mi);
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDAWEB);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_MIRANDAWEB);
mi.position = 2000050000;
mi.name.a = LPGEN("&Miranda NG homepage");
mi.pszService = "Help/WebsiteCommand";
Menu_AddMainMenuItem(&mi);
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
mi.position = 2000040000;
mi.name.a = LPGEN("&Report bug");
mi.pszService = "Help/BugCommand";
diff --git a/src/core/stdmsg/src/msgs.cpp b/src/core/stdmsg/src/msgs.cpp index ba2f82ab62..3319d29fb2 100644 --- a/src/core/stdmsg/src/msgs.cpp +++ b/src/core/stdmsg/src/msgs.cpp @@ -278,10 +278,10 @@ static int SplitmsgModulesLoaded(WPARAM, LPARAM) RegisterSRMMFonts();
LoadMsgLogIcons();
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000090000;
mi.flags = CMIF_DEFAULT;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_MESSAGE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_MESSAGE);
mi.name.a = LPGEN("&Message");
mi.pszService = MS_MSG_SENDMESSAGE;
hMsgMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/src/core/stduihist/src/history.cpp b/src/core/stduihist/src/history.cpp index 94de89639c..2114cd2e24 100644 --- a/src/core/stduihist/src/history.cpp +++ b/src/core/stduihist/src/history.cpp @@ -401,9 +401,9 @@ static int PreShutdownHistoryModule(WPARAM, LPARAM) int LoadHistoryModule(void)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000090000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_HISTORY);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_HISTORY);
mi.name.a = LPGEN("View &history");
mi.pszService = MS_HISTORY_SHOWCONTACTHISTORY;
hContactMenu = Menu_AddContactMenuItem(&mi);
diff --git a/src/core/stdurl/url.cpp b/src/core/stdurl/url.cpp index e6bbf11e77..ba9bd8bb14 100644 --- a/src/core/stdurl/url.cpp +++ b/src/core/stdurl/url.cpp @@ -119,9 +119,9 @@ static int SRUrlPreBuildMenu(WPARAM wParam, LPARAM) static int SRUrlModulesLoaded(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = -2000040000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_EVENT_URL);
mi.name.a = LPGEN("Web page address (&URL)");
mi.pszService = MS_URL_SENDURL;
hSRUrlMenuItem = Menu_AddContactMenuItem(&mi);
diff --git a/src/core/stduserinfo/src/userinfo.cpp b/src/core/stduserinfo/src/userinfo.cpp index 93511c627f..e4019fe568 100644 --- a/src/core/stduserinfo/src/userinfo.cpp +++ b/src/core/stduserinfo/src/userinfo.cpp @@ -628,9 +628,9 @@ int LoadUserInfoModule(void) HookEvent(ME_DB_CONTACT_DELETED, UserInfoContactDelete);
HookEvent(ME_SYSTEM_PRESHUTDOWN, ShutdownUserInfo);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 1000050000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_USERDETAILS);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_USERDETAILS);
mi.name.a = LPGEN("User &details");
mi.pszService = MS_USERINFO_SHOWDIALOG;
Menu_AddContactMenuItem(&mi);
diff --git a/src/mir_app/src/chat_svc.cpp b/src/mir_app/src/chat_svc.cpp index b38bf3d194..ea88490b14 100644 --- a/src/mir_app/src/chat_svc.cpp +++ b/src/mir_app/src/chat_svc.cpp @@ -560,16 +560,16 @@ static int ModulesLoaded(WPARAM, LPARAM) HookEvent(ME_SMILEYADD_OPTIONSCHANGED, SmileyOptionsChanged); HookEvent(ME_CLIST_PREBUILDCONTACTMENU, PrebuildContactMenu); - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.position = -2000090001; mi.flags = CMIF_DEFAULT; - mi.icolibItem = Skin_GetIconHandle(SKINICON_CHAT_JOIN); + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_CHAT_JOIN); mi.name.a = LPGEN("&Join chat"); mi.pszService = "GChat/JoinChat"; hJoinMenuItem = Menu_AddContactMenuItem(&mi); mi.position = -2000090000; - mi.icolibItem = Skin_GetIconHandle(SKINICON_CHAT_LEAVE); + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_CHAT_LEAVE); mi.flags = CMIF_NOTOFFLINE; mi.name.a = LPGEN("&Leave chat"); mi.pszService = "GChat/LeaveChat"; diff --git a/src/mir_app/src/clc.h b/src/mir_app/src/clc.h index 3a79db0804..bc8a921fa5 100644 --- a/src/mir_app/src/clc.h +++ b/src/mir_app/src/clc.h @@ -111,7 +111,7 @@ void GetFontSetting(int i, LOGFONTA *lf, COLORREF *colour); /* clistmenus.c */
HGENMENU fnGetProtocolMenu(const char*);
int fnGetProtocolVisibility(const char* accName);
-int fnConvertMenu(CLISTMENUITEM*, TMO_MenuItem*);
+int fnConvertMenu(TMO_MenuItem*, TMO_MenuItem*);
int fnGetAverageMode(int *pNetProtoCount);
int fnGetAccountIndexByPos(int Pos);
diff --git a/src/mir_app/src/clistcore.cpp b/src/mir_app/src/clistcore.cpp index b4f5442bf9..9c53d8f1ec 100644 --- a/src/mir_app/src/clistcore.cpp +++ b/src/mir_app/src/clistcore.cpp @@ -207,7 +207,6 @@ static INT_PTR srvRetrieveInterface(WPARAM, LPARAM) cli.pfnReloadProtoMenus = fnReloadProtoMenus;
cli.pfnGetAccountIndexByPos = fnGetAccountIndexByPos;
cli.pfnGetProtocolMenu = fnGetProtocolMenu;
- cli.pfnConvertMenu = fnConvertMenu;
cli.pfnReloadExtraIcons = fnReloadExtraIcons;
cli.pfnSetAllExtraIcons = fnSetAllExtraIcons;
diff --git a/src/mir_app/src/clistmenus.cpp b/src/mir_app/src/clistmenus.cpp index 79518f6aa9..5effa2ea0f 100644 --- a/src/mir_app/src/clistmenus.cpp +++ b/src/mir_app/src/clistmenus.cpp @@ -40,7 +40,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. typedef struct {
WORD id;
int iconId;
- CLISTMENUITEM mi;
+ TMO_MenuItem mi;
}
CListIntMenuItem, *lpCListIntMenuItem;
@@ -79,15 +79,14 @@ static INT_PTR statusHotkeys[MAX_STATUS_COUNT]; TMO_IntMenuItem **hStatusMainMenuHandles;
int hStatusMainMenuHandlesCnt;
-typedef struct
+struct tStatusMenuHandles
{
int protoindex;
int protostatus[MAX_STATUS_COUNT];
TMO_IntMenuItem *menuhandle[MAX_STATUS_COUNT];
-}
-tStatusMenuHandles, *lpStatusMenuHandles;
+};
-lpStatusMenuHandles hStatusMenuHandles;
+tStatusMenuHandles *hStatusMenuHandles;
int hStatusMenuHandlesCnt;
struct BuildContactParam
@@ -179,38 +178,35 @@ MIR_APP_DLL(HMENU) Menu_GetMainMenu(void) return Menu_BuildMainMenu();
}
-MIR_APP_DLL(HGENMENU) Menu_AddMainMenuItem(CLISTMENUITEM *mi, int _hLang)
+MIR_APP_DLL(HGENMENU) Menu_AddMainMenuItem(TMO_MenuItem *pmi, int _hLang)
{
- TMO_MenuItem tmi;
- if (!cli.pfnConvertMenu(mi, &tmi))
- return 0;
-
MainMenuExecParam *mmep = (MainMenuExecParam*)mir_alloc(sizeof(MainMenuExecParam));
if (mmep == NULL)
return 0;
//we need just one parametr.
- mmep->szServiceName = mir_strdup(mi->pszService);
- mmep->szMenuName = tmi.name.t;
- tmi.ownerdata = mmep;
+ mmep->szServiceName = mir_strdup(pmi->pszService);
+ mmep->szMenuName = pmi->name.t;
+ pmi->ownerdata = mmep;
- TMO_IntMenuItem *pimi = Menu_AddItem(hMainMenuObject, &tmi);
+ TMO_IntMenuItem *pimi = Menu_AddItem(hMainMenuObject, pmi);
pimi->hLangpack = _hLang;
mmep->pimi = pimi;
- char* name;
+ const char* name;
bool needFree = false;
- if (mi->pszService)
- name = mi->pszService;
- else if (mi->flags & CMIF_UNICODE) {
- name = mir_t2a(mi->name.t);
+ if (pmi->pszService)
+ name = pmi->pszService;
+ else if (pmi->flags & CMIF_UNICODE) {
+ name = mir_t2a(pmi->name.t);
needFree = true;
}
- else name = mi->name.a;
+ else name = pmi->name.a;
Menu_ConfigureItem(pimi, MCI_OPT_UNIQUENAME, name);
- if (needFree) mir_free(name);
+ if (needFree)
+ mir_free((void*)name);
return pimi;
}
@@ -249,21 +245,17 @@ struct ContactMenuExecParam /////////////////////////////////////////////////////////////////////////////////////////
-MIR_APP_DLL(HGENMENU) Menu_AddContactMenuItem(CLISTMENUITEM *mi, const char *pszProto, int _hLang)
+MIR_APP_DLL(HGENMENU) Menu_AddContactMenuItem(TMO_MenuItem *pmi, const char *pszProto, int _hLang)
{
- TMO_MenuItem tmi;
- if (!cli.pfnConvertMenu(mi, &tmi))
- return 0;
-
// owner data
ContactMenuExecParam *cmep = (ContactMenuExecParam*)mir_calloc(sizeof(ContactMenuExecParam));
- cmep->szServiceName = mir_strdup(mi->pszService);
+ cmep->szServiceName = mir_strdup(pmi->pszService);
if (pszProto != NULL)
cmep->pszContactOwner = mir_strdup(pszProto);
- tmi.ownerdata = cmep;
+ pmi->ownerdata = cmep;
// may be need to change how UniqueName is formed?
- TMO_IntMenuItem *pimi = Menu_AddItem(hContactMenuObject, &tmi);
+ TMO_IntMenuItem *pimi = Menu_AddItem(hContactMenuObject, pmi);
pimi->hLangpack = _hLang;
cmep->pimi = pimi;
@@ -271,15 +263,15 @@ MIR_APP_DLL(HGENMENU) Menu_AddContactMenuItem(CLISTMENUITEM *mi, const char *psz pszProto = "";
char buf[256];
- if (mi->pszService) {
- mir_snprintf(buf, "%s/%s", pszProto, (mi->pszService) ? mi->pszService : "");
+ if (pmi->pszService) {
+ mir_snprintf(buf, "%s/%s", pszProto, (pmi->pszService) ? pmi->pszService : "");
Menu_ConfigureItem(pimi, MCI_OPT_UNIQUENAME, buf);
}
- else if (mi->name.t) {
- if (tmi.flags & CMIF_UNICODE)
- mir_snprintf(buf, "%s/NoService/%S", pszProto, mi->name.t);
+ else if (pmi->name.t) {
+ if (pmi->flags & CMIF_UNICODE)
+ mir_snprintf(buf, "%s/NoService/%S", pszProto, pmi->name.t);
else
- mir_snprintf(buf, "%s/NoService/%s", pszProto, mi->name.a);
+ mir_snprintf(buf, "%s/NoService/%s", pszProto, pmi->name.a);
Menu_ConfigureItem(pimi, MCI_OPT_UNIQUENAME, buf);
}
return pimi;
@@ -376,32 +368,28 @@ struct StatusMenuExecParam /////////////////////////////////////////////////////////////////////////////////////////
-MIR_APP_DLL(HGENMENU) Menu_AddStatusMenuItem(CLISTMENUITEM *mi, const char *pszProto, int _hLangpack)
+MIR_APP_DLL(HGENMENU) Menu_AddStatusMenuItem(TMO_MenuItem *pmi, const char *pszProto, int _hLangpack)
{
- TMO_MenuItem tmi;
- if (!cli.pfnConvertMenu(mi, &tmi))
- return 0;
-
- TMO_IntMenuItem *pRoot = MO_GetIntMenuItem(mi->hParentMenu);
+ TMO_IntMenuItem *pRoot = MO_GetIntMenuItem(pmi->root);
// owner data
StatusMenuExecParam *smep = NULL;
- if (mi->pszService) {
+ if (pmi->pszService) {
smep = (StatusMenuExecParam*)mir_calloc(sizeof(StatusMenuExecParam));
smep->custom = TRUE;
- smep->svc = mir_strdup(mi->pszService);
+ smep->svc = mir_strdup(pmi->pszService);
smep->szProto = mir_strdup(pszProto);
- tmi.ownerdata = smep;
+ pmi->ownerdata = smep;
}
- TMO_IntMenuItem *pimi = Menu_AddItem(hStatusMenuObject, &tmi);
+ TMO_IntMenuItem *pimi = Menu_AddItem(hStatusMenuObject, pmi);
pimi->hLangpack = _hLangpack;
if (smep)
smep->hMenuItem = pimi;
char buf[MAX_PATH + 64];
char *p = (pRoot) ? mir_t2a(pRoot->mi.name.t) : NULL;
- mir_snprintf(buf, "%s/%s", (p) ? p : "", mi->pszService ? mi->pszService : "");
+ mir_snprintf(buf, "%s/%s", (p) ? p : "", pmi->pszService ? pmi->pszService : "");
mir_free(p);
Menu_ConfigureItem(pimi, MCI_OPT_UNIQUENAME, buf);
@@ -1062,23 +1050,6 @@ static int MenuProtoAck(WPARAM, LPARAM lParam) /////////////////////////////////////////////////////////////////////////////////////////
-int fnConvertMenu(CLISTMENUITEM *mi, TMO_MenuItem *pmi)
-{
- if (mi == NULL || pmi == NULL)
- return FALSE;
-
- memset(pmi, 0, sizeof(TMO_MenuItem));
- pmi->root = mi->hParentMenu;
- pmi->flags = mi->flags;
- pmi->hIcolibItem = mi->icolibItem;
- pmi->name.a = mi->name.a;
- pmi->position = mi->position;
- pmi->hLangpack = mi->hLangpack;
- return TRUE;
-}
-
-/////////////////////////////////////////////////////////////////////////////////////////
-
static MenuProto* FindProtocolMenu(const char *proto)
{
for (int i = 0; i < cli.menuProtoCount; i++)
@@ -1108,7 +1079,7 @@ static INT_PTR HotkeySetStatus(WPARAM, LPARAM lParam) /////////////////////////////////////////////////////////////////////////////////////////
// PROTOCOL MENU
-MIR_APP_DLL(HGENMENU) Menu_AddProtoMenuItem(CLISTMENUITEM *mi, const char *pszProto, int _hLangpack)
+MIR_APP_DLL(HGENMENU) Menu_AddProtoMenuItem(TMO_MenuItem *mi, const char *pszProto, int _hLangpack)
{
if (mi == NULL)
return NULL;
@@ -1197,11 +1168,11 @@ void InitCustomMenus(void) // add exit command to menu
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 0x7fffffff;
mi.pszService = "CloseAction";
mi.name.a = LPGEN("E&xit");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_EXIT);
Menu_AddMainMenuItem(&mi);
cli.currentStatusMenuItem = ID_STATUS_OFFLINE;
diff --git a/src/mir_app/src/clui.cpp b/src/mir_app/src/clui.cpp index d73eee5893..bc38c7728a 100644 --- a/src/mir_app/src/clui.cpp +++ b/src/mir_app/src/clui.cpp @@ -326,18 +326,18 @@ int LoadCLUIModule(void) db_get_b(NULL, "CList", "OnTop", SETTING_ONTOP_DEFAULT) ? HWND_TOPMOST : HWND_NOTOPMOST,
0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE);
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
CreateServiceFunction("CList/DeleteContactCommand", MenuItem_DeleteContact);
mi.position = 2000070000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_DELETE);
mi.name.a = LPGEN("De&lete");
mi.pszService = "CList/DeleteContactCommand";
Menu_AddContactMenuItem(&mi);
CreateServiceFunction("CList/RenameContactCommand", MenuItem_RenameContact);
mi.position = 2000050000;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_RENAME);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_RENAME);
mi.name.a = LPGEN("&Rename");
mi.pszService = "CList/RenameContactCommand";
hRenameMenuItem = Menu_AddContactMenuItem(&mi);
@@ -345,7 +345,7 @@ int LoadCLUIModule(void) CreateServiceFunction("CList/AddToListContactCommand", MenuItem_AddContactToList);
mi.position = -2050000000;
mi.flags |= CMIF_NOTONLIST;
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_ADDCONTACT);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_ADDCONTACT);
mi.name.a = LPGEN("&Add permanently to list");
mi.pszService = "CList/AddToListContactCommand";
Menu_AddContactMenuItem(&mi);
diff --git a/src/mir_app/src/findadd.cpp b/src/mir_app/src/findadd.cpp index 35da0d8310..724a1216ed 100644 --- a/src/mir_app/src/findadd.cpp +++ b/src/mir_app/src/findadd.cpp @@ -1028,9 +1028,9 @@ int LoadFindAddModule(void) HookEvent(ME_PROTO_ACCLISTCHANGED, OnSystemModulesLoaded); HookEvent(ME_SYSTEM_PRESHUTDOWN, FindAddPreShutdown); - CLISTMENUITEM mi = { 0 }; + TMO_MenuItem mi = { 0 }; mi.position = 500020000; - mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER); + mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_FINDUSER); mi.name.a = LPGEN("&Find/add contacts..."); mi.pszService = MS_FINDADD_FINDADD; hMainMenuItem = Menu_AddMainMenuItem(&mi); diff --git a/src/mir_app/src/framesmenu.cpp b/src/mir_app/src/framesmenu.cpp index 72f2aa24b4..d5b3c81c17 100644 --- a/src/mir_app/src/framesmenu.cpp +++ b/src/mir_app/src/framesmenu.cpp @@ -45,18 +45,12 @@ INT_PTR FreeOwnerDataFrameMenu(WPARAM, LPARAM lParam) static INT_PTR AddContextFrameMenuItem(WPARAM, LPARAM lParam)
{
- CLISTMENUITEM *mi = (CLISTMENUITEM*)lParam;
-
- TMO_MenuItem tmi;
- if (!cli.pfnConvertMenu(mi, &tmi))
- return NULL;
-
- tmi.root = mi->hParentMenu;
+ TMO_MenuItem *pmi = (TMO_MenuItem*)lParam;
FrameMenuExecParam *fmep = new FrameMenuExecParam();
- fmep->szServiceName = mir_strdup(mi->pszService);
- tmi.ownerdata = fmep;
- return (INT_PTR)Menu_AddItem(hFrameMenuObject, &tmi);
+ fmep->szServiceName = mir_strdup(pmi->pszService);
+ pmi->ownerdata = fmep;
+ return (INT_PTR)Menu_AddItem(hFrameMenuObject, pmi);
}
// called with:
diff --git a/src/mir_app/src/meta_menu.cpp b/src/mir_app/src/meta_menu.cpp index df4fbe6bd5..d848d09c17 100644 --- a/src/mir_app/src/meta_menu.cpp +++ b/src/mir_app/src/meta_menu.cpp @@ -356,41 +356,41 @@ INT_PTR Meta_OnOff(WPARAM, LPARAM) void InitMenus()
{
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
// main menu item
- mi.icolibItem = GetIconHandle(I_MENUOFF);
+ mi.hIcolibItem = GetIconHandle(I_MENUOFF);
mi.name.a = LPGEN("Toggle metacontacts off");
mi.pszService = "MetaContacts/OnOff";
mi.position = 500010000;
hMenuOnOff = Menu_AddMainMenuItem(&mi);
// contact menu items
- mi.icolibItem = GetIconHandle(I_CONVERT);
+ mi.hIcolibItem = GetIconHandle(I_CONVERT);
mi.position = -200010;
mi.name.a = LPGEN("Convert to metacontact");
mi.pszService = "MetaContacts/Convert";
hMenuConvert = Menu_AddContactMenuItem(&mi);
- mi.icolibItem = GetIconHandle(I_ADD);
+ mi.hIcolibItem = GetIconHandle(I_ADD);
mi.position = -200009;
mi.name.a = LPGEN("Add to existing metacontact...");
mi.pszService = "MetaContacts/AddTo";
hMenuAdd = Menu_AddContactMenuItem(&mi);
- mi.icolibItem = GetIconHandle(I_EDIT);
+ mi.hIcolibItem = GetIconHandle(I_EDIT);
mi.position = -200010;
mi.name.a = LPGEN("Edit metacontact...");
mi.pszService = "MetaContacts/Edit";
hMenuEdit = Menu_AddContactMenuItem(&mi);
- mi.icolibItem = GetIconHandle(I_SETDEFAULT);
+ mi.hIcolibItem = GetIconHandle(I_SETDEFAULT);
mi.position = -200009;
mi.name.a = LPGEN("Set as metacontact default");
mi.pszService = "MetaContacts/Default";
hMenuDefault = Menu_AddContactMenuItem(&mi);
- mi.icolibItem = GetIconHandle(I_REMOVE);
+ mi.hIcolibItem = GetIconHandle(I_REMOVE);
mi.position = -200008;
mi.name.a = LPGEN("Delete metacontact");
mi.pszService = "MetaContacts/Delete";
@@ -398,12 +398,12 @@ void InitMenus() mi.position = -99000;
mi.flags = CMIF_HIDDEN;
- mi.icolibItem = 0;
+ mi.hIcolibItem = 0;
mi.name.a = LPGEN("Subcontacts");
hMenuRoot = Menu_AddContactMenuItem(&mi);
mi.flags = CMIF_HIDDEN;
- mi.hParentMenu = hMenuRoot;
+ mi.root = hMenuRoot;
for (int i = 0; i < MAX_CONTACTS; i++) {
mi.position--;
mi.name.a = "";
diff --git a/src/mir_app/src/movetogroup.cpp b/src/mir_app/src/movetogroup.cpp index 55e90eac34..569521472c 100644 --- a/src/mir_app/src/movetogroup.cpp +++ b/src/mir_app/src/movetogroup.cpp @@ -30,7 +30,7 @@ LIST<HANDLE> lphGroupsItems(5); //service
//wparam - hcontact
-//lparam .popupposition from CLISTMENUITEM
+//lparam .popupposition from TMO_MenuItem
#define MTG_MOVE "MoveToGroup/Move"
@@ -67,8 +67,8 @@ static TCHAR* PrepareGroupName(TCHAR* str) static void AddGroupItem(HGENMENU hRoot, TCHAR* name, int pos, WPARAM param, bool checked)
{
- CLISTMENUITEM mi = { 0 };
- mi.hParentMenu = hRoot;
+ TMO_MenuItem mi = { 0 };
+ mi.root = hRoot;
mi.position = pos;
mi.name.t = PrepareGroupName(name);
mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
@@ -88,10 +88,10 @@ static int OnContactMenuBuild(WPARAM wParam, LPARAM) OBJLIST<GroupItemSort> groups(10, GroupItemSort::compare);
if (!hMoveToGroupItem) {
- CLISTMENUITEM mi = { 0 };
+ TMO_MenuItem mi = { 0 };
mi.position = 100000;
mi.name.a = LPGEN("&Move to group");
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_GROUP);
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_GROUP);
hMoveToGroupItem = Menu_AddContactMenuItem(&mi);
}
diff --git a/src/mir_app/src/options.cpp b/src/mir_app/src/options.cpp index 1733efbc26..76d34ace71 100644 --- a/src/mir_app/src/options.cpp +++ b/src/mir_app/src/options.cpp @@ -1293,8 +1293,8 @@ static INT_PTR AddOptionsPage(WPARAM wParam, LPARAM lParam) static int OptModulesLoaded(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_OPTIONS);
mi.position = 1900000000;
mi.name.a = LPGEN("&Options...");
mi.pszService = "Options/OptionsCommand";
diff --git a/src/mir_app/src/proto_opts.cpp b/src/mir_app/src/proto_opts.cpp index cd98784e71..d4cbfc84f7 100644 --- a/src/mir_app/src/proto_opts.cpp +++ b/src/mir_app/src/proto_opts.cpp @@ -1018,8 +1018,8 @@ static INT_PTR OptProtosShow(WPARAM, LPARAM) int OptProtosLoaded(WPARAM, LPARAM)
{
- CLISTMENUITEM mi = { 0 };
- mi.icolibItem = Skin_GetIconHandle(SKINICON_OTHER_ACCMGR);
+ TMO_MenuItem mi = { 0 };
+ mi.hIcolibItem = Skin_GetIconHandle(SKINICON_OTHER_ACCMGR);
mi.position = 1900000000;
mi.name.a = LPGEN("&Accounts...");
mi.pszService = MS_PROTO_SHOWACCMGR;
|