Free allocated font handles when control is destroyed.
This commit is contained in:
parent
ce70daf3ec
commit
a1f3756daa
|
@ -1637,6 +1637,8 @@ static LRESULT WINAPI SysLinkWindowProc(HWND hwnd, UINT message,
|
||||||
case WM_DESTROY:
|
case WM_DESTROY:
|
||||||
TRACE("SysLink Ctrl destruction, hwnd=%p\n", hwnd);
|
TRACE("SysLink Ctrl destruction, hwnd=%p\n", hwnd);
|
||||||
SYSLINK_ClearDoc(infoPtr);
|
SYSLINK_ClearDoc(infoPtr);
|
||||||
|
if(infoPtr->Font != 0) DeleteObject(infoPtr->Font);
|
||||||
|
if(infoPtr->LinkFont != 0) DeleteObject(infoPtr->LinkFont);
|
||||||
SYSLINK_Free (infoPtr);
|
SYSLINK_Free (infoPtr);
|
||||||
SetWindowLongPtrW(hwnd, 0, 0);
|
SetWindowLongPtrW(hwnd, 0, 0);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Reference in New Issue