From e58823d961a630eb62e60d2ccb443761ba5f1704 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 14 Jun 2012 15:51:34 +0000 Subject: - all MS_CLIST_ADD*ITEM services replaced with Menu_Add*Item stubs. - massive cleanup of the menu-related code git-svn-id: http://svn.miranda-ng.org/main/trunk@410 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/TabSRMM/chat/services.cpp | 4 ++-- plugins/TabSRMM/src/globals.cpp | 6 +++--- plugins/TabSRMM/src/typingnotify.cpp | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'plugins/TabSRMM') diff --git a/plugins/TabSRMM/chat/services.cpp b/plugins/TabSRMM/chat/services.cpp index c24af3af6b..a7033f8a62 100644 --- a/plugins/TabSRMM/chat/services.cpp +++ b/plugins/TabSRMM/chat/services.cpp @@ -91,14 +91,14 @@ int Chat_ModulesLoaded(WPARAM wParam, LPARAM lParam) mi.icolibItem = LoadSkinnedIconHandle( SKINICON_CHAT_JOIN ); mi.pszName = LPGEN("&Join"); mi.pszService = "GChat/JoinChat"; - hJoinMenuItem = ( HANDLE )CallService(MS_CLIST_ADDCONTACTMENUITEM, 0, (LPARAM) & mi); + hJoinMenuItem = Menu_AddContactMenuItem(&mi); mi.position = -2000090000; mi.flags = CMIF_NOTOFFLINE | CMIF_ICONFROMICOLIB; mi.icolibItem = LoadSkinnedIconHandle( SKINICON_CHAT_LEAVE ); mi.pszName = LPGEN("&Leave"); mi.pszService = "GChat/LeaveChat"; - hLeaveMenuItem = ( HANDLE )CallService(MS_CLIST_ADDCONTACTMENUITEM, 0, (LPARAM) & mi); + hLeaveMenuItem = Menu_AddContactMenuItem(&mi); CList_SetAllOffline(TRUE, NULL); diff --git a/plugins/TabSRMM/src/globals.cpp b/plugins/TabSRMM/src/globals.cpp index a92d20c92c..c924b06675 100644 --- a/plugins/TabSRMM/src/globals.cpp +++ b/plugins/TabSRMM/src/globals.cpp @@ -258,7 +258,7 @@ void CGlobals::reloadSystemModulesChanged() } mi.pszName = LPGEN("&Message"); mi.pszService = MS_MSG_SENDMESSAGE; - PluginConfig.m_hMenuItem = (HANDLE)CallService(MS_CLIST_ADDCONTACTMENUITEM, 0, (LPARAM) & mi); + PluginConfig.m_hMenuItem = Menu_AddContactMenuItem(&mi); m_useAeroPeek = M->GetByte("useAeroPeek", 1); } @@ -444,7 +444,7 @@ int CGlobals::ModulesLoaded(WPARAM wParam, LPARAM lParam) mi.pszContactOwner = NULL; mi.pszName = LPGEN("&Messaging settings..."); mi.pszService = MS_TABMSG_SETUSERPREFS; - PluginConfig.m_UserMenuItem = (HANDLE)CallService(MS_CLIST_ADDCONTACTMENUITEM, 0, (LPARAM) & mi); + PluginConfig.m_UserMenuItem = Menu_AddContactMenuItem(&mi); if(sendLater->isAvail()) { mi.cbSize = sizeof(mi); @@ -453,7 +453,7 @@ int CGlobals::ModulesLoaded(WPARAM wParam, LPARAM lParam) mi.pszContactOwner = NULL; mi.pszName = LPGEN("&Send later job list..."); mi.pszService = MS_TABMSG_SLQMGR; - PluginConfig.m_UserMenuItem = (HANDLE)CallService(MS_CLIST_ADDMAINMENUITEM, 0, (LPARAM) & mi); + PluginConfig.m_UserMenuItem = Menu_AddMainMenuItem(&mi); } RestoreUnreadMessageAlerts(); diff --git a/plugins/TabSRMM/src/typingnotify.cpp b/plugins/TabSRMM/src/typingnotify.cpp index 7878715850..4a892a9390 100644 --- a/plugins/TabSRMM/src/typingnotify.cpp +++ b/plugins/TabSRMM/src/typingnotify.cpp @@ -558,7 +558,7 @@ int TN_ModuleInit() } mi.pszService = "TypingNotify/EnableDisableMenuCommand"; mi.pszPopupName = LPGEN("PopUps"); - hDisableMenu = (HANDLE) CallService(MS_CLIST_ADDMAINMENUITEM,0,(LPARAM)&mi); + hDisableMenu = Menu_AddMainMenuItem(&mi); } SkinAddNewSoundEx("TNStart", "Instant messages", "Contact started typing"); SkinAddNewSoundEx("TNStop", "Instant messages", "Contact stopped typing"); -- cgit v1.2.3