| Index: third_party/WebKit/Source/core/paint/PaintLayerPainter.cpp
|
| diff --git a/third_party/WebKit/Source/core/paint/PaintLayerPainter.cpp b/third_party/WebKit/Source/core/paint/PaintLayerPainter.cpp
|
| index 337de3731f19143e51e1e61cea3e9036a38fd40d..f51fa53d6145dac05305a8bc7228f910c1ef27e3 100644
|
| --- a/third_party/WebKit/Source/core/paint/PaintLayerPainter.cpp
|
| +++ b/third_party/WebKit/Source/core/paint/PaintLayerPainter.cpp
|
| @@ -185,6 +185,9 @@ private:
|
|
|
| static bool shouldCreateSubsequence(const PaintLayer& paintLayer, GraphicsContext& context, const PaintLayerPaintingInfo& paintingInfo, PaintLayerFlags paintFlags)
|
| {
|
| + if (!RuntimeEnabledFeatures::paintOptimizationsEnabled())
|
| + return false;
|
| +
|
| // Caching is not needed during printing.
|
| if (context.printing())
|
| return false;
|
| @@ -739,12 +742,12 @@ void PaintLayerPainter::paintForegroundForFragments(const PaintLayerFragments& l
|
| if (selectionOnly) {
|
| paintForegroundForFragmentsWithPhase(PaintPhaseSelection, layerFragments, context, localPaintingInfo, paintFlags, clipState);
|
| } else {
|
| - if (m_paintLayer.needsPaintPhaseDescendantBlockBackgrounds())
|
| + if (!RuntimeEnabledFeatures::paintOptimizationsEnabled() || m_paintLayer.needsPaintPhaseDescendantBlockBackgrounds())
|
| paintForegroundForFragmentsWithPhase(PaintPhaseDescendantBlockBackgroundsOnly, layerFragments, context, localPaintingInfo, paintFlags, clipState);
|
| - if (m_paintLayer.needsPaintPhaseFloat())
|
| + if (!RuntimeEnabledFeatures::paintOptimizationsEnabled() || m_paintLayer.needsPaintPhaseFloat())
|
| paintForegroundForFragmentsWithPhase(PaintPhaseFloat, layerFragments, context, localPaintingInfo, paintFlags, clipState);
|
| paintForegroundForFragmentsWithPhase(PaintPhaseForeground, layerFragments, context, localPaintingInfo, paintFlags, clipState);
|
| - if (m_paintLayer.needsPaintPhaseDescendantOutlines())
|
| + if (!RuntimeEnabledFeatures::paintOptimizationsEnabled() || m_paintLayer.needsPaintPhaseDescendantOutlines())
|
| paintForegroundForFragmentsWithPhase(PaintPhaseDescendantOutlinesOnly, layerFragments, context, localPaintingInfo, paintFlags, clipState);
|
| }
|
| }
|
|
|