comctl32/taskdialog: Use per-window dpi settings.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Nikolay Sivov 2018-07-17 14:13:06 +03:00 committed by Alexandre Julliard
parent 40298cc69a
commit 6292c0abdc
1 changed files with 2 additions and 2 deletions

View File

@ -316,8 +316,8 @@ static void taskdialog_get_radio_button_size(struct taskdialog_info *dialog_info
hfont = (HFONT)SendMessageW(hwnd, WM_GETFONT, 0, 0);
old_hfont = SelectObject(hdc, hfont);
radio_box_width = 12 * GetDeviceCaps(hdc, LOGPIXELSX) / 96 + 1;
radio_box_height = 12 * GetDeviceCaps(hdc, LOGPIXELSY) / 96 + 1;
radio_box_width = 12 * GetDpiForWindow(hwnd) / 96 + 1;
radio_box_height = 12 * GetDpiForWindow(hwnd) / 96 + 1;
GetCharWidthW(hdc, '0', '0', &text_offset);
text_offset /= 2;