comctl32/button: Do not restore groupbox font after themed painting.

Fix button tests failures when theming is on.

Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zhiyi Zhang 2021-10-01 11:29:30 +08:00 committed by Alexandre Julliard
parent 687d9d0bee
commit 1e7e31cab9
1 changed files with 2 additions and 2 deletions

View File

@ -2835,8 +2835,8 @@ static void GB_ThemedPaint(HTHEME theme, const BUTTON_INFO *infoPtr, HDC hDC, in
created_font = TRUE;
}
} else {
font = (HFONT)SendMessageW(infoPtr->hwnd, WM_GETFONT, 0, 0);
hPrevFont = SelectObject(hDC, font);
if (infoPtr->font)
SelectObject(hDC, infoPtr->font);
}
GetClientRect(infoPtr->hwnd, &bgRect);