mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-03 01:12:51 +00:00
Duplicate the font handle passed through WM_SETFONT, because it does
not belong to us and is not ours to free.
This commit is contained in:
parent
2f2e4fab6c
commit
06effbf07a
|
@ -2187,8 +2187,11 @@ static LRESULT
|
|||
TOOLTIPS_SetFont (HWND hwnd, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
TOOLTIPS_INFO *infoPtr = TOOLTIPS_GetInfoPtr (hwnd);
|
||||
LOGFONTW lf;
|
||||
|
||||
infoPtr->hFont = (HFONT)wParam;
|
||||
if(!GetObjectW((HFONT)wParam, sizeof lf, &lf))
|
||||
return 0;
|
||||
infoPtr->hFont = CreateFontIndirectW(&lf);
|
||||
|
||||
if ((LOWORD(lParam)) & (infoPtr->nCurrentTool != -1)) {
|
||||
FIXME("full redraw needed!\n");
|
||||
|
|
Loading…
Reference in a new issue