From 1b2485f4af2010f262bd4f6e149a8c2d96b893cc Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sat, 27 May 2006 12:48:31 +0000 Subject: Don't draw the shadow outside the scrollbar (should fix 'garbage' when moving the scrollbar) svn-id: r22680 --- gui/ThemeNew.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gui/ThemeNew.cpp b/gui/ThemeNew.cpp index d99116a4cc..94fc94a4db 100644 --- a/gui/ThemeNew.cpp +++ b/gui/ThemeNew.cpp @@ -830,13 +830,15 @@ void ThemeNew::drawScrollbar(const Common::Rect &r, int sliderY, int sliderHeigh } r2 = r; + r2.left += 1; + r2.right -= 1; r2.top += sliderY; - r2.bottom = r2.top + sliderHeight; + r2.bottom = r2.top + sliderHeight - 1; drawShadow(r2, surface(kSliderCorner), surface(kSliderTop), surface(kSliderLeft), surface(kSliderBkgd), kShadowSmall); - r2.left += 2; - r2.right -= 2; + r2.left += 1; + r2.right -= 1; r2.bottom = r2.top + sliderHeight / 2 + surface(kScrollbarCorner)->h + 4; drawRectMasked(r2, surface(kScrollbarCorner), surface(kScrollbarTop), surface(kScrollbarLeft), surface(kScrollbarBkgd), 256, -- cgit v1.2.3