diff options
author | George Hazan <george.hazan@gmail.com> | 2016-09-06 16:51:39 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2016-09-06 16:51:39 +0000 |
commit | 5e49edfe66308d79bd8095acb1c89d0e987c7aa4 (patch) | |
tree | 950fc1055228f15e2627bc5bafd5bfdfd987db8f /plugins | |
parent | 3bb087726db613aad9c1e61332fda7300600f60c (diff) |
Clist_GetImageList()
git-svn-id: http://svn.miranda-ng.org/main/trunk@17266 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/Clist_blind/src/init.cpp | 4 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_clc.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/clc.cpp | 2 | ||||
-rw-r--r-- | plugins/FavContacts/src/menu.cpp | 2 | ||||
-rw-r--r-- | plugins/FloatingContacts/src/main.cpp | 2 | ||||
-rw-r--r-- | plugins/FloatingContacts/src/stdafx.h | 1 | ||||
-rw-r--r-- | plugins/FloatingContacts/src/thumbs.cpp | 2 | ||||
-rw-r--r-- | plugins/HistoryPlusPlus/GlobalSearch.pas | 2 | ||||
-rw-r--r-- | plugins/NewAwaySysMod/src/ContactList.cpp | 2 | ||||
-rw-r--r-- | plugins/QuickContacts/src/quickcontacts.cpp | 2 | ||||
-rw-r--r-- | plugins/QuickSearch/sr_window.pas | 3 | ||||
-rw-r--r-- | plugins/RecentContacts/src/RecentContacts.cpp | 2 | ||||
-rw-r--r-- | plugins/TipperYM/src/popwin.cpp | 2 | ||||
-rw-r--r-- | plugins/Utils.pas/protocols.pas | 6 |
14 files changed, 16 insertions, 18 deletions
diff --git a/plugins/Clist_blind/src/init.cpp b/plugins/Clist_blind/src/init.cpp index d09979acad..18e9ad813c 100644 --- a/plugins/Clist_blind/src/init.cpp +++ b/plugins/Clist_blind/src/init.cpp @@ -92,7 +92,7 @@ extern "C" __declspec(dllexport) const MUUID MirandaInterfaces[] = { MIID_CLIST, static int OnAccountsChanged(WPARAM, LPARAM)
{
- himlCListClc = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ himlCListClc = Clist_GetImageList();
return 0;
}
@@ -101,7 +101,7 @@ static int OnAccountsChanged(WPARAM, LPARAM) static int OnModulesLoaded(WPARAM, LPARAM)
{
- himlCListClc = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ himlCListClc = Clist_GetImageList();
return 0;
}
diff --git a/plugins/Clist_modern/src/modern_clc.cpp b/plugins/Clist_modern/src/modern_clc.cpp index 1cd8e95663..683f0bd7d4 100644 --- a/plugins/Clist_modern/src/modern_clc.cpp +++ b/plugins/Clist_modern/src/modern_clc.cpp @@ -1623,7 +1623,7 @@ static int clcHookModulesLoaded(WPARAM, LPARAM) HRESULT ClcLoadModule()
{
- g_himlCListClc = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ g_himlCListClc = Clist_GetImageList();
HookEvent(ME_MC_SUBCONTACTSCHANGED, clcMetacontactChanged);
HookEvent(ME_MC_ENABLED, clcMetaModeChanged);
diff --git a/plugins/Clist_nicer/src/clc.cpp b/plugins/Clist_nicer/src/clc.cpp index 7d25e6faf0..189717d6c6 100644 --- a/plugins/Clist_nicer/src/clc.cpp +++ b/plugins/Clist_nicer/src/clc.cpp @@ -204,7 +204,7 @@ int LoadCLCModule(void) g_cxsmIcon = GetSystemMetrics(SM_CXSMICON);
g_cysmIcon = GetSystemMetrics(SM_CYSMICON);
- hCListImages = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ hCListImages = Clist_GetImageList();
HookEvent(ME_MC_ENABLED, ClcMetamodeChanged);
HookEvent(ME_DB_CONTACT_SETTINGCHANGED, ClcSettingChanged);
diff --git a/plugins/FavContacts/src/menu.cpp b/plugins/FavContacts/src/menu.cpp index 0a24b6ecd3..92775dee70 100644 --- a/plugins/FavContacts/src/menu.cpp +++ b/plugins/FavContacts/src/menu.cpp @@ -241,7 +241,7 @@ static BOOL sttDrawItem_Contact(LPDRAWITEMSTRUCT lpdis, Options *options = NULL) char *proto = GetContactProto(hContact);
- HIMAGELIST hIml = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ HIMAGELIST hIml = Clist_GetImageList();
int iIcon = pcli->pfnGetContactIcon(hContact);
if (db_get_dw(hContact, proto, "IdleTS", 0)) {
diff --git a/plugins/FloatingContacts/src/main.cpp b/plugins/FloatingContacts/src/main.cpp index 0988542780..0f7b433256 100644 --- a/plugins/FloatingContacts/src/main.cpp +++ b/plugins/FloatingContacts/src/main.cpp @@ -211,7 +211,7 @@ static int OnContactDragStop(WPARAM hContact, LPARAM) static int OnSkinIconsChanged(WPARAM, LPARAM)
{
// Get handle to the image list
- himlMiranda = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ himlMiranda = Clist_GetImageList();
// Update thumbs
for (int i = 0; i < thumbList.getCount(); ++i)
diff --git a/plugins/FloatingContacts/src/stdafx.h b/plugins/FloatingContacts/src/stdafx.h index b983665732..fb438647d6 100644 --- a/plugins/FloatingContacts/src/stdafx.h +++ b/plugins/FloatingContacts/src/stdafx.h @@ -6,6 +6,7 @@ #include <assert.h>
#include <math.h>
#include <Shlwapi.h>
+#include <CommCtrl.h>
#include <newpluginapi.h>
#include <m_system_cpp.h>
diff --git a/plugins/FloatingContacts/src/thumbs.cpp b/plugins/FloatingContacts/src/thumbs.cpp index 8fb1a3c5f4..f1d3447e74 100644 --- a/plugins/FloatingContacts/src/thumbs.cpp +++ b/plugins/FloatingContacts/src/thumbs.cpp @@ -237,7 +237,7 @@ void ThumbInfo::ResizeThumb() {
int index = FLT_FONTID_NOTONLIST;
- himlMiranda = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ himlMiranda = Clist_GetImageList();
if (himlMiranda == NULL)
return;
diff --git a/plugins/HistoryPlusPlus/GlobalSearch.pas b/plugins/HistoryPlusPlus/GlobalSearch.pas index 44eb3283ea..5beb129b1d 100644 --- a/plugins/HistoryPlusPlus/GlobalSearch.pas +++ b/plugins/HistoryPlusPlus/GlobalSearch.pas @@ -443,7 +443,7 @@ begin ContactList := TObjectList.Create;
- ilContacts.Handle := CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ ilContacts.Handle := Clist_GetImageList();
// delphi 2006 doesn't save toolbar's flat property in dfm if it is True
// delphi 2006 doesn't save toolbar's edgeborder property in dfm
ToolBar.Flat := True;
diff --git a/plugins/NewAwaySysMod/src/ContactList.cpp b/plugins/NewAwaySysMod/src/ContactList.cpp index 8a472008de..561292c9b1 100644 --- a/plugins/NewAwaySysMod/src/ContactList.cpp +++ b/plugins/NewAwaySysMod/src/ContactList.cpp @@ -343,7 +343,7 @@ CCList::CCList(HWND hTreeView) : CWndUserData(GetParent(hTreeView)).SetCList(this);
OrigTreeViewProc = (WNDPROC)SetWindowLongPtr(hTreeView, GWLP_WNDPROC, (LONG_PTR)ContactListSubclassProc);
OrigParentProc = (WNDPROC)SetWindowLongPtr(GetParent(hTreeView), GWLP_WNDPROC, (LONG_PTR)ParentSubclassProc);
- TreeView_SetImageList(hTreeView, CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0), TVSIL_NORMAL);
+ TreeView_SetImageList(hTreeView, Clist_GetImageList(), TVSIL_NORMAL);
WindowList_Add(hCLWindowList, hTreeView, NULL);
TreeView_SetIndent(hTreeView, 5); // doesn't set it less than the initial value on my system, and i guess it's because of icons... but who knows - maybe it will work somewhere
}
diff --git a/plugins/QuickContacts/src/quickcontacts.cpp b/plugins/QuickContacts/src/quickcontacts.cpp index bc09d7f4aa..6f38d59d36 100644 --- a/plugins/QuickContacts/src/quickcontacts.cpp +++ b/plugins/QuickContacts/src/quickcontacts.cpp @@ -183,7 +183,7 @@ int ModulesLoaded(WPARAM, LPARAM) }
// Get the icons for the listbox
- hIml = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST,0,0);
+ hIml = Clist_GetImageList();
// Add menu item
CMenuItem mi;
diff --git a/plugins/QuickSearch/sr_window.pas b/plugins/QuickSearch/sr_window.pas index a2f96e4098..3ed4343e6d 100644 --- a/plugins/QuickSearch/sr_window.pas +++ b/plugins/QuickSearch/sr_window.pas @@ -1970,8 +1970,7 @@ begin grid:=GetDlgItem(Dialog,IDC_LIST);
// ListView
- ListView_SetImageList(grid,
- CallService(MS_CLIST_GETICONSIMAGELIST,0,0),LVSIL_SMALL);
+ ListView_SetImageList(grid,Clist_GetImageList,LVSIL_SMALL);
tmp:=LVS_EX_FULLROWSELECT or LVS_EX_SUBITEMIMAGES or LVS_EX_HEADERDRAGDROP or
LVS_EX_LABELTIP or LVS_EX_DOUBLEBUFFER;
diff --git a/plugins/RecentContacts/src/RecentContacts.cpp b/plugins/RecentContacts/src/RecentContacts.cpp index 72441c76e9..499ce50241 100644 --- a/plugins/RecentContacts/src/RecentContacts.cpp +++ b/plugins/RecentContacts/src/RecentContacts.cpp @@ -213,7 +213,7 @@ INT_PTR CALLBACK ShowListMainDlgProc(HWND hDlg, UINT msg, WPARAM wParam, LPARAM ListView_InsertColumn(hList, 0, &lvc);
// add conacts to listview
- HIMAGELIST hImgList = (HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0);
+ HIMAGELIST hImgList = Clist_GetImageList();
if (hImgList != NULL)
ListView_SetImageList(hList, hImgList, LVSIL_SMALL);
diff --git a/plugins/TipperYM/src/popwin.cpp b/plugins/TipperYM/src/popwin.cpp index f10def056c..b7fa55bcb7 100644 --- a/plugins/TipperYM/src/popwin.cpp +++ b/plugins/TipperYM/src/popwin.cpp @@ -318,7 +318,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa // status icon if (pwd->bIsIconVisible[0]) { for (i = 0; opt.exIconsOrder[i] != 0; i++); - pwd->extraIcons[i].hIcon = ImageList_GetIcon((HIMAGELIST)CallService(MS_CLIST_GETICONSIMAGELIST, 0, 0), pwd->iIconIndex, 0); + pwd->extraIcons[i].hIcon = ImageList_GetIcon(Clist_GetImageList(), pwd->iIconIndex, 0); pwd->extraIcons[i].bDestroy = true; } diff --git a/plugins/Utils.pas/protocols.pas b/plugins/Utils.pas/protocols.pas index bb57e337ad..f4526a6c09 100644 --- a/plugins/Utils.pas/protocols.pas +++ b/plugins/Utils.pas/protocols.pas @@ -226,8 +226,7 @@ begin begin
SetWindowLongPtrW(list,GWL_STYLE,
GetWindowLongPtrW(list,GWL_STYLE) or LVS_SHAREIMAGELISTS);
- ListView_SetImageList(list,
- CallService(MS_CLIST_GETICONSIMAGELIST,0,0),LVSIL_SMALL);
+ ListView_SetImageList(list,Clist_GetImageList,LVSIL_SMALL);
lvc.mask:=LVCF_FMT+LVCF_IMAGE
end
else
@@ -309,8 +308,7 @@ begin begin
SetWindowLongPtrW(list,GWL_STYLE,
GetWindowLongPtrW(list,GWL_STYLE) or LVS_SHAREIMAGELISTS);
- ListView_SetImageList(list,
- CallService(MS_CLIST_GETICONSIMAGELIST,0,0),LVSIL_SMALL);
+ ListView_SetImageList(list,Clist_GetImageList,LVSIL_SMALL);
lvc.mask:=LVCF_FMT+LVCF_IMAGE
end
else
|