OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. |
7 * All rights reserved. | 7 * All rights reserved. |
8 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 8 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 2239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2250 return false; | 2250 return false; |
2251 | 2251 |
2252 // If the box has clip or mask, we need issue paint invalidation to cover | 2252 // If the box has clip or mask, we need issue paint invalidation to cover |
2253 // the changed part of children when the box got resized. In SPv2 this is | 2253 // the changed part of children when the box got resized. In SPv2 this is |
2254 // handled by detecting paint property changes. | 2254 // handled by detecting paint property changes. |
2255 if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { | 2255 if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled()) { |
2256 if (hasClipRelatedProperty() || hasControlClip() || hasMask()) | 2256 if (hasClipRelatedProperty() || hasControlClip() || hasMask()) |
2257 return false; | 2257 return false; |
2258 } | 2258 } |
2259 | 2259 |
| 2260 // If the box paints into its own backing, we can assume that it's painting |
| 2261 // may have some effect. For example, honoring the border-radius clip on |
| 2262 // a composited child paints into a mask for an otherwise non-painting |
| 2263 // element, because children of that element will require the mask. |
| 2264 if (hasLayer() && layer()->compositingState() == PaintsIntoOwnBacking) |
| 2265 return false; |
| 2266 |
2260 return true; | 2267 return true; |
2261 } | 2268 } |
2262 | 2269 |
2263 LayoutRect LayoutBox::localVisualRect() const { | 2270 LayoutRect LayoutBox::localVisualRect() const { |
2264 if (style()->visibility() != EVisibility::Visible) | 2271 if (style()->visibility() != EVisibility::Visible) |
2265 return LayoutRect(); | 2272 return LayoutRect(); |
2266 | 2273 |
2267 if (hasMask() && !RuntimeEnabledFeatures::slimmingPaintV2Enabled()) | 2274 if (hasMask() && !RuntimeEnabledFeatures::slimmingPaintV2Enabled()) |
2268 return LayoutRect(layer()->boxForFilterOrMask()); | 2275 return LayoutRect(layer()->boxForFilterOrMask()); |
2269 return selfVisualOverflowRect(); | 2276 return selfVisualOverflowRect(); |
(...skipping 3382 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5652 LayoutRect rect = frameRect(); | 5659 LayoutRect rect = frameRect(); |
5653 | 5660 |
5654 LayoutBlock* block = containingBlock(); | 5661 LayoutBlock* block = containingBlock(); |
5655 if (block) | 5662 if (block) |
5656 block->adjustChildDebugRect(rect); | 5663 block->adjustChildDebugRect(rect); |
5657 | 5664 |
5658 return rect; | 5665 return rect; |
5659 } | 5666 } |
5660 | 5667 |
5661 } // namespace blink | 5668 } // namespace blink |
OLD | NEW |