Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(320)

Unified Diff: third_party/WebKit/Source/core/frame/FrameView.cpp

Issue 2724083002: [SPv2] Decomposite otherwise-compositable animations that paint nothing. (Closed)
Patch Set: Clean up after initial review. Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 4959e65cffdd86d3499cbe53c908e02024163cdf..dd17f21bd3d3792ffa8a2aa57a23170f5bb8a098 100644
--- a/third_party/WebKit/Source/core/frame/FrameView.cpp
+++ b/third_party/WebKit/Source/core/frame/FrameView.cpp
@@ -3102,18 +3102,19 @@ void FrameView::updateLifecyclePhasesInternal(
RuntimeEnabledFeatures::printBrowserEnabled())
paintTree();
- if (RuntimeEnabledFeatures::slimmingPaintV2Enabled())
- pushPaintArtifactToCompositor();
+ if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) {
+ Optional<CompositorElementIdSet> compositedElementIds =
+ CompositorElementIdSet();
+ pushPaintArtifactToCompositor(compositedElementIds.value());
+ DocumentAnimations::updateAnimations(layoutView()->document(),
+ DocumentLifecycle::PaintClean,
+ compositedElementIds);
+ }
DCHECK(!view.hasPendingSelection());
DCHECK((m_frame->document()->printing() &&
lifecycle().state() == DocumentLifecycle::PrePaintClean) ||
lifecycle().state() == DocumentLifecycle::PaintClean);
-
- if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) {
- DocumentAnimations::updateAnimations(layoutView()->document(),
- DocumentLifecycle::PaintClean);
- }
}
forAllNonThrottledFrameViews([](FrameView& frameView) {
@@ -3250,7 +3251,8 @@ void FrameView::paintGraphicsLayerRecursively(GraphicsLayer* graphicsLayer) {
paintGraphicsLayerRecursively(child);
}
-void FrameView::pushPaintArtifactToCompositor() {
+void FrameView::pushPaintArtifactToCompositor(
+ CompositorElementIdSet& compositedElementIds) {
TRACE_EVENT0("blink", "FrameView::pushPaintArtifactToCompositor");
DCHECK(RuntimeEnabledFeatures::slimmingPaintV2Enabled());
@@ -3271,7 +3273,8 @@ void FrameView::pushPaintArtifactToCompositor() {
m_paintArtifactCompositor->update(
m_paintController->paintArtifact(),
m_paintController->paintChunksRasterInvalidationTrackingMap(),
- m_isStoringCompositedLayerDebugInfo, *m_geometryMapper);
+ m_isStoringCompositedLayerDebugInfo, *m_geometryMapper,
+ compositedElementIds);
}
std::unique_ptr<JSONObject> FrameView::compositedLayersAsJSON(

Powered by Google App Engine
This is Rietveld 408576698