summaryrefslogtreecommitdiff
path: root/plugins/PluginUpdater/src/Compat/compat.cpp
diff options
context:
space:
mode:
authorTobias Weimer <wishmaster51@googlemail.com>2015-05-22 20:15:32 +0000
committerTobias Weimer <wishmaster51@googlemail.com>2015-05-22 20:15:32 +0000
commitba020540c064ebd48bf6b77e5bd5e11255766f23 (patch)
treead87b13d4dbc6cc43a489aa1022b28b48d0e2dd5 /plugins/PluginUpdater/src/Compat/compat.cpp
parentc09aa99a7e9915c503064d6eb5e9dd1bdd2a673f (diff)
-PluginUpdater:
-code cleanup git-svn-id: http://svn.miranda-ng.org/main/trunk@13765 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
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);
+ }
+}