[PATCH 5/7] uxtheme: Use COLOR_BTNFACE to fill scroll bar background.
Zhiyi Zhang
zzhang at codeweavers.com
Thu Feb 10 00:57:19 CST 2022
Signed-off-by: Zhiyi Zhang <zzhang at codeweavers.com>
---
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;
--
2.32.0
More information about the wine-devel
mailing list