Commit 830112b0 authored by Philip Rogers's avatar Philip Rogers Committed by Commit Bot

Refactor PaintArtifactCompositor::CcLayer() to use RootLayer()

with PaintArtifactCompositor::RootLayer. This is a very simple cleanup.

PaintArtifactCompositor: :CcLayer is no longer needed and can be replaced
Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_slimming_paint_v2;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: Ie3a4c07f0a514fc96ad2692eb22d6e5b3e106b27
Reviewed-on: https://chromium-review.googlesource.com/1117710
Commit-Queue: Chris Harrelson <chrishtr@chromium.org>
Reviewed-by: default avatarChris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#571024}
parent 0abb3632
......@@ -3052,7 +3052,7 @@ void LocalFrameView::PushPaintArtifactToCompositor(
// ScrollingCoordinator.
WrapWeakPersistent(page->GetScrollingCoordinator())));
page->GetChromeClient().AttachRootLayer(
paint_artifact_compositor_->GetCcLayer(), &GetFrame());
paint_artifact_compositor_->RootLayer(), &GetFrame());
}
SCOPED_UMA_AND_UKM_TIMER("Blink.Compositing.UpdateTime",
......
......@@ -67,11 +67,6 @@ class PLATFORM_EXPORT PaintArtifactCompositor final
// The root layer of the tree managed by this object.
cc::Layer* RootLayer() const { return root_layer_.get(); }
// Wraps RootLayer(), so that it can be attached as a child of another
// cc::Layer.
// TODO(danakj): Remove this, use RootLayer() directly.
cc::Layer* GetCcLayer() const { return root_layer_.get(); }
// Returns extra information recorded during unit tests.
// While not part of the normal output of this class, this provides a simple
// way of locating the layers of interest, since there are still a slew of
......
......@@ -98,8 +98,7 @@ class PaintArtifactCompositorTest : public testing::Test,
settings.use_layer_lists = true;
web_layer_tree_view_ =
std::make_unique<WebLayerTreeViewWithLayerTreeFrameSink>(settings);
web_layer_tree_view_->SetRootLayer(
paint_artifact_compositor_->GetCcLayer());
web_layer_tree_view_->SetRootLayer(paint_artifact_compositor_->RootLayer());
}
void TearDown() override {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment