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

Side by Side Diff: components/display_compositor/gpu_root_compositor_frame_sink.cc

Issue 2669183002: Seems incorrect to se device_scale_factor in SetLocalSurfaceId.
Patch Set: Seems incorrect to set device_scale_factor in SetLocalSurfaceId. Added new function SetDeviceScaleF… Created 3 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/display_compositor/gpu_root_compositor_frame_sink.h" 5 #include "components/display_compositor/gpu_root_compositor_frame_sink.h"
6 6
7 #include "cc/surfaces/compositor_frame_sink_support.h" 7 #include "cc/surfaces/compositor_frame_sink_support.h"
8 #include "cc/surfaces/display.h" 8 #include "cc/surfaces/display.h"
9 9
10 namespace display_compositor { 10 namespace display_compositor {
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 DCHECK(display_); 63 DCHECK(display_);
64 display_->SetColorSpace(color_space); 64 display_->SetColorSpace(color_space);
65 } 65 }
66 66
67 void GpuRootCompositorFrameSink::SetOutputIsSecure(bool secure) { 67 void GpuRootCompositorFrameSink::SetOutputIsSecure(bool secure) {
68 DCHECK(display_); 68 DCHECK(display_);
69 display_->SetOutputIsSecure(secure); 69 display_->SetOutputIsSecure(secure);
70 } 70 }
71 71
72 void GpuRootCompositorFrameSink::SetLocalSurfaceId( 72 void GpuRootCompositorFrameSink::SetLocalSurfaceId(
73 const cc::LocalSurfaceId& local_surface_id, 73 const cc::LocalSurfaceId& local_surface_id) {
74 display_->SetLocalSurfaceId(local_surface_id);
75 }
76
77 void GpuRootCompositorFrameSink::SetDeviceScaleFactor(
74 float scale_factor) { 78 float scale_factor) {
75 display_->SetLocalSurfaceId(local_surface_id, scale_factor); 79 display_->SetDeviceScaleFactor(scale_factor);
76 } 80 }
77 81
78 void GpuRootCompositorFrameSink::EvictFrame() { 82 void GpuRootCompositorFrameSink::EvictFrame() {
79 support_->EvictFrame(); 83 support_->EvictFrame();
80 } 84 }
81 85
82 void GpuRootCompositorFrameSink::SetNeedsBeginFrame(bool needs_begin_frame) { 86 void GpuRootCompositorFrameSink::SetNeedsBeginFrame(bool needs_begin_frame) {
83 support_->SetNeedsBeginFrame(needs_begin_frame); 87 support_->SetNeedsBeginFrame(needs_begin_frame);
84 } 88 }
85 89
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 } 160 }
157 161
158 void GpuRootCompositorFrameSink::OnPrivateConnectionLost() { 162 void GpuRootCompositorFrameSink::OnPrivateConnectionLost() {
159 private_connection_lost_ = true; 163 private_connection_lost_ = true;
160 // Request destruction of |this| only if both connections are lost. 164 // Request destruction of |this| only if both connections are lost.
161 delegate_->OnPrivateConnectionLost(support_->frame_sink_id(), 165 delegate_->OnPrivateConnectionLost(support_->frame_sink_id(),
162 client_connection_lost_); 166 client_connection_lost_);
163 } 167 }
164 168
165 } // namespace display_compositor 169 } // namespace display_compositor
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698