OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
516 compositor->needsFixedRootBackgroundLayer(&m_owningLayer)); | 516 compositor->needsFixedRootBackgroundLayer(&m_owningLayer)); |
517 | 517 |
518 // The background layer is currently only used for fixed root backgrounds. | 518 // The background layer is currently only used for fixed root backgrounds. |
519 if (updateBackgroundLayer(m_backgroundLayerPaintsFixedRootBackground)) | 519 if (updateBackgroundLayer(m_backgroundLayerPaintsFixedRootBackground)) |
520 layerConfigChanged = true; | 520 layerConfigChanged = true; |
521 | 521 |
522 if (updateForegroundLayer( | 522 if (updateForegroundLayer( |
523 compositor->needsContentsCompositingLayer(&m_owningLayer))) | 523 compositor->needsContentsCompositingLayer(&m_owningLayer))) |
524 layerConfigChanged = true; | 524 layerConfigChanged = true; |
525 | 525 |
526 // The decoration layer is currently only used for painting outline | |
527 if (updateDecorationLayer(layoutObject->style()->hasOutline())) | |
flackr
2016/10/24 17:19:30
I don't think this condition is specific enough. W
yigu
2016/10/24 20:31:36
Done.
| |
528 layerConfigChanged = true; | |
529 | |
526 bool needsDescendantsClippingLayer = | 530 bool needsDescendantsClippingLayer = |
527 compositor->clipsCompositingDescendants(&m_owningLayer); | 531 compositor->clipsCompositingDescendants(&m_owningLayer); |
528 | 532 |
529 // Our scrolling layer will clip. | 533 // Our scrolling layer will clip. |
530 if (m_owningLayer.needsCompositedScrolling()) | 534 if (m_owningLayer.needsCompositedScrolling()) |
531 needsDescendantsClippingLayer = false; | 535 needsDescendantsClippingLayer = false; |
532 | 536 |
533 // We disable clipping on ancestor layers of the root scroller to give it | 537 // We disable clipping on ancestor layers of the root scroller to give it |
534 // the same behavior w.r.t top controls as the real root layer. See the | 538 // the same behavior w.r.t top controls as the real root layer. See the |
535 // RootScrollerController class for more details. | 539 // RootScrollerController class for more details. |
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
937 clippingBox = clipBox(toLayoutBox(layoutObject())); | 941 clippingBox = clipBox(toLayoutBox(layoutObject())); |
938 | 942 |
939 updateChildTransformLayerGeometry(); | 943 updateChildTransformLayerGeometry(); |
940 updateChildContainmentLayerGeometry(clippingBox, localCompositingBounds); | 944 updateChildContainmentLayerGeometry(clippingBox, localCompositingBounds); |
941 | 945 |
942 updateMaskLayerGeometry(); | 946 updateMaskLayerGeometry(); |
943 updateTransformGeometry(snappedOffsetFromCompositedAncestor, | 947 updateTransformGeometry(snappedOffsetFromCompositedAncestor, |
944 relativeCompositingBounds); | 948 relativeCompositingBounds); |
945 updateForegroundLayerGeometry(contentsSize, clippingBox); | 949 updateForegroundLayerGeometry(contentsSize, clippingBox); |
946 updateBackgroundLayerGeometry(contentsSize); | 950 updateBackgroundLayerGeometry(contentsSize); |
951 updateDecorationLayerGeometry(contentsSize); | |
947 updateScrollingLayerGeometry(localCompositingBounds); | 952 updateScrollingLayerGeometry(localCompositingBounds); |
948 updateChildClippingMaskLayerGeometry(); | 953 updateChildClippingMaskLayerGeometry(); |
949 | 954 |
950 if (m_owningLayer.getScrollableArea() && | 955 if (m_owningLayer.getScrollableArea() && |
951 m_owningLayer.getScrollableArea()->scrollsOverflow()) | 956 m_owningLayer.getScrollableArea()->scrollsOverflow()) |
952 m_owningLayer.getScrollableArea()->positionOverflowControls(); | 957 m_owningLayer.getScrollableArea()->positionOverflowControls(); |
953 | 958 |
954 updateLayerBlendMode(layoutObject()->styleRef()); | 959 updateLayerBlendMode(layoutObject()->styleRef()); |
955 updateIsRootForIsolatedGroup(); | 960 updateIsRootForIsolatedGroup(); |
956 updateContentsRect(); | 961 updateContentsRect(); |
(...skipping 407 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1364 } | 1369 } |
1365 m_backgroundLayer->setPosition(FloatPoint()); | 1370 m_backgroundLayer->setPosition(FloatPoint()); |
1366 if (backgroundSize != m_backgroundLayer->size()) { | 1371 if (backgroundSize != m_backgroundLayer->size()) { |
1367 m_backgroundLayer->setSize(backgroundSize); | 1372 m_backgroundLayer->setSize(backgroundSize); |
1368 m_backgroundLayer->setNeedsDisplay(); | 1373 m_backgroundLayer->setNeedsDisplay(); |
1369 } | 1374 } |
1370 m_backgroundLayer->setOffsetFromLayoutObject( | 1375 m_backgroundLayer->setOffsetFromLayoutObject( |
1371 m_graphicsLayer->offsetFromLayoutObject()); | 1376 m_graphicsLayer->offsetFromLayoutObject()); |
1372 } | 1377 } |
1373 | 1378 |
1379 void CompositedLayerMapping::updateDecorationLayerGeometry( | |
1380 const FloatSize& relativeCompositingBoundsSize) { | |
1381 if (!m_decorationLayer) | |
1382 return; | |
1383 FloatSize decorationSize = relativeCompositingBoundsSize; | |
1384 m_decorationLayer->setPosition(FloatPoint()); | |
1385 if (decorationSize != m_decorationLayer->size()) { | |
1386 m_decorationLayer->setSize(decorationSize); | |
1387 m_decorationLayer->setNeedsDisplay(); | |
1388 } | |
1389 m_decorationLayer->setOffsetFromLayoutObject( | |
1390 m_graphicsLayer->offsetFromLayoutObject()); | |
1391 } | |
1392 | |
1374 void CompositedLayerMapping::registerScrollingLayers() { | 1393 void CompositedLayerMapping::registerScrollingLayers() { |
1375 // Register fixed position layers and their containers with the scrolling | 1394 // Register fixed position layers and their containers with the scrolling |
1376 // coordinator. | 1395 // coordinator. |
1377 ScrollingCoordinator* scrollingCoordinator = | 1396 ScrollingCoordinator* scrollingCoordinator = |
1378 scrollingCoordinatorFromLayer(m_owningLayer); | 1397 scrollingCoordinatorFromLayer(m_owningLayer); |
1379 if (!scrollingCoordinator) | 1398 if (!scrollingCoordinator) |
1380 return; | 1399 return; |
1381 | 1400 |
1382 scrollingCoordinator->updateLayerPositionConstraint(&m_owningLayer); | 1401 scrollingCoordinator->updateLayerPositionConstraint(&m_owningLayer); |
1383 | 1402 |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1431 .containerLayer(); | 1450 .containerLayer(); |
1432 updateBottomLayer(m_overflowControlsAncestorClippingLayer.get()); | 1451 updateBottomLayer(m_overflowControlsAncestorClippingLayer.get()); |
1433 updateBottomLayer(m_overflowControlsHostLayer.get()); | 1452 updateBottomLayer(m_overflowControlsHostLayer.get()); |
1434 if (m_layerForHorizontalScrollbar) | 1453 if (m_layerForHorizontalScrollbar) |
1435 m_overflowControlsHostLayer->addChild(m_layerForHorizontalScrollbar.get()); | 1454 m_overflowControlsHostLayer->addChild(m_layerForHorizontalScrollbar.get()); |
1436 if (m_layerForVerticalScrollbar) | 1455 if (m_layerForVerticalScrollbar) |
1437 m_overflowControlsHostLayer->addChild(m_layerForVerticalScrollbar.get()); | 1456 m_overflowControlsHostLayer->addChild(m_layerForVerticalScrollbar.get()); |
1438 if (m_layerForScrollCorner) | 1457 if (m_layerForScrollCorner) |
1439 m_overflowControlsHostLayer->addChild(m_layerForScrollCorner.get()); | 1458 m_overflowControlsHostLayer->addChild(m_layerForScrollCorner.get()); |
1440 | 1459 |
1460 // Now add the DecorationLayer as a subtree to GraphicsLayer | |
1461 bottomLayer = m_graphicsLayer.get(); | |
1462 updateBottomLayer(m_decorationLayer.get()); | |
1463 | |
1441 // The squashing containment layer, if it exists, becomes a no-op parent. | 1464 // The squashing containment layer, if it exists, becomes a no-op parent. |
1442 if (m_squashingLayer) { | 1465 if (m_squashingLayer) { |
1443 ASSERT((m_ancestorClippingLayer && !m_squashingContainmentLayer) || | 1466 ASSERT((m_ancestorClippingLayer && !m_squashingContainmentLayer) || |
1444 (!m_ancestorClippingLayer && m_squashingContainmentLayer)); | 1467 (!m_ancestorClippingLayer && m_squashingContainmentLayer)); |
1445 | 1468 |
1446 if (m_squashingContainmentLayer) { | 1469 if (m_squashingContainmentLayer) { |
1447 m_squashingContainmentLayer->removeAllChildren(); | 1470 m_squashingContainmentLayer->removeAllChildren(); |
1448 m_squashingContainmentLayer->addChild(m_graphicsLayer.get()); | 1471 m_squashingContainmentLayer->addChild(m_graphicsLayer.get()); |
1449 m_squashingContainmentLayer->addChild(m_squashingLayer.get()); | 1472 m_squashingContainmentLayer->addChild(m_squashingLayer.get()); |
1450 } else { | 1473 } else { |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1565 } | 1588 } |
1566 | 1589 |
1567 // FIXME: we could refine this to only allocate backings for one of these | 1590 // FIXME: we could refine this to only allocate backings for one of these |
1568 // layers if possible. | 1591 // layers if possible. |
1569 if (m_foregroundLayer) | 1592 if (m_foregroundLayer) |
1570 m_foregroundLayer->setDrawsContent(hasPaintedContent); | 1593 m_foregroundLayer->setDrawsContent(hasPaintedContent); |
1571 | 1594 |
1572 if (m_backgroundLayer) | 1595 if (m_backgroundLayer) |
1573 m_backgroundLayer->setDrawsContent(hasPaintedContent); | 1596 m_backgroundLayer->setDrawsContent(hasPaintedContent); |
1574 | 1597 |
1598 if (m_decorationLayer) | |
1599 m_decorationLayer->setDrawsContent(hasPaintedContent); | |
1600 | |
1575 if (m_maskLayer) | 1601 if (m_maskLayer) |
1576 m_maskLayer->setDrawsContent(true); | 1602 m_maskLayer->setDrawsContent(true); |
1577 | 1603 |
1578 if (m_childClippingMaskLayer) | 1604 if (m_childClippingMaskLayer) |
1579 m_childClippingMaskLayer->setDrawsContent(true); | 1605 m_childClippingMaskLayer->setDrawsContent(true); |
1580 } | 1606 } |
1581 | 1607 |
1582 void CompositedLayerMapping::updateChildrenTransform() { | 1608 void CompositedLayerMapping::updateChildrenTransform() { |
1583 if (GraphicsLayer* childTransformLayer = this->childTransformLayer()) { | 1609 if (GraphicsLayer* childTransformLayer = this->childTransformLayer()) { |
1584 childTransformLayer->setTransform(owningLayer().perspectiveTransform()); | 1610 childTransformLayer->setTransform(owningLayer().perspectiveTransform()); |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1764 ApplyToLayersAffectedByPreserve3D = (1 << 0), | 1790 ApplyToLayersAffectedByPreserve3D = (1 << 0), |
1765 ApplyToSquashingLayer = (1 << 1), | 1791 ApplyToSquashingLayer = (1 << 1), |
1766 ApplyToScrollbarLayers = (1 << 2), | 1792 ApplyToScrollbarLayers = (1 << 2), |
1767 ApplyToBackgroundLayer = (1 << 3), | 1793 ApplyToBackgroundLayer = (1 << 3), |
1768 ApplyToMaskLayers = (1 << 4), | 1794 ApplyToMaskLayers = (1 << 4), |
1769 ApplyToContentLayers = (1 << 5), | 1795 ApplyToContentLayers = (1 << 5), |
1770 ApplyToChildContainingLayers = | 1796 ApplyToChildContainingLayers = |
1771 (1 << 6), // layers between m_graphicsLayer and children | 1797 (1 << 6), // layers between m_graphicsLayer and children |
1772 ApplyToNonScrollingContentLayers = (1 << 7), | 1798 ApplyToNonScrollingContentLayers = (1 << 7), |
1773 ApplyToScrollingContentLayers = (1 << 8), | 1799 ApplyToScrollingContentLayers = (1 << 8), |
1800 ApplyToDecorationLayer = (1 << 9), | |
1774 ApplyToAllGraphicsLayers = | 1801 ApplyToAllGraphicsLayers = |
1775 (ApplyToSquashingLayer | ApplyToScrollbarLayers | ApplyToBackgroundLayer | | 1802 (ApplyToSquashingLayer | ApplyToScrollbarLayers | ApplyToBackgroundLayer | |
1776 ApplyToMaskLayers | | 1803 ApplyToMaskLayers | |
1777 ApplyToLayersAffectedByPreserve3D | | 1804 ApplyToLayersAffectedByPreserve3D | |
1778 ApplyToContentLayers | | 1805 ApplyToContentLayers | |
1779 ApplyToScrollingContentLayers) | 1806 ApplyToScrollingContentLayers | |
1807 ApplyToDecorationLayer) | |
1780 }; | 1808 }; |
1781 typedef unsigned ApplyToGraphicsLayersMode; | 1809 typedef unsigned ApplyToGraphicsLayersMode; |
1782 | 1810 |
1783 template <typename Func> | 1811 template <typename Func> |
1784 static void ApplyToGraphicsLayers(const CompositedLayerMapping* mapping, | 1812 static void ApplyToGraphicsLayers(const CompositedLayerMapping* mapping, |
1785 const Func& f, | 1813 const Func& f, |
1786 ApplyToGraphicsLayersMode mode) { | 1814 ApplyToGraphicsLayersMode mode) { |
1787 ASSERT(mode); | 1815 ASSERT(mode); |
1788 | 1816 |
1789 if ((mode & ApplyToLayersAffectedByPreserve3D) && | 1817 if ((mode & ApplyToLayersAffectedByPreserve3D) && |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1832 (mode & ApplyToNonScrollingContentLayers)) && | 1860 (mode & ApplyToNonScrollingContentLayers)) && |
1833 mapping->backgroundLayer()) | 1861 mapping->backgroundLayer()) |
1834 f(mapping->backgroundLayer()); | 1862 f(mapping->backgroundLayer()); |
1835 | 1863 |
1836 if ((mode & ApplyToScrollbarLayers) && mapping->layerForHorizontalScrollbar()) | 1864 if ((mode & ApplyToScrollbarLayers) && mapping->layerForHorizontalScrollbar()) |
1837 f(mapping->layerForHorizontalScrollbar()); | 1865 f(mapping->layerForHorizontalScrollbar()); |
1838 if ((mode & ApplyToScrollbarLayers) && mapping->layerForVerticalScrollbar()) | 1866 if ((mode & ApplyToScrollbarLayers) && mapping->layerForVerticalScrollbar()) |
1839 f(mapping->layerForVerticalScrollbar()); | 1867 f(mapping->layerForVerticalScrollbar()); |
1840 if ((mode & ApplyToScrollbarLayers) && mapping->layerForScrollCorner()) | 1868 if ((mode & ApplyToScrollbarLayers) && mapping->layerForScrollCorner()) |
1841 f(mapping->layerForScrollCorner()); | 1869 f(mapping->layerForScrollCorner()); |
1870 | |
1871 if ((mode & ApplyToDecorationLayer) && mapping->decorationLayer()) | |
flackr
2016/10/24 20:07:04
I think you need to apply to non scrolling content
yigu
2016/10/24 20:31:36
Done.
| |
1872 f(mapping->decorationLayer()); | |
1842 } | 1873 } |
1843 | 1874 |
1844 struct UpdateRenderingContextFunctor { | 1875 struct UpdateRenderingContextFunctor { |
1845 void operator()(GraphicsLayer* layer) const { | 1876 void operator()(GraphicsLayer* layer) const { |
1846 layer->setRenderingContext(renderingContext); | 1877 layer->setRenderingContext(renderingContext); |
1847 } | 1878 } |
1848 int renderingContext; | 1879 int renderingContext; |
1849 }; | 1880 }; |
1850 | 1881 |
1851 void CompositedLayerMapping::updateRenderingContext() { | 1882 void CompositedLayerMapping::updateRenderingContext() { |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2010 layerChanged = true; | 2041 layerChanged = true; |
2011 } | 2042 } |
2012 } | 2043 } |
2013 | 2044 |
2014 if (layerChanged && !m_owningLayer.layoutObject()->documentBeingDestroyed()) | 2045 if (layerChanged && !m_owningLayer.layoutObject()->documentBeingDestroyed()) |
2015 compositor()->rootFixedBackgroundsChanged(); | 2046 compositor()->rootFixedBackgroundsChanged(); |
2016 | 2047 |
2017 return layerChanged; | 2048 return layerChanged; |
2018 } | 2049 } |
2019 | 2050 |
2051 bool CompositedLayerMapping::updateDecorationLayer(bool needsDecorationLayer) { | |
2052 bool layerChanged = false; | |
2053 if (needsDecorationLayer) { | |
2054 if (!m_decorationLayer) { | |
2055 m_decorationLayer = | |
2056 createGraphicsLayer(CompositingReasonLayerForDecoration); | |
2057 m_decorationLayer->setPaintingPhase(GraphicsLayerPaintDecoration); | |
2058 layerChanged = true; | |
2059 } | |
2060 } else if (m_decorationLayer) { | |
2061 m_decorationLayer = nullptr; | |
2062 layerChanged = true; | |
2063 } | |
2064 | |
2065 return layerChanged; | |
2066 } | |
2067 | |
2020 bool CompositedLayerMapping::updateMaskLayer(bool needsMaskLayer) { | 2068 bool CompositedLayerMapping::updateMaskLayer(bool needsMaskLayer) { |
2021 bool layerChanged = false; | 2069 bool layerChanged = false; |
2022 if (needsMaskLayer) { | 2070 if (needsMaskLayer) { |
2023 if (!m_maskLayer) { | 2071 if (!m_maskLayer) { |
2024 m_maskLayer = createGraphicsLayer(CompositingReasonLayerForMask); | 2072 m_maskLayer = createGraphicsLayer(CompositingReasonLayerForMask); |
2025 m_maskLayer->setPaintingPhase(GraphicsLayerPaintMask); | 2073 m_maskLayer->setPaintingPhase(GraphicsLayerPaintMask); |
2026 layerChanged = true; | 2074 layerChanged = true; |
2027 } | 2075 } |
2028 } else if (m_maskLayer) { | 2076 } else if (m_maskLayer) { |
2029 m_maskLayer = nullptr; | 2077 m_maskLayer = nullptr; |
(...skipping 918 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2948 if (graphicsLayerPaintingPhase & GraphicsLayerPaintForeground) | 2996 if (graphicsLayerPaintingPhase & GraphicsLayerPaintForeground) |
2949 paintLayerFlags |= PaintLayerPaintingCompositingForegroundPhase; | 2997 paintLayerFlags |= PaintLayerPaintingCompositingForegroundPhase; |
2950 if (graphicsLayerPaintingPhase & GraphicsLayerPaintMask) | 2998 if (graphicsLayerPaintingPhase & GraphicsLayerPaintMask) |
2951 paintLayerFlags |= PaintLayerPaintingCompositingMaskPhase; | 2999 paintLayerFlags |= PaintLayerPaintingCompositingMaskPhase; |
2952 if (graphicsLayerPaintingPhase & GraphicsLayerPaintChildClippingMask) | 3000 if (graphicsLayerPaintingPhase & GraphicsLayerPaintChildClippingMask) |
2953 paintLayerFlags |= PaintLayerPaintingChildClippingMaskPhase; | 3001 paintLayerFlags |= PaintLayerPaintingChildClippingMaskPhase; |
2954 if (graphicsLayerPaintingPhase & GraphicsLayerPaintOverflowContents) | 3002 if (graphicsLayerPaintingPhase & GraphicsLayerPaintOverflowContents) |
2955 paintLayerFlags |= PaintLayerPaintingOverflowContents; | 3003 paintLayerFlags |= PaintLayerPaintingOverflowContents; |
2956 if (graphicsLayerPaintingPhase & GraphicsLayerPaintCompositedScroll) | 3004 if (graphicsLayerPaintingPhase & GraphicsLayerPaintCompositedScroll) |
2957 paintLayerFlags |= PaintLayerPaintingCompositingScrollingPhase; | 3005 paintLayerFlags |= PaintLayerPaintingCompositingScrollingPhase; |
3006 if (graphicsLayerPaintingPhase & GraphicsLayerPaintDecoration) | |
3007 paintLayerFlags |= PaintLayerPaintingCompositingDecorationPhase; | |
2958 | 3008 |
2959 if (graphicsLayer == m_backgroundLayer.get()) | 3009 if (graphicsLayer == m_backgroundLayer.get()) |
2960 paintLayerFlags |= PaintLayerPaintingRootBackgroundOnly; | 3010 paintLayerFlags |= PaintLayerPaintingRootBackgroundOnly; |
2961 else if (compositor()->fixedRootBackgroundLayer() && | 3011 else if (compositor()->fixedRootBackgroundLayer() && |
2962 m_owningLayer.isRootLayer()) | 3012 m_owningLayer.isRootLayer()) |
2963 paintLayerFlags |= PaintLayerPaintingSkipRootBackground; | 3013 paintLayerFlags |= PaintLayerPaintingSkipRootBackground; |
2964 | 3014 |
2965 if (graphicsLayer == m_graphicsLayer.get() || | 3015 if (graphicsLayer == m_graphicsLayer.get() || |
2966 graphicsLayer == m_foregroundLayer.get() || | 3016 graphicsLayer == m_foregroundLayer.get() || |
2967 graphicsLayer == m_backgroundLayer.get() || | 3017 graphicsLayer == m_backgroundLayer.get() || |
2968 graphicsLayer == m_maskLayer.get() || | 3018 graphicsLayer == m_maskLayer.get() || |
2969 graphicsLayer == m_childClippingMaskLayer.get() || | 3019 graphicsLayer == m_childClippingMaskLayer.get() || |
2970 graphicsLayer == m_scrollingContentsLayer.get()) { | 3020 graphicsLayer == m_scrollingContentsLayer.get() || |
3021 graphicsLayer == m_decorationLayer.get()) { | |
2971 bool paintRootBackgroundOntoScrollingContentsLayer = | 3022 bool paintRootBackgroundOntoScrollingContentsLayer = |
2972 m_backgroundPaintsOntoScrollingContentsLayer; | 3023 m_backgroundPaintsOntoScrollingContentsLayer; |
2973 DCHECK(!paintRootBackgroundOntoScrollingContentsLayer || | 3024 DCHECK(!paintRootBackgroundOntoScrollingContentsLayer || |
2974 (!m_backgroundLayer && !m_foregroundLayer)); | 3025 (!m_backgroundLayer && !m_foregroundLayer)); |
2975 if (paintRootBackgroundOntoScrollingContentsLayer) { | 3026 if (paintRootBackgroundOntoScrollingContentsLayer) { |
2976 if (graphicsLayer == m_scrollingContentsLayer.get()) | 3027 if (graphicsLayer == m_scrollingContentsLayer.get()) |
2977 paintLayerFlags &= ~PaintLayerPaintingSkipRootBackground; | 3028 paintLayerFlags &= ~PaintLayerPaintingSkipRootBackground; |
2978 else | 3029 else |
2979 paintLayerFlags |= PaintLayerPaintingSkipRootBackground; | 3030 paintLayerFlags |= PaintLayerPaintingSkipRootBackground; |
2980 } | 3031 } |
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3241 } else if (graphicsLayer == m_layerForScrollCorner.get()) { | 3292 } else if (graphicsLayer == m_layerForScrollCorner.get()) { |
3242 name = "Scroll Corner Layer"; | 3293 name = "Scroll Corner Layer"; |
3243 } else if (graphicsLayer == m_overflowControlsHostLayer.get()) { | 3294 } else if (graphicsLayer == m_overflowControlsHostLayer.get()) { |
3244 name = "Overflow Controls Host Layer"; | 3295 name = "Overflow Controls Host Layer"; |
3245 } else if (graphicsLayer == m_overflowControlsAncestorClippingLayer.get()) { | 3296 } else if (graphicsLayer == m_overflowControlsAncestorClippingLayer.get()) { |
3246 name = "Overflow Controls Ancestor Clipping Layer"; | 3297 name = "Overflow Controls Ancestor Clipping Layer"; |
3247 } else if (graphicsLayer == m_scrollingLayer.get()) { | 3298 } else if (graphicsLayer == m_scrollingLayer.get()) { |
3248 name = "Scrolling Layer"; | 3299 name = "Scrolling Layer"; |
3249 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { | 3300 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { |
3250 name = "Scrolling Contents Layer"; | 3301 name = "Scrolling Contents Layer"; |
3302 } else if (graphicsLayer == m_decorationLayer.get()) { | |
3303 name = "Decoration Layer"; | |
3251 } else { | 3304 } else { |
3252 ASSERT_NOT_REACHED(); | 3305 ASSERT_NOT_REACHED(); |
3253 } | 3306 } |
3254 | 3307 |
3255 return name; | 3308 return name; |
3256 } | 3309 } |
3257 | 3310 |
3258 } // namespace blink | 3311 } // namespace blink |
OLD | NEW |