summaryrefslogtreecommitdiff
path: root/plugins/PluginUpdater/src/Compat/compat.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/PluginUpdater/src/Compat/compat.cpp')
-rw-r--r--plugins/PluginUpdater/src/Compat/compat.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/plugins/PluginUpdater/src/Compat/compat.cpp b/plugins/PluginUpdater/src/Compat/compat.cpp
index 260ff99039..e6b67265bd 100644
--- a/plugins/PluginUpdater/src/Compat/compat.cpp
+++ b/plugins/PluginUpdater/src/Compat/compat.cpp
@@ -114,3 +114,24 @@ void __stdcall RestartMe(void*)
STARTUPINFO si = { sizeof(si) };
CreateProcess(mirandaPath, cmdLine, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi);
}
+
+/////////////////////////////////////////////////////////////////////////////////////
+// we don't use Icon_Register here because it should work under Miranda IM too
+
+void InitIcoLib()
+{
+ TCHAR destfile[MAX_PATH];
+ GetModuleFileName(hInst, destfile, MAX_PATH);
+
+ SKINICONDESC sid = { sizeof(sid) };
+ sid.flags = SIDF_PATH_TCHAR;
+ sid.ptszDefaultFile = destfile;
+ sid.pszSection = MODULEA;
+
+ for (int i = 0; i < SIZEOF(iconList); i++) {
+ sid.pszName = iconList[i].szIconName;
+ sid.pszDescription = iconList[i].szDescr;
+ sid.iDefaultIndex = -iconList[i].IconID;
+ Skin_AddIcon(&sid);
+ }
+}