diff options
author | George Hazan <george.hazan@gmail.com> | 2012-07-08 20:51:14 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-07-08 20:51:14 +0000 |
commit | 696f4ea57845f48d6d979ecd9d66bb22bd9f738d (patch) | |
tree | c32ac05d363bff47320c1b204561b966aa1c81fd /plugins/RecentContacts/RecentContacts.cpp | |
parent | 3b396a2da6b0b8e0f4d2c051aca133772d317820 (diff) |
TopToolbar usage fixed everywhere
git-svn-id: http://svn.miranda-ng.org/main/trunk@861 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/RecentContacts/RecentContacts.cpp')
-rw-r--r-- | plugins/RecentContacts/RecentContacts.cpp | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/plugins/RecentContacts/RecentContacts.cpp b/plugins/RecentContacts/RecentContacts.cpp index b2dfc76e9e..fb893f87e0 100644 --- a/plugins/RecentContacts/RecentContacts.cpp +++ b/plugins/RecentContacts/RecentContacts.cpp @@ -454,19 +454,13 @@ static int OnContactSettingChanged( WPARAM wParam, LPARAM lParam ) int Create_TopToolbarShowList(WPARAM wParam, LPARAM lParam)
{
- if (ServiceExists(MS_TTB_ADDBUTTON)) {
- TTBButton ttbb = { 0 };
- ttbb.cbSize = sizeof(ttbb);
- ttbb.hIconHandleDn = ttbb.hIconHandleDn = hIcon;
- ttbb.pszService = msLastUC_ShowList;
- ttbb.dwFlags = TTBBF_VISIBLE|TTBBF_SHOWTOOLTIP;
- ttbb.name = Translate(msLastUC_ShowListName);
-
- hTopToolbarButtonShowList = (HANDLE)CallService(MS_TTB_ADDBUTTON, (WPARAM)&ttbb, 0);
- if ((int)hTopToolbarButtonShowList == -1)
- hTopToolbarButtonShowList = NULL;
- }
-
+ TTBButton ttbb = { 0 };
+ ttbb.cbSize = sizeof(ttbb);
+ ttbb.hIconHandleDn = ttbb.hIconHandleDn = hIcon;
+ ttbb.pszService = msLastUC_ShowList;
+ ttbb.dwFlags = TTBBF_VISIBLE | TTBBF_SHOWTOOLTIP;
+ ttbb.name = msLastUC_ShowListName;
+ hTopToolbarButtonShowList = TopToolbar_AddButton(&ttbb);
return 0;
}
|