summaryrefslogtreecommitdiff
path: root/plugins/UserInfoEx/src/svc_gender.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-11-19 12:51:53 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-11-19 12:51:53 +0000
commit32dedc767dec565c576b78b786e7a95d76ac806e (patch)
tree0f2eb209b3716569a8e3c3ef146a91f402ebbb4d /plugins/UserInfoEx/src/svc_gender.cpp
parentadf7367cfdb57b32aadeb74af45dce9a6a3c02a5 (diff)
- added another helper, ExtraIcon_Clear, to remove an icon from slot;
- added ability to pass IcoLib handles instead of icons' names git-svn-id: http://svn.miranda-ng.org/main/trunk@2371 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/UserInfoEx/src/svc_gender.cpp')
-rw-r--r--plugins/UserInfoEx/src/svc_gender.cpp17
1 files changed, 5 insertions, 12 deletions
diff --git a/plugins/UserInfoEx/src/svc_gender.cpp b/plugins/UserInfoEx/src/svc_gender.cpp
index 68d6f5b8ec..f849569644 100644
--- a/plugins/UserInfoEx/src/svc_gender.cpp
+++ b/plugins/UserInfoEx/src/svc_gender.cpp
@@ -81,20 +81,13 @@ BYTE GenderOf(HANDLE hContact)
static INT OnCListApplyIcons(HANDLE hContact, LPARAM)
{
if (ghExtraIconSvc != INVALID_HANDLE_VALUE) {
- EXTRAICON ico = { sizeof(ico) };
- ico.hContact = hContact;
- ico.hExtraIcon = ghExtraIconSvc;
+ char *icoName;
switch (GenderOf(hContact)) {
- case 'M':
- ico.icoName = ICO_COMMON_MALE;
- break;
- case 'F':
- ico.icoName = ICO_COMMON_FEMALE;
- break;
- default:
- ico.icoName = NULL;
+ case 'M': icoName = ICO_COMMON_MALE; break;
+ case 'F': icoName = ICO_COMMON_FEMALE; break;
+ default: icoName = NULL;
}
- CallService(MS_EXTRAICON_SET_ICON, (WPARAM)&ico, 0);
+ ExtraIcon_SetIcon(ghExtraIconSvc, hContact, icoName);
}
return 0;
}