summaryrefslogtreecommitdiff
path: root/plugins/Ping/src/utils.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-12-01 20:32:13 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-12-01 20:32:13 +0000
commit1860018b201d995ed051c0affb72d5a1d09fa02e (patch)
tree1ee096c43578fdf5694e5487d672830f810f186c /plugins/Ping/src/utils.cpp
parent7300094417302d82aa4f3f6e469f91d8facf4f26 (diff)
SKINICONDESC initialization - end of story
git-svn-id: http://svn.miranda-ng.org/main/trunk@2598 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Ping/src/utils.cpp')
-rw-r--r--plugins/Ping/src/utils.cpp81
1 files changed, 39 insertions, 42 deletions
diff --git a/plugins/Ping/src/utils.cpp b/plugins/Ping/src/utils.cpp
index 4350fe2e16..22b8b2e63d 100644
--- a/plugins/Ping/src/utils.cpp
+++ b/plugins/Ping/src/utils.cpp
@@ -304,7 +304,8 @@ HANDLE hIcoLibIconsChanged;
HICON hIconResponding, hIconNotResponding, hIconTesting, hIconDisabled;
-int ReloadIcons(WPARAM wParam, LPARAM lParam) {
+int ReloadIcons(WPARAM wParam, LPARAM lParam)
+{
hIconResponding = Skin_GetIcon("ping_responding");
hIconNotResponding = Skin_GetIcon("ping_not_responding");
hIconTesting = Skin_GetIcon("ping_testing");
@@ -318,48 +319,44 @@ void InitUtils()
{
TCHAR file[MAX_PATH];
GetModuleFileName(hInst,file,MAX_PATH);
- {
- SKINICONDESC sid = {0};
-
- sid.cbSize = sizeof(SKINICONDESC);
- sid.ptszSection = LPGENT("Ping");
- sid.flags = SIDF_PATH_TCHAR;
-
- sid.pszDescription = LPGEN("Responding");
- sid.pszName = "ping_responding";
- sid.ptszDefaultFile = file;
- sid.iDefaultIndex = -IDI_ICON_RESPONDING;
- Skin_AddIcon(&sid);
-
- sid.pszDescription = LPGEN("Not Responding");
- sid.pszName = "ping_not_responding";
- sid.ptszDefaultFile = file;
- sid.iDefaultIndex = -IDI_ICON_NOTRESPONDING;
- Skin_AddIcon(&sid);
-
- sid.pszDescription = LPGEN("Testing");
- sid.pszName = "ping_testing";
- sid.ptszDefaultFile = file;
- sid.iDefaultIndex = -IDI_ICON_TESTING;
- Skin_AddIcon(&sid);
-
- sid.pszDescription = LPGEN("Disabled");
- sid.pszName = "ping_disabled";
- sid.ptszDefaultFile = file;
- sid.iDefaultIndex = -IDI_ICON_DISABLED;
- Skin_AddIcon(&sid);
-
- hIconResponding = Skin_GetIcon("ping_responding");
- hIconNotResponding = Skin_GetIcon("ping_not_responding");
- hIconTesting = Skin_GetIcon("ping_testing");
- hIconDisabled = Skin_GetIcon("ping_disabled");
-
- hIcoLibIconsChanged = HookEvent(ME_SKIN2_ICONSCHANGED, ReloadIcons);
- }
- if(ServiceExists(MS_POPUP_REGISTERCLASS)) {
- POPUPCLASS test = {0};
- test.cbSize = sizeof(test);
+ SKINICONDESC sid = { sizeof(sid) };
+ sid.ptszSection = LPGENT("Ping");
+ sid.flags = SIDF_PATH_TCHAR;
+
+ sid.pszDescription = LPGEN("Responding");
+ sid.pszName = "ping_responding";
+ sid.ptszDefaultFile = file;
+ sid.iDefaultIndex = -IDI_ICON_RESPONDING;
+ Skin_AddIcon(&sid);
+
+ sid.pszDescription = LPGEN("Not Responding");
+ sid.pszName = "ping_not_responding";
+ sid.ptszDefaultFile = file;
+ sid.iDefaultIndex = -IDI_ICON_NOTRESPONDING;
+ Skin_AddIcon(&sid);
+
+ sid.pszDescription = LPGEN("Testing");
+ sid.pszName = "ping_testing";
+ sid.ptszDefaultFile = file;
+ sid.iDefaultIndex = -IDI_ICON_TESTING;
+ Skin_AddIcon(&sid);
+
+ sid.pszDescription = LPGEN("Disabled");
+ sid.pszName = "ping_disabled";
+ sid.ptszDefaultFile = file;
+ sid.iDefaultIndex = -IDI_ICON_DISABLED;
+ Skin_AddIcon(&sid);
+
+ hIconResponding = Skin_GetIcon("ping_responding");
+ hIconNotResponding = Skin_GetIcon("ping_not_responding");
+ hIconTesting = Skin_GetIcon("ping_testing");
+ hIconDisabled = Skin_GetIcon("ping_disabled");
+
+ hIcoLibIconsChanged = HookEvent(ME_SKIN2_ICONSCHANGED, ReloadIcons);
+
+ if (ServiceExists(MS_POPUP_REGISTERCLASS)) {
+ POPUPCLASS test = { sizeof(test) };
test.flags = PCF_TCHAR;
test.hIcon = hIconResponding;
test.iSeconds = -1;