Zhiyi Zhang : uxtheme: Use COLOR_BTNFACE to fill scroll bar background.
Alexandre Julliard
julliard at winehq.org
Thu Feb 10 16:10:30 CST 2022
Module: wine
Branch: master
Commit: 19a77a8b6a71f349e630f532330635202c2179bb
URL: https://source.winehq.org/git/wine.git/?a=commit;h=19a77a8b6a71f349e630f532330635202c2179bb
Author: Zhiyi Zhang <zzhang at codeweavers.com>
Date: Thu Feb 10 14:57:19 2022 +0800
uxtheme: Use COLOR_BTNFACE to fill scroll bar background.
Signed-off-by: Zhiyi Zhang <zzhang at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/comctl32/tests/misc.c | 4 ++--
dlls/user32/tests/scroll.c | 1 -
dlls/uxtheme/scrollbar.c | 5 +++--
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/dlls/comctl32/tests/misc.c b/dlls/comctl32/tests/misc.c
index 069d1200c82..2fe6ad68426 100644
--- a/dlls/comctl32/tests/misc.c
+++ b/dlls/comctl32/tests/misc.c
@@ -888,8 +888,8 @@ static void test_themed_background(void)
{WC_TREEVIEWA, 0, treeview_seq},
{UPDOWN_CLASSA, 0, empty_seq},
{WC_SCROLLBARA, 0, scrollbar_seq, TRUE},
- {WC_SCROLLBARA, SBS_SIZEBOX, empty_seq, TRUE},
- {WC_SCROLLBARA, SBS_SIZEGRIP, empty_seq, TRUE},
+ {WC_SCROLLBARA, SBS_SIZEBOX, empty_seq},
+ {WC_SCROLLBARA, SBS_SIZEGRIP, empty_seq},
};
uxtheme = LoadLibraryA("uxtheme.dll");
diff --git a/dlls/user32/tests/scroll.c b/dlls/user32/tests/scroll.c
index 154d3c8d434..57bf759879c 100644
--- a/dlls/user32/tests/scroll.c
+++ b/dlls/user32/tests/scroll.c
@@ -802,7 +802,6 @@ static void test_visual(void)
hdc = GetDC(hwnd);
color = GetPixel(hdc, 5, 5);
- todo_wine_if(bThemeActive)
ok(color == colors[1], "Expected color %#x, got %#x.\n", colors[1], color);
ReleaseDC(hwnd, hdc);
diff --git a/dlls/uxtheme/scrollbar.c b/dlls/uxtheme/scrollbar.c
index 0e42de7d77f..e96e5e89b69 100644
--- a/dlls/uxtheme/scrollbar.c
+++ b/dlls/uxtheme/scrollbar.c
@@ -62,8 +62,9 @@ void WINAPI UXTHEME_ScrollBarDraw(HWND hwnd, HDC dc, INT bar, enum SCROLL_HITTES
else
state = SZB_RIGHTALIGN;
- if (IsThemeBackgroundPartiallyTransparent(theme, SBP_SIZEBOX, state))
- DrawThemeParentBackground(hwnd, dc, NULL);
+ /* Tests show that COLOR_BTNFACE is used instead of DrawThemeParentBackground() for drawing
+ * background */
+ FillRect(dc, rect, GetSysColorBrush(COLOR_BTNFACE));
DrawThemeBackground(theme, dc, SBP_SIZEBOX, state, rect, NULL);
} else {
int uppertrackstate, lowertrackstate, thumbstate;
More information about the wine-cvs
mailing list