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 1423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1434 const DeprecatedPaintLayer* ancestorLayer = rootLayerIsInsidePaginationL
ayer ? paginationParentLayer : rootLayer; | 1434 const DeprecatedPaintLayer* ancestorLayer = rootLayerIsInsidePaginationL
ayer ? paginationParentLayer : rootLayer; |
1435 ClipRectsContext clipRectsContext(ancestorLayer, clipRectsCacheSlot, inO
verlayScrollbarSizeRelevancy); | 1435 ClipRectsContext clipRectsContext(ancestorLayer, clipRectsCacheSlot, inO
verlayScrollbarSizeRelevancy); |
1436 if (respectOverflowClip == IgnoreOverflowClip) | 1436 if (respectOverflowClip == IgnoreOverflowClip) |
1437 clipRectsContext.setIgnoreOverflowClip(); | 1437 clipRectsContext.setIgnoreOverflowClip(); |
1438 ancestorClipRect = enclosingPaginationLayer()->clipper().backgroundClipR
ect(clipRectsContext); | 1438 ancestorClipRect = enclosingPaginationLayer()->clipper().backgroundClipR
ect(clipRectsContext); |
1439 if (rootLayerIsInsidePaginationLayer) | 1439 if (rootLayerIsInsidePaginationLayer) |
1440 ancestorClipRect.moveBy(-rootLayer->visualOffsetFromAncestor(ancesto
rLayer)); | 1440 ancestorClipRect.moveBy(-rootLayer->visualOffsetFromAncestor(ancesto
rLayer)); |
1441 ancestorClipRect.intersect(dirtyRect); | 1441 ancestorClipRect.intersect(dirtyRect); |
1442 } | 1442 } |
1443 | 1443 |
1444 const LayoutSize subPixelAccumulationIfNeeded = compositingState() == Paints
IntoOwnBacking ? LayoutSize() : subPixelAccumulation; | 1444 const LayoutSize subPixelAccumulationIfNeeded = offsetFromRoot ? subPixelAcc
umulation : LayoutSize(); |
1445 for (size_t i = 0; i < fragments.size(); ++i) { | 1445 for (size_t i = 0; i < fragments.size(); ++i) { |
1446 DeprecatedPaintLayerFragment& fragment = fragments.at(i); | 1446 DeprecatedPaintLayerFragment& fragment = fragments.at(i); |
1447 | 1447 |
1448 // Set our four rects with all clipping applied that was internal to the
flow thread. | 1448 // Set our four rects with all clipping applied that was internal to the
flow thread. |
1449 fragment.setRects(layerBoundsInFlowThread, backgroundRectInFlowThread, f
oregroundRectInFlowThread, outlineRectInFlowThread); | 1449 fragment.setRects(layerBoundsInFlowThread, backgroundRectInFlowThread, f
oregroundRectInFlowThread, outlineRectInFlowThread); |
1450 | 1450 |
1451 // Shift to the root-relative physical position used when painting the f
low thread in this fragment. | 1451 // Shift to the root-relative physical position used when painting the f
low thread in this fragment. |
1452 fragment.moveBy(fragment.paginationOffset + offsetOfPaginationLayerFromR
oot + subPixelAccumulationIfNeeded); | 1452 fragment.moveBy(fragment.paginationOffset + offsetOfPaginationLayerFromR
oot + subPixelAccumulationIfNeeded); |
1453 | 1453 |
1454 // Intersect the fragment with our ancestor's background clip so that e.
g., columns in an overflow:hidden block are | 1454 // Intersect the fragment with our ancestor's background clip so that e.
g., columns in an overflow:hidden block are |
(...skipping 1199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2654 | 2654 |
2655 void showLayerTree(const blink::LayoutObject* layoutObject) | 2655 void showLayerTree(const blink::LayoutObject* layoutObject) |
2656 { | 2656 { |
2657 if (!layoutObject) { | 2657 if (!layoutObject) { |
2658 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n"); | 2658 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n"); |
2659 return; | 2659 return; |
2660 } | 2660 } |
2661 showLayerTree(layoutObject->enclosingLayer()); | 2661 showLayerTree(layoutObject->enclosingLayer()); |
2662 } | 2662 } |
2663 #endif | 2663 #endif |
OLD | NEW |