OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
5 * | 5 * |
6 * Other contributors: | 6 * Other contributors: |
7 * Robert O'Callahan <roc+@cs.cmu.edu> | 7 * Robert O'Callahan <roc+@cs.cmu.edu> |
8 * David Baron <dbaron@fas.harvard.edu> | 8 * David Baron <dbaron@fas.harvard.edu> |
9 * Christian Biesinger <cbiesinger@web.de> | 9 * Christian Biesinger <cbiesinger@web.de> |
10 * Randall Jesup <rjesup@wgate.com> | 10 * Randall Jesup <rjesup@wgate.com> |
(...skipping 1103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1114 layer->convertToLayerCoords(rootLayerForTransform, delta); | 1114 layer->convertToLayerCoords(rootLayerForTransform, delta); |
1115 | 1115 |
1116 delta.move(subPixelAccumulation); | 1116 delta.move(subPixelAccumulation); |
1117 IntPoint pixelSnappedDelta = roundedIntPoint(delta); | 1117 IntPoint pixelSnappedDelta = roundedIntPoint(delta); |
1118 TransformationMatrix transform; | 1118 TransformationMatrix transform; |
1119 transform.translate(pixelSnappedDelta.x(), pixelSnappedDelta.y()); | 1119 transform.translate(pixelSnappedDelta.x(), pixelSnappedDelta.y()); |
1120 transform = transform * *layer->transform(); | 1120 transform = transform * *layer->transform(); |
1121 | 1121 |
1122 // We don't use fragment boxes when collecting a transformed layer's bou nding box, since it always | 1122 // We don't use fragment boxes when collecting a transformed layer's bou nding box, since it always |
1123 // paints unfragmented. | 1123 // paints unfragmented. |
1124 LayoutRect clipRect = layer->physicalBoundingBox(layer); | 1124 LayoutRect clipRect = layer->boundingBox(layer); |
1125 expandClipRectForDescendantsAndReflection(clipRect, layer, layer, transp arencyBehavior, subPixelAccumulation, paintBehavior); | 1125 expandClipRectForDescendantsAndReflection(clipRect, layer, layer, transp arencyBehavior, subPixelAccumulation, paintBehavior); |
1126 layer->renderer()->style()->filterOutsets().expandRect(clipRect); | 1126 layer->renderer()->style()->filterOutsets().expandRect(clipRect); |
1127 LayoutRect result = transform.mapRect(clipRect); | 1127 LayoutRect result = transform.mapRect(clipRect); |
1128 if (!paginationLayer) | 1128 if (!paginationLayer) |
1129 return result; | 1129 return result; |
1130 | 1130 |
1131 // We have to break up the transformed extent across our columns. | 1131 // We have to break up the transformed extent across our columns. |
1132 // Split our box up into the actual fragment boxes that render in the co lumns/pages and unite those together to | 1132 // Split our box up into the actual fragment boxes that render in the co lumns/pages and unite those together to |
1133 // get our true bounding box. | 1133 // get our true bounding box. |
1134 RenderFlowThread* enclosingFlowThread = toRenderFlowThread(paginationLay er->renderer()); | 1134 RenderFlowThread* enclosingFlowThread = toRenderFlowThread(paginationLay er->renderer()); |
1135 result = enclosingFlowThread->fragmentsBoundingBox(result); | 1135 result = enclosingFlowThread->fragmentsBoundingBox(result); |
1136 | 1136 |
1137 LayoutPoint rootLayerDelta; | 1137 LayoutPoint rootLayerDelta; |
1138 paginationLayer->convertToLayerCoords(rootLayer, rootLayerDelta); | 1138 paginationLayer->convertToLayerCoords(rootLayer, rootLayerDelta); |
1139 result.moveBy(rootLayerDelta); | 1139 result.moveBy(rootLayerDelta); |
1140 return result; | 1140 return result; |
1141 } | 1141 } |
1142 | 1142 |
1143 LayoutRect clipRect = layer->physicalBoundingBox(rootLayer); | 1143 LayoutRect clipRect = layer->fragmentedBoundingBox(rootLayer); |
1144 expandClipRectForDescendantsAndReflection(clipRect, layer, rootLayer, transp arencyBehavior, subPixelAccumulation, paintBehavior); | 1144 expandClipRectForDescendantsAndReflection(clipRect, layer, rootLayer, transp arencyBehavior, subPixelAccumulation, paintBehavior); |
1145 layer->renderer()->style()->filterOutsets().expandRect(clipRect); | 1145 layer->renderer()->style()->filterOutsets().expandRect(clipRect); |
1146 clipRect.move(subPixelAccumulation); | 1146 clipRect.move(subPixelAccumulation); |
1147 return clipRect; | 1147 return clipRect; |
1148 } | 1148 } |
1149 | 1149 |
1150 LayoutRect RenderLayer::paintingExtent(const RenderLayer* rootLayer, const Layou tRect& paintDirtyRect, const LayoutSize& subPixelAccumulation, PaintBehavior pai ntBehavior) | 1150 LayoutRect RenderLayer::paintingExtent(const RenderLayer* rootLayer, const Layou tRect& paintDirtyRect, const LayoutSize& subPixelAccumulation, PaintBehavior pai ntBehavior) |
1151 { | 1151 { |
1152 return intersection(transparencyClipBox(this, rootLayer, PaintingTransparenc yClipBox, RootOfTransparencyClipBox, subPixelAccumulation, paintBehavior), paint DirtyRect); | 1152 return intersection(transparencyClipBox(this, rootLayer, PaintingTransparenc yClipBox, RootOfTransparencyClipBox, subPixelAccumulation, paintBehavior), paint DirtyRect); |
1153 } | 1153 } |
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1405 | 1405 |
1406 const RenderLayer* currLayer = this; | 1406 const RenderLayer* currLayer = this; |
1407 while (currLayer && currLayer != ancestorLayer) | 1407 while (currLayer && currLayer != ancestorLayer) |
1408 currLayer = accumulateOffsetTowardsAncestor(currLayer, ancestorLayer, lo cation); | 1408 currLayer = accumulateOffsetTowardsAncestor(currLayer, ancestorLayer, lo cation); |
1409 } | 1409 } |
1410 | 1410 |
1411 void RenderLayer::convertToLayerCoords(const RenderLayer* ancestorLayer, LayoutR ect& rect) const | 1411 void RenderLayer::convertToLayerCoords(const RenderLayer* ancestorLayer, LayoutR ect& rect) const |
1412 { | 1412 { |
1413 LayoutPoint delta; | 1413 LayoutPoint delta; |
1414 convertToLayerCoords(ancestorLayer, delta); | 1414 convertToLayerCoords(ancestorLayer, delta); |
1415 rect.move(-delta.x(), -delta.y()); | 1415 rect.moveBy(delta); |
1416 } | 1416 } |
1417 | 1417 |
1418 void RenderLayer::didUpdateNeedsCompositedScrolling() | 1418 void RenderLayer::didUpdateNeedsCompositedScrolling() |
1419 { | 1419 { |
1420 updateSelfPaintingLayer(); | 1420 updateSelfPaintingLayer(); |
1421 } | 1421 } |
1422 | 1422 |
1423 void RenderLayer::updateReflectionInfo(const RenderStyle* oldStyle) | 1423 void RenderLayer::updateReflectionInfo(const RenderStyle* oldStyle) |
1424 { | 1424 { |
1425 ASSERT(!oldStyle || !renderer()->style()->reflectionDataEquivalent(oldStyle) ); | 1425 ASSERT(!oldStyle || !renderer()->style()->reflectionDataEquivalent(oldStyle) ); |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1479 if (respectOverflowClip == IgnoreOverflowClip) | 1479 if (respectOverflowClip == IgnoreOverflowClip) |
1480 paginationClipRectsContext.setIgnoreOverflowClip(); | 1480 paginationClipRectsContext.setIgnoreOverflowClip(); |
1481 LayoutRect layerBoundsInFlowThread; | 1481 LayoutRect layerBoundsInFlowThread; |
1482 ClipRect backgroundRectInFlowThread; | 1482 ClipRect backgroundRectInFlowThread; |
1483 ClipRect foregroundRectInFlowThread; | 1483 ClipRect foregroundRectInFlowThread; |
1484 ClipRect outlineRectInFlowThread; | 1484 ClipRect outlineRectInFlowThread; |
1485 clipper().calculateRects(paginationClipRectsContext, PaintInfo::infiniteRect (), layerBoundsInFlowThread, backgroundRectInFlowThread, foregroundRectInFlowThr ead, | 1485 clipper().calculateRects(paginationClipRectsContext, PaintInfo::infiniteRect (), layerBoundsInFlowThread, backgroundRectInFlowThread, foregroundRectInFlowThr ead, |
1486 outlineRectInFlowThread, &offsetWithinPaginatedLayer); | 1486 outlineRectInFlowThread, &offsetWithinPaginatedLayer); |
1487 | 1487 |
1488 // Take our bounding box within the flow thread and clip it. | 1488 // Take our bounding box within the flow thread and clip it. |
1489 LayoutRect layerBoundingBoxInFlowThread = layerBoundingBox ? *layerBoundingB ox : physicalBoundingBox(enclosingPaginationLayer(), &offsetWithinPaginatedLayer ); | 1489 LayoutRect layerBoundingBoxInFlowThread = layerBoundingBox ? *layerBoundingB ox : boundingBox(enclosingPaginationLayer(), &offsetWithinPaginatedLayer); |
1490 layerBoundingBoxInFlowThread.intersect(backgroundRectInFlowThread.rect()); | 1490 layerBoundingBoxInFlowThread.intersect(backgroundRectInFlowThread.rect()); |
1491 | 1491 |
1492 // Shift the dirty rect into flow thread coordinates. | 1492 // Shift the dirty rect into flow thread coordinates. |
1493 LayoutPoint offsetOfPaginationLayerFromRoot; | 1493 LayoutPoint offsetOfPaginationLayerFromRoot; |
1494 enclosingPaginationLayer()->convertToLayerCoords(rootLayer, offsetOfPaginati onLayerFromRoot); | 1494 enclosingPaginationLayer()->convertToLayerCoords(rootLayer, offsetOfPaginati onLayerFromRoot); |
1495 LayoutRect dirtyRectInFlowThread(dirtyRect); | 1495 LayoutRect dirtyRectInFlowThread(dirtyRect); |
1496 dirtyRectInFlowThread.moveBy(-offsetOfPaginationLayerFromRoot); | 1496 dirtyRectInFlowThread.moveBy(-offsetOfPaginationLayerFromRoot); |
1497 | 1497 |
1498 // Tell the flow thread to collect the fragments. We pass enough information to create a minimal number of fragments based off the pages/columns | 1498 // Tell the flow thread to collect the fragments. We pass enough information to create a minimal number of fragments based off the pages/columns |
1499 // that intersect the actual dirtyRect as well as the pages/columns that int ersect our layer's bounding box. | 1499 // that intersect the actual dirtyRect as well as the pages/columns that int ersect our layer's bounding box. |
(...skipping 679 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2179 // can go ahead and return true. | 2179 // can go ahead and return true. |
2180 RenderView* view = renderer()->view(); | 2180 RenderView* view = renderer()->view(); |
2181 ASSERT(view); | 2181 ASSERT(view); |
2182 if (view && !renderer()->isRenderInline()) { | 2182 if (view && !renderer()->isRenderInline()) { |
2183 if (layerBounds.intersects(damageRect)) | 2183 if (layerBounds.intersects(damageRect)) |
2184 return true; | 2184 return true; |
2185 } | 2185 } |
2186 | 2186 |
2187 // Otherwise we need to compute the bounding box of this single layer and se e if it intersects | 2187 // Otherwise we need to compute the bounding box of this single layer and se e if it intersects |
2188 // the damage rect. | 2188 // the damage rect. |
2189 return physicalBoundingBox(rootLayer, offsetFromRoot).intersects(damageRect) ; | 2189 return boundingBox(rootLayer, offsetFromRoot).intersects(damageRect); |
2190 } | 2190 } |
2191 | 2191 |
2192 LayoutRect RenderLayer::logicalBoundingBox() const | 2192 LayoutRect RenderLayer::logicalBoundingBox() const |
2193 { | 2193 { |
2194 // There are three special cases we need to consider. | 2194 // There are three special cases we need to consider. |
2195 // (1) Inline Flows. For inline flows we will create a bounding box that fu lly encompasses all of the lines occupied by the | 2195 // (1) Inline Flows. For inline flows we will create a bounding box that fu lly encompasses all of the lines occupied by the |
2196 // inline. In other words, if some <span> wraps to three lines, we'll creat e a bounding box that fully encloses the | 2196 // inline. In other words, if some <span> wraps to three lines, we'll creat e a bounding box that fully encloses the |
2197 // line boxes of all three lines (including overflow on those lines). | 2197 // line boxes of all three lines (including overflow on those lines). |
2198 // (2) Left/Top Overflow. The width/height of layers already includes right /bottom overflow. However, in the case of left/top | 2198 // (2) Left/Top Overflow. The width/height of layers already includes right /bottom overflow. However, in the case of left/top |
2199 // overflow, we have to create a bounding box that will extend to include th is overflow. | 2199 // overflow, we have to create a bounding box that will extend to include th is overflow. |
(...skipping 18 matching lines...) Expand all Loading... | |
2218 RenderBox* box = renderBox(); | 2218 RenderBox* box = renderBox(); |
2219 ASSERT(box); | 2219 ASSERT(box); |
2220 result = box->borderBoxRect(); | 2220 result = box->borderBoxRect(); |
2221 result.unite(box->visualOverflowRect()); | 2221 result.unite(box->visualOverflowRect()); |
2222 } | 2222 } |
2223 | 2223 |
2224 ASSERT(renderer()->view()); | 2224 ASSERT(renderer()->view()); |
2225 return result; | 2225 return result; |
2226 } | 2226 } |
2227 | 2227 |
2228 LayoutRect RenderLayer::physicalBoundingBox(const RenderLayer* ancestorLayer, co nst LayoutPoint* offsetFromRoot) const | 2228 LayoutRect RenderLayer::flippedLogicalBoundingBox() const |
2229 { | 2229 { |
2230 LayoutRect result = logicalBoundingBox(); | 2230 LayoutRect result = logicalBoundingBox(); |
2231 if (m_renderer->isBox()) | 2231 if (m_renderer->isBox()) |
2232 renderBox()->flipForWritingMode(result); | 2232 renderBox()->flipForWritingMode(result); |
2233 else | 2233 else |
2234 m_renderer->containingBlock()->flipForWritingMode(result); | 2234 m_renderer->containingBlock()->flipForWritingMode(result); |
2235 | |
2236 LayoutPoint delta; | |
2237 if (offsetFromRoot) | |
2238 delta = *offsetFromRoot; | |
2239 else | |
2240 convertToLayerCoords(ancestorLayer, delta); | |
2241 | |
2242 result.moveBy(delta); | |
2243 return result; | 2235 return result; |
2244 } | 2236 } |
2245 | 2237 |
2238 LayoutRect RenderLayer::boundingBox(const RenderLayer* ancestorLayer, const Layo utPoint* offsetFromRoot) const | |
2239 { | |
2240 LayoutRect result = flippedLogicalBoundingBox(); | |
2241 if (offsetFromRoot) | |
2242 result.moveBy(*offsetFromRoot); | |
2243 else | |
2244 convertToLayerCoords(ancestorLayer, result); | |
2245 return result; | |
2246 } | |
2247 | |
2248 LayoutRect RenderLayer::fragmentedBoundingBox(const RenderLayer* ancestorLayer, const LayoutPoint* offsetFromRoot) const | |
andersr
2014/10/02 11:01:21
Is fragmentsBoundingBox a better name? (Like Rende
rune
2014/10/02 11:17:34
Yes.
rune
2014/10/03 09:15:46
Done.
| |
2249 { | |
2250 if (!enclosingPaginationLayer()) | |
2251 return boundingBox(ancestorLayer, offsetFromRoot); | |
2252 | |
2253 LayoutRect result = flippedLogicalBoundingBox(); | |
2254 | |
2255 // Split our box up into the actual fragment boxes that render in the column s/pages and unite those together to | |
2256 // get our true bounding box. | |
2257 LayoutPoint offsetWithinPaginationLayer; | |
2258 convertToLayerCoords(enclosingPaginationLayer(), offsetWithinPaginationLayer ); | |
2259 result.moveBy(offsetWithinPaginationLayer); | |
2260 | |
2261 RenderFlowThread* enclosingFlowThread = toRenderFlowThread(enclosingPaginati onLayer()->renderer()); | |
2262 result = enclosingFlowThread->fragmentsBoundingBox(result); | |
2263 | |
mstensho (USE GERRIT)
2014/10/02 12:43:59
At this point, |result| is a nice visual rectangle
rune
2014/10/03 09:15:46
Done.
I also removed the offsetFromRoot pointer,
| |
2264 if (offsetFromRoot) | |
2265 result.moveBy(*offsetFromRoot); | |
2266 else | |
2267 convertToLayerCoords(ancestorLayer, result); | |
2268 return result; | |
2269 } | |
2270 | |
2246 static void expandRectForReflectionAndStackingChildren(const RenderLayer* ancest orLayer, RenderLayer::CalculateBoundsOptions options, LayoutRect& result) | 2271 static void expandRectForReflectionAndStackingChildren(const RenderLayer* ancest orLayer, RenderLayer::CalculateBoundsOptions options, LayoutRect& result) |
2247 { | 2272 { |
2248 if (ancestorLayer->reflectionInfo() && !ancestorLayer->reflectionInfo()->ref lectionLayer()->hasCompositedLayerMapping()) | 2273 if (ancestorLayer->reflectionInfo() && !ancestorLayer->reflectionInfo()->ref lectionLayer()->hasCompositedLayerMapping()) |
2249 result.unite(ancestorLayer->reflectionInfo()->reflectionLayer()->boundin gBoxForCompositing(ancestorLayer)); | 2274 result.unite(ancestorLayer->reflectionInfo()->reflectionLayer()->boundin gBoxForCompositing(ancestorLayer)); |
2250 | 2275 |
2251 ASSERT(ancestorLayer->stackingNode()->isStackingContext() || !ancestorLayer- >stackingNode()->hasPositiveZOrderList()); | 2276 ASSERT(ancestorLayer->stackingNode()->isStackingContext() || !ancestorLayer- >stackingNode()->hasPositiveZOrderList()); |
2252 | 2277 |
2253 #if ENABLE(ASSERT) | 2278 #if ENABLE(ASSERT) |
2254 LayerListMutationDetector mutationChecker(const_cast<RenderLayer*>(ancestorL ayer)->stackingNode()); | 2279 LayerListMutationDetector mutationChecker(const_cast<RenderLayer*>(ancestorL ayer)->stackingNode()); |
2255 #endif | 2280 #endif |
2256 | 2281 |
2257 RenderLayerStackingNodeIterator iterator(*ancestorLayer->stackingNode(), All Children); | 2282 RenderLayerStackingNodeIterator iterator(*ancestorLayer->stackingNode(), All Children); |
2258 while (RenderLayerStackingNode* node = iterator.next()) { | 2283 while (RenderLayerStackingNode* node = iterator.next()) { |
2259 // Here we exclude both directly composited layers and squashing layers | 2284 // Here we exclude both directly composited layers and squashing layers |
2260 // because those RenderLayers don't paint into the graphics layer | 2285 // because those RenderLayers don't paint into the graphics layer |
2261 // for this RenderLayer. For example, the bounds of squashed RenderLayer s | 2286 // for this RenderLayer. For example, the bounds of squashed RenderLayer s |
2262 // will be included in the computation of the appropriate squashing | 2287 // will be included in the computation of the appropriate squashing |
2263 // GraphicsLayer. | 2288 // GraphicsLayer. |
2264 if (options != RenderLayer::ApplyBoundsChickenEggHacks && node->layer()- >compositingState() != NotComposited) | 2289 if (options != RenderLayer::ApplyBoundsChickenEggHacks && node->layer()- >compositingState() != NotComposited) |
2265 continue; | 2290 continue; |
2266 result.unite(node->layer()->boundingBoxForCompositing(ancestorLayer, opt ions)); | 2291 result.unite(node->layer()->boundingBoxForCompositing(ancestorLayer, opt ions)); |
2267 } | 2292 } |
2268 } | 2293 } |
2269 | 2294 |
2270 LayoutRect RenderLayer::physicalBoundingBoxIncludingReflectionAndStackingChildre n(const RenderLayer* ancestorLayer, const LayoutPoint& offsetFromRoot) const | 2295 LayoutRect RenderLayer::boundingBoxIncludingReflectionAndStackingChildren(const RenderLayer* ancestorLayer, const LayoutPoint& offsetFromRoot) const |
2271 { | 2296 { |
2272 LayoutPoint origin; | 2297 LayoutPoint origin; |
2273 LayoutRect result = physicalBoundingBox(ancestorLayer, &origin); | 2298 LayoutRect result = boundingBox(ancestorLayer, &origin); |
2274 | 2299 |
2275 const_cast<RenderLayer*>(this)->stackingNode()->updateLayerListsIfNeeded(); | 2300 const_cast<RenderLayer*>(this)->stackingNode()->updateLayerListsIfNeeded(); |
2276 | 2301 |
2277 expandRectForReflectionAndStackingChildren(this, DoNotApplyBoundsChickenEggH acks, result); | 2302 expandRectForReflectionAndStackingChildren(this, DoNotApplyBoundsChickenEggH acks, result); |
2278 | 2303 |
2279 result.moveBy(offsetFromRoot); | 2304 result.moveBy(offsetFromRoot); |
2280 return result; | 2305 return result; |
2281 } | 2306 } |
2282 | 2307 |
2283 LayoutRect RenderLayer::boundingBoxForCompositing(const RenderLayer* ancestorLay er, CalculateBoundsOptions options) const | 2308 LayoutRect RenderLayer::boundingBoxForCompositing(const RenderLayer* ancestorLay er, CalculateBoundsOptions options) const |
(...skipping 25 matching lines...) Expand all Loading... | |
2309 if (shouldIncludeTransform) | 2334 if (shouldIncludeTransform) |
2310 localClipRect = transform()->mapRect(localClipRect); | 2335 localClipRect = transform()->mapRect(localClipRect); |
2311 | 2336 |
2312 LayoutPoint delta; | 2337 LayoutPoint delta; |
2313 convertToLayerCoords(ancestorLayer, delta); | 2338 convertToLayerCoords(ancestorLayer, delta); |
2314 localClipRect.moveBy(delta); | 2339 localClipRect.moveBy(delta); |
2315 return localClipRect; | 2340 return localClipRect; |
2316 } | 2341 } |
2317 | 2342 |
2318 LayoutPoint origin; | 2343 LayoutPoint origin; |
2319 LayoutRect result = physicalBoundingBox(ancestorLayer, &origin); | 2344 LayoutRect result = boundingBox(ancestorLayer, &origin); |
2320 | 2345 |
2321 const_cast<RenderLayer*>(this)->stackingNode()->updateLayerListsIfNeeded(); | 2346 const_cast<RenderLayer*>(this)->stackingNode()->updateLayerListsIfNeeded(); |
2322 | 2347 |
2323 // Reflections are implemented with RenderLayers that hang off of the reflec ted layer. However, | 2348 // Reflections are implemented with RenderLayers that hang off of the reflec ted layer. However, |
2324 // the reflection layer subtree does not include the subtree of the parent R enderLayer, so | 2349 // the reflection layer subtree does not include the subtree of the parent R enderLayer, so |
2325 // a recursive computation of stacking children yields no results. This brea ks cases when there are stacking | 2350 // a recursive computation of stacking children yields no results. This brea ks cases when there are stacking |
2326 // children of the parent, that need to be included in reflected composited bounds. | 2351 // children of the parent, that need to be included in reflected composited bounds. |
2327 // Fix this by including composited bounds of stacking children of the refle cted RenderLayer. | 2352 // Fix this by including composited bounds of stacking children of the refle cted RenderLayer. |
2328 if (hasCompositedLayerMapping() && parent() && parent()->reflectionInfo() && parent()->reflectionInfo()->reflectionLayer() == this) | 2353 if (hasCompositedLayerMapping() && parent() && parent()->reflectionInfo() && parent()->reflectionInfo()->reflectionLayer() == this) |
2329 expandRectForReflectionAndStackingChildren(parent(), options, result); | 2354 expandRectForReflectionAndStackingChildren(parent(), options, result); |
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2802 // as well as they may be on another composited layer. Skip reportin g contents | 2827 // as well as they may be on another composited layer. Skip reportin g contents |
2803 // for non-composited layers as they'll get projected to the same la yer as the | 2828 // for non-composited layers as they'll get projected to the same la yer as the |
2804 // bounding box. | 2829 // bounding box. |
2805 if (compositingState() != NotComposited) | 2830 if (compositingState() != NotComposited) |
2806 rect.append(m_scrollableArea->overflowRect()); | 2831 rect.append(m_scrollableArea->overflowRect()); |
2807 | 2832 |
2808 rects.set(this, rect); | 2833 rects.set(this, rect); |
2809 if (const RenderLayer* parentLayer = parent()) { | 2834 if (const RenderLayer* parentLayer = parent()) { |
2810 LayerHitTestRects::iterator iter = rects.find(parentLayer); | 2835 LayerHitTestRects::iterator iter = rects.find(parentLayer); |
2811 if (iter == rects.end()) { | 2836 if (iter == rects.end()) { |
2812 rects.add(parentLayer, Vector<LayoutRect>()).storedValue->va lue.append(physicalBoundingBox(parentLayer)); | 2837 rects.add(parentLayer, Vector<LayoutRect>()).storedValue->va lue.append(boundingBox(parentLayer)); |
2813 } else { | 2838 } else { |
2814 iter->value.append(physicalBoundingBox(parentLayer)); | 2839 iter->value.append(boundingBox(parentLayer)); |
2815 } | 2840 } |
2816 } | 2841 } |
2817 } else { | 2842 } else { |
2818 rect.append(logicalBoundingBox()); | 2843 rect.append(logicalBoundingBox()); |
2819 rects.set(this, rect); | 2844 rects.set(this, rect); |
2820 } | 2845 } |
2821 } | 2846 } |
2822 } | 2847 } |
2823 | 2848 |
2824 void RenderLayer::setShouldDoFullPaintInvalidationIncludingNonCompositingDescend ants() | 2849 void RenderLayer::setShouldDoFullPaintInvalidationIncludingNonCompositingDescend ants() |
(...skipping 26 matching lines...) Expand all Loading... | |
2851 } | 2876 } |
2852 } | 2877 } |
2853 | 2878 |
2854 void showLayerTree(const blink::RenderObject* renderer) | 2879 void showLayerTree(const blink::RenderObject* renderer) |
2855 { | 2880 { |
2856 if (!renderer) | 2881 if (!renderer) |
2857 return; | 2882 return; |
2858 showLayerTree(renderer->enclosingLayer()); | 2883 showLayerTree(renderer->enclosingLayer()); |
2859 } | 2884 } |
2860 #endif | 2885 #endif |
OLD | NEW |