| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights |
| 3 * reserved. | 3 * reserved. |
| 4 * | 4 * |
| 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
| 6 * | 6 * |
| 7 * Other contributors: | 7 * Other contributors: |
| 8 * Robert O'Callahan <roc+@cs.cmu.edu> | 8 * Robert O'Callahan <roc+@cs.cmu.edu> |
| 9 * David Baron <dbaron@fas.harvard.edu> | 9 * David Baron <dbaron@fas.harvard.edu> |
| 10 * Christian Biesinger <cbiesinger@web.de> | 10 * Christian Biesinger <cbiesinger@web.de> |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 #include "core/layout/LayoutPart.h" | 61 #include "core/layout/LayoutPart.h" |
| 62 #include "core/layout/LayoutTreeAsText.h" | 62 #include "core/layout/LayoutTreeAsText.h" |
| 63 #include "core/layout/LayoutView.h" | 63 #include "core/layout/LayoutView.h" |
| 64 #include "core/layout/api/LayoutPartItem.h" | 64 #include "core/layout/api/LayoutPartItem.h" |
| 65 #include "core/layout/api/LayoutViewItem.h" | 65 #include "core/layout/api/LayoutViewItem.h" |
| 66 #include "core/layout/compositing/CompositedLayerMapping.h" | 66 #include "core/layout/compositing/CompositedLayerMapping.h" |
| 67 #include "core/layout/compositing/PaintLayerCompositor.h" | 67 #include "core/layout/compositing/PaintLayerCompositor.h" |
| 68 #include "core/layout/svg/LayoutSVGResourceClipper.h" | 68 #include "core/layout/svg/LayoutSVGResourceClipper.h" |
| 69 #include "core/layout/svg/LayoutSVGRoot.h" | 69 #include "core/layout/svg/LayoutSVGRoot.h" |
| 70 #include "core/page/Page.h" | 70 #include "core/page/Page.h" |
| 71 #include "core/page/scrolling/RootScrollerController.h" | |
| 72 #include "core/page/scrolling/ScrollingCoordinator.h" | 71 #include "core/page/scrolling/ScrollingCoordinator.h" |
| 73 #include "core/paint/BoxReflectionUtils.h" | 72 #include "core/paint/BoxReflectionUtils.h" |
| 74 #include "core/paint/FilterEffectBuilder.h" | 73 #include "core/paint/FilterEffectBuilder.h" |
| 75 #include "core/paint/ObjectPaintInvalidator.h" | 74 #include "core/paint/ObjectPaintInvalidator.h" |
| 76 #include "platform/LengthFunctions.h" | 75 #include "platform/LengthFunctions.h" |
| 77 #include "platform/RuntimeEnabledFeatures.h" | 76 #include "platform/RuntimeEnabledFeatures.h" |
| 78 #include "platform/geometry/FloatPoint3D.h" | 77 #include "platform/geometry/FloatPoint3D.h" |
| 79 #include "platform/geometry/FloatRect.h" | 78 #include "platform/geometry/FloatRect.h" |
| 80 #include "platform/geometry/TransformState.h" | 79 #include "platform/geometry/TransformState.h" |
| 81 #include "platform/graphics/CompositorFilterOperations.h" | 80 #include "platform/graphics/CompositorFilterOperations.h" |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 m_previousPaintResult(FullyPainted), | 148 m_previousPaintResult(FullyPainted), |
| 150 m_needsPaintPhaseDescendantOutlines(false), | 149 m_needsPaintPhaseDescendantOutlines(false), |
| 151 m_previousPaintPhaseDescendantOutlinesWasEmpty(false), | 150 m_previousPaintPhaseDescendantOutlinesWasEmpty(false), |
| 152 m_needsPaintPhaseFloat(false), | 151 m_needsPaintPhaseFloat(false), |
| 153 m_previousPaintPhaseFloatWasEmpty(false), | 152 m_previousPaintPhaseFloatWasEmpty(false), |
| 154 m_needsPaintPhaseDescendantBlockBackgrounds(false), | 153 m_needsPaintPhaseDescendantBlockBackgrounds(false), |
| 155 m_previousPaintPhaseDescendantBlockBackgroundsWasEmpty(false), | 154 m_previousPaintPhaseDescendantBlockBackgroundsWasEmpty(false), |
| 156 m_hasDescendantWithClipPath(false), | 155 m_hasDescendantWithClipPath(false), |
| 157 m_hasNonIsolatedDescendantWithBlendMode(false), | 156 m_hasNonIsolatedDescendantWithBlendMode(false), |
| 158 m_hasAncestorWithClipPath(false), | 157 m_hasAncestorWithClipPath(false), |
| 159 m_hasRootScrollerAsDescendant(false), | |
| 160 m_selfPaintingStatusChanged(false), | 158 m_selfPaintingStatusChanged(false), |
| 161 m_layoutObject(layoutObject), | 159 m_layoutObject(layoutObject), |
| 162 m_parent(0), | 160 m_parent(0), |
| 163 m_previous(0), | 161 m_previous(0), |
| 164 m_next(0), | 162 m_next(0), |
| 165 m_first(0), | 163 m_first(0), |
| 166 m_last(0), | 164 m_last(0), |
| 167 m_staticInlinePosition(0), | 165 m_staticInlinePosition(0), |
| 168 m_staticBlockPosition(0), | 166 m_staticBlockPosition(0), |
| 169 m_ancestorOverflowLayer(nullptr) { | 167 m_ancestorOverflowLayer(nullptr) { |
| (...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 667 } | 665 } |
| 668 } | 666 } |
| 669 | 667 |
| 670 void PaintLayer::updateDescendantDependentFlags() { | 668 void PaintLayer::updateDescendantDependentFlags() { |
| 671 if (m_needsDescendantDependentFlagsUpdate) { | 669 if (m_needsDescendantDependentFlagsUpdate) { |
| 672 bool oldHasNonIsolatedDescendantWithBlendMode = | 670 bool oldHasNonIsolatedDescendantWithBlendMode = |
| 673 m_hasNonIsolatedDescendantWithBlendMode; | 671 m_hasNonIsolatedDescendantWithBlendMode; |
| 674 m_hasVisibleDescendant = false; | 672 m_hasVisibleDescendant = false; |
| 675 m_hasNonIsolatedDescendantWithBlendMode = false; | 673 m_hasNonIsolatedDescendantWithBlendMode = false; |
| 676 m_hasDescendantWithClipPath = false; | 674 m_hasDescendantWithClipPath = false; |
| 677 m_hasRootScrollerAsDescendant = false; | |
| 678 | 675 |
| 679 for (PaintLayer* child = firstChild(); child; | 676 for (PaintLayer* child = firstChild(); child; |
| 680 child = child->nextSibling()) { | 677 child = child->nextSibling()) { |
| 681 child->updateDescendantDependentFlags(); | 678 child->updateDescendantDependentFlags(); |
| 682 | 679 |
| 683 if (child->m_hasVisibleContent || child->m_hasVisibleDescendant) | 680 if (child->m_hasVisibleContent || child->m_hasVisibleDescendant) |
| 684 m_hasVisibleDescendant = true; | 681 m_hasVisibleDescendant = true; |
| 685 | 682 |
| 686 m_hasNonIsolatedDescendantWithBlendMode |= | 683 m_hasNonIsolatedDescendantWithBlendMode |= |
| 687 (!child->stackingNode()->isStackingContext() && | 684 (!child->stackingNode()->isStackingContext() && |
| 688 child->hasNonIsolatedDescendantWithBlendMode()) || | 685 child->hasNonIsolatedDescendantWithBlendMode()) || |
| 689 child->layoutObject().styleRef().hasBlendMode(); | 686 child->layoutObject().styleRef().hasBlendMode(); |
| 690 | 687 |
| 691 m_hasDescendantWithClipPath |= child->hasDescendantWithClipPath() || | 688 m_hasDescendantWithClipPath |= child->hasDescendantWithClipPath() || |
| 692 child->layoutObject().hasClipPath(); | 689 child->layoutObject().hasClipPath(); |
| 693 | |
| 694 m_hasRootScrollerAsDescendant |= child->hasRootScrollerAsDescendant() || | |
| 695 (child == | |
| 696 child->layoutObject() | |
| 697 .document() | |
| 698 .rootScrollerController() | |
| 699 .rootScrollerPaintLayer()); | |
| 700 } | 690 } |
| 701 | 691 |
| 702 if (RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled() && | 692 if (RuntimeEnabledFeatures::slimmingPaintInvalidationEnabled() && |
| 703 oldHasNonIsolatedDescendantWithBlendMode != | 693 oldHasNonIsolatedDescendantWithBlendMode != |
| 704 static_cast<bool>(m_hasNonIsolatedDescendantWithBlendMode)) | 694 static_cast<bool>(m_hasNonIsolatedDescendantWithBlendMode)) |
| 705 layoutObject().setNeedsPaintPropertyUpdate(); | 695 layoutObject().setNeedsPaintPropertyUpdate(); |
| 706 m_needsDescendantDependentFlagsUpdate = false; | 696 m_needsDescendantDependentFlagsUpdate = false; |
| 707 } | 697 } |
| 708 | 698 |
| 709 bool previouslyHasVisibleContent = m_hasVisibleContent; | 699 bool previouslyHasVisibleContent = m_hasVisibleContent; |
| (...skipping 2522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3232 } | 3222 } |
| 3233 | 3223 |
| 3234 void showLayerTree(const blink::LayoutObject* layoutObject) { | 3224 void showLayerTree(const blink::LayoutObject* layoutObject) { |
| 3235 if (!layoutObject) { | 3225 if (!layoutObject) { |
| 3236 LOG(INFO) << "Cannot showLayerTree. Root is (nil)"; | 3226 LOG(INFO) << "Cannot showLayerTree. Root is (nil)"; |
| 3237 return; | 3227 return; |
| 3238 } | 3228 } |
| 3239 showLayerTree(layoutObject->enclosingLayer()); | 3229 showLayerTree(layoutObject->enclosingLayer()); |
| 3240 } | 3230 } |
| 3241 #endif | 3231 #endif |
| OLD | NEW |