Fixed icon leak.
This commit is contained in:
parent
7ca0381e7a
commit
4f6a1d3475
|
@ -246,6 +246,8 @@ void SYSTRAY_ItemSetMessage(SystrayItem *ptrayItem, UINT uCallbackMessage)
|
|||
|
||||
void SYSTRAY_ItemSetIcon(SystrayItem *ptrayItem, HICON hIcon)
|
||||
{
|
||||
if(ptrayItem->notifyIcon.hIcon)
|
||||
DestroyIcon(ptrayItem->notifyIcon.hIcon);
|
||||
ptrayItem->notifyIcon.hIcon = CopyIcon(hIcon);
|
||||
InvalidateRect(ptrayItem->hWnd, NULL, TRUE);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue