Chromium Code Reviews| Index: Source/core/rendering/RenderBox.cpp |
| diff --git a/Source/core/rendering/RenderBox.cpp b/Source/core/rendering/RenderBox.cpp |
| index b1239206822ae5264809d81cf307f7e4b542dff4..721428684de0b3e23379d32242f20faf1f320717 100644 |
| --- a/Source/core/rendering/RenderBox.cpp |
| +++ b/Source/core/rendering/RenderBox.cpp |
| @@ -1569,6 +1569,19 @@ void RenderBox::invalidatePaintIfNeeded(const PaintInvalidationState& paintInval |
| setPreviousPaintInvalidationRect(boundsRectForPaintInvalidation(&newPaintInvalidationContainer, &paintInvalidationState)); |
| setPreviousPositionFromPaintInvalidationContainer(RenderLayer::positionFromPaintInvalidationContainer(this, &newPaintInvalidationContainer, &paintInvalidationState)); |
| + // Issue paint invalidations for any scrollbars if there is a scrollable area for this renderer. |
| + if (enclosingLayer()) { |
| + if (RenderLayerScrollableArea* area = enclosingLayer()->scrollableArea()) { |
| + if (!view()->doingFullRepaint()) { |
|
dsinclair
2014/07/22 19:55:22
This is really confusing. I wonder if the resetScr
Xianzhu
2014/07/23 00:18:13
Done.
|
| + if (area->hasVerticalBarDamage()) |
| + invalidatePaintRectangle(area->verticalBarDamage()); |
| + if (area->hasHorizontalBarDamage()) |
| + invalidatePaintRectangle(area->horizontalBarDamage()); |
| + } |
| + area->resetScrollbarDamage(); |
| + } |
| + } |
| + |
| // If we are set to do a full paint invalidation that means the RenderView will be |
| // issue paint invalidations. We can then skip issuing of paint invalidations for the child |
| // renderers as they'll be covered by the RenderView. |
| @@ -1585,16 +1598,6 @@ void RenderBox::invalidatePaintIfNeeded(const PaintInvalidationState& paintInval |
| if (!RenderObject::invalidatePaintIfNeeded(newPaintInvalidationContainer, oldPaintInvalidationRect, oldPositionFromPaintInvalidationContainer, paintInvalidationState)) |
| invalidatePaintForOverflowIfNeeded(); |
| - // Issue paint invalidations for any scrollbars if there is a scrollable area for this renderer. |
| - if (enclosingLayer()) { |
| - if (RenderLayerScrollableArea* area = enclosingLayer()->scrollableArea()) { |
| - if (area->hasVerticalBarDamage()) |
| - invalidatePaintRectangle(area->verticalBarDamage()); |
| - if (area->hasHorizontalBarDamage()) |
| - invalidatePaintRectangle(area->horizontalBarDamage()); |
| - area->resetScrollbarDamage(); |
| - } |
| - } |
| } |
| bool RenderBox::pushContentsClip(PaintInfo& paintInfo, const LayoutPoint& accumulatedOffset, ContentsClipBehavior contentsClipBehavior) |