Index: third_party/WebKit/Source/core/frame/FrameView.cpp |
diff --git a/third_party/WebKit/Source/core/frame/FrameView.cpp b/third_party/WebKit/Source/core/frame/FrameView.cpp |
index 048e7d1c315d85fd90c25e562ffe98c1cde3a5ad..63ca3b805ac0b0ffb138b60bb1664ebd29f21c50 100644 |
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp |
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp |
@@ -106,6 +106,7 @@ |
#include "platform/graphics/GraphicsContext.h" |
#include "platform/graphics/GraphicsLayer.h" |
#include "platform/graphics/GraphicsLayerDebugInfo.h" |
+#include "platform/graphics/compositing/PaintArtifactCompositor.h" |
#include "platform/graphics/paint/CullRect.h" |
#include "platform/graphics/paint/PaintController.h" |
#include "platform/graphics/paint/ScopedPaintChunkProperties.h" |
@@ -2762,12 +2763,20 @@ void FrameView::pushPaintArtifactToCompositor() |
ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled()); |
- const PaintArtifact& paintArtifact = m_paintController->paintArtifact(); |
- |
Page* page = frame().page(); |
if (!page) |
return; |
- page->chromeClient().didPaint(paintArtifact); |
+ |
+ if (!m_paintArtifactCompositor) { |
+ m_paintArtifactCompositor = PaintArtifactCompositor::create(); |
+ page->chromeClient().attachRootLayer(m_paintArtifactCompositor->getWebLayer(), &frame()); |
jbroman
2016/09/15 21:31:04
For what it's worth, the concern here was that Web
|
+ } |
+ |
+ SCOPED_BLINK_UMA_HISTOGRAM_TIMER("Blink.Compositing.UpdateTime"); |
+ |
+ frameView.lifecycle().advanceTo(DocumentLifecycle::InCompositingUpdateForSlimmingPaintV2); |
+ m_paintArtifactCompositor->update(m_paintController->paintArtifact()); |
+ frameView.lifecycle().advanceTo(DocumentLifecycle::InCompositingUpdateForSlimmingPaintV2Clean); |
} |
void FrameView::updateStyleAndLayoutIfNeededRecursive() |