OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/display.h" | 5 #include "services/ui/ws/display.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 } | 64 } |
65 } | 65 } |
66 | 66 |
67 void Display::Init(const display::ViewportMetrics& metrics, | 67 void Display::Init(const display::ViewportMetrics& metrics, |
68 std::unique_ptr<DisplayBinding> binding) { | 68 std::unique_ptr<DisplayBinding> binding) { |
69 binding_ = std::move(binding); | 69 binding_ = std::move(binding); |
70 display_manager()->AddDisplay(this); | 70 display_manager()->AddDisplay(this); |
71 | 71 |
72 CreateRootWindow(metrics.bounds_in_pixels.size()); | 72 CreateRootWindow(metrics.bounds_in_pixels.size()); |
73 | 73 |
74 platform_display_ = PlatformDisplay::Create(root_.get(), metrics); | 74 platform_display_ = PlatformDisplay::Create( |
| 75 root_.get(), metrics, window_server_->GetThreadedImageCursorsFactory()); |
75 platform_display_->Init(this); | 76 platform_display_->Init(this); |
76 } | 77 } |
77 | 78 |
78 int64_t Display::GetId() const { | 79 int64_t Display::GetId() const { |
79 // TODO(tonikitoo): Implement a different ID for external window mode. | 80 // TODO(tonikitoo): Implement a different ID for external window mode. |
80 return display_.id(); | 81 return display_.id(); |
81 } | 82 } |
82 | 83 |
83 void Display::SetDisplay(const display::Display& display) { | 84 void Display::SetDisplay(const display::Display& display) { |
84 display_ = display; | 85 display_ = display; |
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
417 | 418 |
418 UserActivityMonitor* activity_monitor = | 419 UserActivityMonitor* activity_monitor = |
419 window_server_->GetUserActivityMonitorForUser( | 420 window_server_->GetUserActivityMonitorForUser( |
420 window_server_->user_id_tracker()->active_id()); | 421 window_server_->user_id_tracker()->active_id()); |
421 activity_monitor->OnUserActivity(); | 422 activity_monitor->OnUserActivity(); |
422 return EventDispatchDetails(); | 423 return EventDispatchDetails(); |
423 } | 424 } |
424 | 425 |
425 } // namespace ws | 426 } // namespace ws |
426 } // namespace ui | 427 } // namespace ui |
OLD | NEW |