| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "services/ui/ws/platform_display_default.h" | 5 #include "services/ui/ws/platform_display_default.h" |
| 6 | 6 |
| 7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
| 8 #include "gpu/ipc/client/gpu_channel_host.h" | 8 #include "gpu/ipc/client/gpu_channel_host.h" |
| 9 #include "services/ui/display/screen_manager.h" | 9 #include "services/ui/display/screen_manager.h" |
| 10 #include "services/ui/ws/display_client_compositor_frame_sink.h" | 10 #include "services/ui/ws/display_client_compositor_frame_sink.h" |
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 250 widget_, mojo::MakeRequest(&compositor_frame_sink), | 250 widget_, mojo::MakeRequest(&compositor_frame_sink), |
| 251 std::move(compositor_frame_sink_client), | 251 std::move(compositor_frame_sink_client), |
| 252 mojo::MakeRequest(&display_private)); | 252 mojo::MakeRequest(&display_private)); |
| 253 | 253 |
| 254 auto display_client_compositor_frame_sink = | 254 auto display_client_compositor_frame_sink = |
| 255 base::MakeUnique<DisplayClientCompositorFrameSink>( | 255 base::MakeUnique<DisplayClientCompositorFrameSink>( |
| 256 root_window_->frame_sink_id(), std::move(compositor_frame_sink), | 256 root_window_->frame_sink_id(), std::move(compositor_frame_sink), |
| 257 std::move(display_private), | 257 std::move(display_private), |
| 258 std::move(compositor_frame_sink_client_request)); | 258 std::move(compositor_frame_sink_client_request)); |
| 259 frame_generator_ = base::MakeUnique<FrameGenerator>( | 259 frame_generator_ = base::MakeUnique<FrameGenerator>( |
| 260 this, root_window_, std::move(display_client_compositor_frame_sink)); | 260 root_window_, std::move(display_client_compositor_frame_sink)); |
| 261 frame_generator_->SetDeviceScaleFactor(init_device_scale_factor_); | 261 frame_generator_->SetDeviceScaleFactor(init_device_scale_factor_); |
| 262 } | 262 } |
| 263 | 263 |
| 264 void PlatformDisplayDefault::OnAcceleratedWidgetDestroyed() { | 264 void PlatformDisplayDefault::OnAcceleratedWidgetDestroyed() { |
| 265 NOTREACHED(); | 265 NOTREACHED(); |
| 266 } | 266 } |
| 267 | 267 |
| 268 void PlatformDisplayDefault::OnActivationChanged(bool active) {} | 268 void PlatformDisplayDefault::OnActivationChanged(bool active) {} |
| 269 | 269 |
| 270 bool PlatformDisplayDefault::IsInHighContrastMode() { | |
| 271 return delegate_ ? delegate_->IsInHighContrastMode() : false; | |
| 272 } | |
| 273 | |
| 274 } // namespace ws | 270 } // namespace ws |
| 275 } // namespace ui | 271 } // namespace ui |
| OLD | NEW |