From d773919d989c02aa6939b9bdcbfe46efb2fccea9 Mon Sep 17 00:00:00 2001 From: "reed@reedloden.com" Date: Thu, 7 Feb 2008 00:56:38 -0800 Subject: [PATCH] Bug 385058 - "Grey marks (turds, remnants, ghosts) appear on scrollbars" (Redraw whole scrollbar when position changes) [p=mstange@themasta.com (Markus Stange) r+sr=roc a1.9=schrep] --- layout/xul/base/src/nsSliderFrame.cpp | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/layout/xul/base/src/nsSliderFrame.cpp b/layout/xul/base/src/nsSliderFrame.cpp index 7eaaeec43a1..e73d3beda67 100644 --- a/layout/xul/base/src/nsSliderFrame.cpp +++ b/layout/xul/base/src/nsSliderFrame.cpp @@ -658,15 +658,9 @@ nsSliderFrame::CurrentPositionChanged(nsPresContext* aPresContext, // set the rect thumbFrame->SetRect(newThumbRect); - // Figure out the union of the rect so we know what to redraw. - // Combine the old and new thumb overflow areas. - nsRect changeRect; - changeRect.UnionRect(thumbFrame->GetOverflowRect() + thumbRect.TopLeft(), - thumbFrame->GetOverflowRect() + newThumbRect.TopLeft()); + // Redraw the scrollbar + Invalidate(clientRect, aImmediateRedraw); - // redraw just the change - Invalidate(changeRect, aImmediateRedraw); - if (mScrollbarListener) mScrollbarListener->PositionChanged(aPresContext, mCurPos, curpospx);