uxtheme: Send WM_THEMECHANGED instead of posting it in SetWindowTheme().

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51348
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
(cherry picked from commit fe257dde58)
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
This commit is contained in:
Zhiyi Zhang 2021-07-02 11:36:59 +08:00 committed by Michael Stefaniuc
parent 6b501df752
commit 46390286f0
2 changed files with 3 additions and 3 deletions

View File

@ -685,7 +685,7 @@ HRESULT WINAPI SetWindowTheme(HWND hwnd, LPCWSTR pszSubAppName,
if(SUCCEEDED(hr))
hr = UXTHEME_SetWindowProperty(hwnd, atSubIdList, pszSubIdList);
if(SUCCEEDED(hr))
UXTHEME_broadcast_msg (hwnd, WM_THEMECHANGED);
SendMessageW(hwnd, WM_THEMECHANGED, 0, 0);
return hr;
}

View File

@ -237,8 +237,8 @@ todo_wine
}
DispatchMessageA(&msg);
}
ok_sequence(sequences, PARENT_SEQ_INDEX, SetWindowThemeSeq, "SetWindowTheme parent", TRUE);
ok_sequence(sequences, CHILD_SEQ_INDEX, EmptySeq, "SetWindowTheme child", TRUE);
ok_sequence(sequences, PARENT_SEQ_INDEX, SetWindowThemeSeq, "SetWindowTheme parent", FALSE);
ok_sequence(sequences, CHILD_SEQ_INDEX, EmptySeq, "SetWindowTheme child", FALSE);
DestroyWindow(hWnd);
UnregisterClassA("TestSetWindowThemeParentClass", GetModuleHandleA(0));
UnregisterClassA("TestSetWindowThemeChildClass", GetModuleHandleA(0));