| Index: ui/compositor/compositor.cc
|
| diff --git a/ui/compositor/compositor.cc b/ui/compositor/compositor.cc
|
| index 1250b4dab09472d91f618bf79cd0497b309cd2e9..318c73614f143d7f52ab480c8ac133b8d996e503 100644
|
| --- a/ui/compositor/compositor.cc
|
| +++ b/ui/compositor/compositor.cc
|
| @@ -208,7 +208,7 @@ Compositor::Compositor(const cc::FrameSinkId& frame_sink_id,
|
| cc::AnimationTimeline::Create(cc::AnimationIdProvider::NextTimelineId());
|
| animation_host_->AddAnimationTimeline(animation_timeline_.get());
|
|
|
| - host_->GetLayerTree()->SetRootLayer(root_web_layer_);
|
| + host_->SetRootLayer(root_web_layer_);
|
| host_->SetFrameSinkId(frame_sink_id_);
|
| host_->SetVisible(true);
|
|
|
| @@ -303,8 +303,7 @@ cc::AnimationTimeline* Compositor::GetAnimationTimeline() const {
|
|
|
| void Compositor::SetHostHasTransparentBackground(
|
| bool host_has_transparent_background) {
|
| - host_->GetLayerTree()->set_has_transparent_background(
|
| - host_has_transparent_background);
|
| + host_->set_has_transparent_background(host_has_transparent_background);
|
| }
|
|
|
| void Compositor::ScheduleFullRedraw() {
|
| @@ -312,8 +311,7 @@ void Compositor::ScheduleFullRedraw() {
|
| // will also commit. This should probably just redraw the screen
|
| // from damage and not commit. ScheduleDraw/ScheduleRedraw need
|
| // better names.
|
| - host_->SetNeedsRedrawRect(
|
| - gfx::Rect(host_->GetLayerTree()->device_viewport_size()));
|
| + host_->SetNeedsRedrawRect(gfx::Rect(host_->device_viewport_size()));
|
| host_->SetNeedsCommit();
|
| }
|
|
|
| @@ -337,7 +335,7 @@ void Compositor::SetScaleAndSize(float scale, const gfx::Size& size_in_pixel) {
|
| DCHECK_GT(scale, 0);
|
| if (!size_in_pixel.IsEmpty()) {
|
| size_ = size_in_pixel;
|
| - host_->GetLayerTree()->SetViewportSize(size_in_pixel);
|
| + host_->SetViewportSize(size_in_pixel);
|
| root_web_layer_->SetBounds(size_in_pixel);
|
| // TODO(fsamuel): Get rid of ContextFactoryPrivate.
|
| if (context_factory_private_)
|
| @@ -345,14 +343,14 @@ void Compositor::SetScaleAndSize(float scale, const gfx::Size& size_in_pixel) {
|
| }
|
| if (device_scale_factor_ != scale) {
|
| device_scale_factor_ = scale;
|
| - host_->GetLayerTree()->SetDeviceScaleFactor(scale);
|
| + host_->SetDeviceScaleFactor(scale);
|
| if (root_layer_)
|
| root_layer_->OnDeviceScaleFactorChanged(scale);
|
| }
|
| }
|
|
|
| void Compositor::SetDisplayColorSpace(const gfx::ColorSpace& color_space) {
|
| - host_->GetLayerTree()->SetDeviceColorSpace(color_space);
|
| + host_->SetDeviceColorSpace(color_space);
|
| color_space_ = color_space;
|
| // Color space is reset when the output surface is lost, so this must also be
|
| // updated then.
|
| @@ -362,7 +360,7 @@ void Compositor::SetDisplayColorSpace(const gfx::ColorSpace& color_space) {
|
| }
|
|
|
| void Compositor::SetBackgroundColor(SkColor color) {
|
| - host_->GetLayerTree()->set_background_color(color);
|
| + host_->set_background_color(color);
|
| ScheduleDraw();
|
| }
|
|
|
|
|