comdlg32: Set the radiobuttons' font if they're part of a visual group.
Signed-off-by: Huw Davies <huw@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
00994524f5
commit
e77771c0bf
|
@ -1316,13 +1316,34 @@ static UINT ctrl_container_resize(FileDialogImpl *This, UINT container_width)
|
||||||
return container_height;
|
return container_height;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void ctrl_set_font(customctrl *ctrl, HFONT font)
|
||||||
|
{
|
||||||
|
customctrl *sub_ctrl;
|
||||||
|
cctrl_item* item;
|
||||||
|
|
||||||
|
SendMessageW(ctrl->hwnd, WM_SETFONT, (WPARAM)font, TRUE);
|
||||||
|
|
||||||
|
LIST_FOR_EACH_ENTRY(sub_ctrl, &ctrl->sub_cctrls, customctrl, sub_cctrls_entry)
|
||||||
|
{
|
||||||
|
ctrl_set_font(sub_ctrl, font);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ctrl->type == IDLG_CCTRL_RADIOBUTTONLIST)
|
||||||
|
{
|
||||||
|
LIST_FOR_EACH_ENTRY(item, &ctrl->sub_items, cctrl_item, entry)
|
||||||
|
{
|
||||||
|
SendMessageW(item->hwnd, WM_SETFONT, (WPARAM)font, TRUE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static void ctrl_container_reparent(FileDialogImpl *This, HWND parent)
|
static void ctrl_container_reparent(FileDialogImpl *This, HWND parent)
|
||||||
{
|
{
|
||||||
LONG wndstyle;
|
LONG wndstyle;
|
||||||
|
|
||||||
if(parent)
|
if(parent)
|
||||||
{
|
{
|
||||||
customctrl *ctrl, *sub_ctrl;
|
customctrl *ctrl;
|
||||||
HFONT font;
|
HFONT font;
|
||||||
|
|
||||||
wndstyle = GetWindowLongW(This->cctrls_hwnd, GWL_STYLE);
|
wndstyle = GetWindowLongW(This->cctrls_hwnd, GWL_STYLE);
|
||||||
|
@ -1340,23 +1361,7 @@ static void ctrl_container_reparent(FileDialogImpl *This, HWND parent)
|
||||||
|
|
||||||
LIST_FOR_EACH_ENTRY(ctrl, &This->cctrls, customctrl, entry)
|
LIST_FOR_EACH_ENTRY(ctrl, &This->cctrls, customctrl, entry)
|
||||||
{
|
{
|
||||||
if(font) SendMessageW(ctrl->hwnd, WM_SETFONT, (WPARAM)font, TRUE);
|
if(font) ctrl_set_font(ctrl, font);
|
||||||
|
|
||||||
/* If this is a VisualGroup */
|
|
||||||
LIST_FOR_EACH_ENTRY(sub_ctrl, &ctrl->sub_cctrls, customctrl, sub_cctrls_entry)
|
|
||||||
{
|
|
||||||
if(font) SendMessageW(sub_ctrl->hwnd, WM_SETFONT, (WPARAM)font, TRUE);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (ctrl->type == IDLG_CCTRL_RADIOBUTTONLIST)
|
|
||||||
{
|
|
||||||
cctrl_item* item;
|
|
||||||
LIST_FOR_EACH_ENTRY(item, &ctrl->sub_items, cctrl_item, entry)
|
|
||||||
{
|
|
||||||
if (font) SendMessageW(item->hwnd, WM_SETFONT, (WPARAM)font, TRUE);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
customctrl_resize(This, ctrl);
|
customctrl_resize(This, ctrl);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue