summaryrefslogtreecommitdiff
path: root/plugins/UserInfoEx/src/svc_gender.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-11-20 18:41:56 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-11-20 18:41:56 +0000
commit44141ccc8e279bfd390b91f2f0b737b39da6481c (patch)
treec3cee7cf5fde12c891c834272272b85911328198 /plugins/UserInfoEx/src/svc_gender.cpp
parentc5c8084eff5beffa9c007de67782b973f2c64fde (diff)
automatic extra icon removal on dynamic plugin unloading
git-svn-id: http://svn.miranda-ng.org/main/trunk@2399 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/UserInfoEx/src/svc_gender.cpp')
-rw-r--r--plugins/UserInfoEx/src/svc_gender.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/plugins/UserInfoEx/src/svc_gender.cpp b/plugins/UserInfoEx/src/svc_gender.cpp
index cf820a1ba4..7fe59908bd 100644
--- a/plugins/UserInfoEx/src/svc_gender.cpp
+++ b/plugins/UserInfoEx/src/svc_gender.cpp
@@ -141,14 +141,8 @@ VOID SvcGenderEnableExtraIcons(BYTE bColumn, BOOLEAN bUpdateDB)
DB::Setting::WriteByte(SET_CLIST_EXTRAICON_GENDER2, bColumn);
if (bEnable) { // Gender checkt or dropdown select
- if (ghExtraIconSvc == INVALID_HANDLE_VALUE) {
- EXTRAICON_INFO ico = { sizeof(ico) };
- ico.type = EXTRAICON_TYPE_ICOLIB;
- ico.name = "gender"; //must be the same as the group name in extraicon
- ico.description="Gender (uinfoex)";
- ico.descIcon = ICO_COMMON_MALE;
- ghExtraIconSvc = (HANDLE)CallService(MS_EXTRAICON_REGISTER, (WPARAM)&ico, 0);
- }
+ if (ghExtraIconSvc == INVALID_HANDLE_VALUE)
+ ghExtraIconSvc = ExtraIcon_Register("gender", "Gender (uinfoex)", ICO_COMMON_MALE);
// hook events
if (hChangedHook == NULL)