From 44141ccc8e279bfd390b91f2f0b737b39da6481c Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 20 Nov 2012 18:41:56 +0000 Subject: automatic extra icon removal on dynamic plugin unloading git-svn-id: http://svn.miranda-ng.org/main/trunk@2399 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/UserInfoEx/src/svc_reminder.cpp | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'plugins/UserInfoEx/src/svc_reminder.cpp') diff --git a/plugins/UserInfoEx/src/svc_reminder.cpp b/plugins/UserInfoEx/src/svc_reminder.cpp index 660d2de23e..a3cc8e63cd 100644 --- a/plugins/UserInfoEx/src/svc_reminder.cpp +++ b/plugins/UserInfoEx/src/svc_reminder.cpp @@ -968,15 +968,9 @@ VOID SvcReminderEnable(BOOLEAN bEnable) { if (bEnable) // Reminder is on { - if (ExtraIcon == INVALID_HANDLE_VALUE) { - EXTRAICON_INFO ico = { sizeof(ico) }; - ico.type = EXTRAICON_TYPE_ICOLIB; - ico.name = "Reminder"; - ico.description = "Reminder (uinfoex)"; - ico.descIcon = ICO_COMMON_ANNIVERSARY; - ExtraIcon = (HANDLE)CallService(MS_EXTRAICON_REGISTER, (WPARAM)&ico, 0); - ZeroMemory(&ico,sizeof(ico)); - } + if (ExtraIcon == INVALID_HANDLE_VALUE) + ExtraIcon = ExtraIcon_Register("Reminder", "Reminder (uinfoex)", ICO_COMMON_ANNIVERSARY); + // init hooks if (!ghCListIA) ghCListIA = HookEvent(ME_CLIST_EXTRA_IMAGE_APPLY, (MIRANDAHOOK)OnCListApplyIcon); -- cgit v1.2.3