diff options
author | George Hazan <george.hazan@gmail.com> | 2012-06-14 15:51:34 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-06-14 15:51:34 +0000 |
commit | e58823d961a630eb62e60d2ccb443761ba5f1704 (patch) | |
tree | 62d071be480d57af2a53f154a1468abe0b9449ff /protocols/Twitter | |
parent | 721aea0764451e985d575236205808bbef298244 (diff) |
- 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
Diffstat (limited to 'protocols/Twitter')
-rw-r--r-- | protocols/Twitter/proto.cpp | 7 | ||||
-rw-r--r-- | protocols/Twitter/theme.cpp | 5 |
2 files changed, 4 insertions, 8 deletions
diff --git a/protocols/Twitter/proto.cpp b/protocols/Twitter/proto.cpp index a3d9b24e07..6f23a185a4 100644 --- a/protocols/Twitter/proto.cpp +++ b/protocols/Twitter/proto.cpp @@ -341,8 +341,7 @@ int TwitterProto::OnBuildStatusMenu(WPARAM wParam,LPARAM lParam) mi.flags = CMIF_ICONFROMICOLIB|CMIF_ROOTHANDLE;
mi.position = 1001;
- HANDLE m_hMenuRoot = reinterpret_cast<HGENMENU>( CallService(
- MS_CLIST_ADDSTATUSMENUITEM,0,reinterpret_cast<LPARAM>(&mi)) );
+ HANDLE m_hMenuRoot = Menu_AddStatusMenuItem(&mi);
// TODO: Disable this menu item when offline
// "Send Tweet..."
@@ -351,9 +350,7 @@ int TwitterProto::OnBuildStatusMenu(WPARAM wParam,LPARAM lParam) mi.pszName = LPGEN("Send Tweet...");
mi.popupPosition = 200001;
mi.icolibItem = GetIconHandle("tweet");
- HANDLE m_hMenuBookmarks = reinterpret_cast<HGENMENU>( CallService(
- MS_CLIST_ADDSTATUSMENUITEM,0,reinterpret_cast<LPARAM>(&mi)) );
-
+ HANDLE m_hMenuBookmarks = Menu_AddStatusMenuItem(&mi);
return 0;
}
diff --git a/protocols/Twitter/theme.cpp b/protocols/Twitter/theme.cpp index 5afb3b7e36..d6f0be38bb 100644 --- a/protocols/Twitter/theme.cpp +++ b/protocols/Twitter/theme.cpp @@ -143,7 +143,7 @@ void InitContactMenus() mi.pszName = LPGEN("Reply...");
mi.pszService = "Twitter/ReplyToTweet";
g_hMenuEvts[1] = CreateServiceFunction(mi.pszService, GlobalService<&TwitterProto::ReplyToTweet>);
- g_hMenuItems[0] = reinterpret_cast<HANDLE>(CallService(MS_CLIST_ADDCONTACTMENUITEM,0,(LPARAM)&mi) );
+ g_hMenuItems[0] = Menu_AddContactMenuItem(&mi);
mi.position=-2000006000;
mi.icolibItem = GetIconHandle("homepage");
@@ -151,8 +151,7 @@ void InitContactMenus() mi.pszService = "Twitter/VisitHomepage";
g_hMenuEvts[2] = CreateServiceFunction(mi.pszService,
GlobalService<&TwitterProto::VisitHomepage>);
- g_hMenuItems[1] = reinterpret_cast<HANDLE>(
- CallService(MS_CLIST_ADDCONTACTMENUITEM,0,(LPARAM)&mi) );
+ g_hMenuItems[1] = Menu_AddContactMenuItem(&mi);
}
void UninitContactMenus()
|