From e63a40ee96d0f48215c6acc6689c1450ac060e8b Mon Sep 17 00:00:00 2001 From: Rob Farnum <rfarnum@mindspring.com> Date: Sat, 15 Jul 2000 19:45:43 +0000 Subject: [PATCH] Ignore iBitmap width when drawing flat toolbar. --- dlls/comctl32/toolbar.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/dlls/comctl32/toolbar.c b/dlls/comctl32/toolbar.c index 20330afbb3b..384f085753f 100644 --- a/dlls/comctl32/toolbar.c +++ b/dlls/comctl32/toolbar.c @@ -227,7 +227,12 @@ TOOLBAR_DrawButton (HWND hwnd, TBUTTON_INFO *btnPtr, HDC hdc) /* separator */ if (btnPtr->fsStyle & TBSTYLE_SEP) { - if ((dwStyle & TBSTYLE_FLAT) && (btnPtr->iBitmap == 0)) + /* with the FLAT style, iBitmap is the width and has already */ + /* been taken into consideration in calculating the width */ + /* so now we need to draw the vertical separator */ + /* empirical tests show that iBitmap can/will be non-zero */ + /* when drawing the vertical bar... */ + if ((dwStyle & TBSTYLE_FLAT) /* && (btnPtr->iBitmap == 0) */) TOOLBAR_DrawFlatSeparator (&rc, hdc); return; } -- GitLab