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 #ifndef SERVICES_UI_WS_DISPLAY_MANAGER_H_ | 5 #ifndef SERVICES_UI_WS_DISPLAY_MANAGER_H_ |
6 #define SERVICES_UI_WS_DISPLAY_MANAGER_H_ | 6 #define SERVICES_UI_WS_DISPLAY_MANAGER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <memory> | 9 #include <memory> |
10 #include <set> | 10 #include <set> |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 | 75 |
76 // Called when the AcceleratedWidget is available for |display|. | 76 // Called when the AcceleratedWidget is available for |display|. |
77 void OnDisplayAcceleratedWidgetAvailable(Display* display); | 77 void OnDisplayAcceleratedWidgetAvailable(Display* display); |
78 | 78 |
79 private: | 79 private: |
80 // UserIdTrackerObserver: | 80 // UserIdTrackerObserver: |
81 void OnActiveUserIdChanged(const UserId& previously_active_id, | 81 void OnActiveUserIdChanged(const UserId& previously_active_id, |
82 const UserId& active_id) override; | 82 const UserId& active_id) override; |
83 | 83 |
84 // display::PlatformScreenDelegate: | 84 // display::PlatformScreenDelegate: |
85 void OnDisplayAdded(int64_t id, const gfx::Rect& bounds) override; | 85 void OnDisplayAdded(int64_t id, |
| 86 const gfx::Rect& bounds, |
| 87 const gfx::Size& pixel_size, |
| 88 float scale_factor) override; |
86 void OnDisplayRemoved(int64_t id) override; | 89 void OnDisplayRemoved(int64_t id) override; |
87 void OnDisplayModified(int64_t id, const gfx::Rect& bounds) override; | 90 void OnDisplayModified(int64_t id, |
| 91 const gfx::Rect& bounds, |
| 92 const gfx::Size& pixel_size, |
| 93 float scale_factor) override; |
88 | 94 |
89 WindowServer* window_server_; | 95 WindowServer* window_server_; |
90 UserIdTracker* user_id_tracker_; | 96 UserIdTracker* user_id_tracker_; |
91 | 97 |
92 // Displays are initially added to |pending_displays_|. When the display is | 98 // Displays are initially added to |pending_displays_|. When the display is |
93 // initialized it is moved to |displays_|. WindowServer owns the Displays. | 99 // initialized it is moved to |displays_|. WindowServer owns the Displays. |
94 std::set<Display*> pending_displays_; | 100 std::set<Display*> pending_displays_; |
95 std::set<Display*> displays_; | 101 std::set<Display*> displays_; |
96 | 102 |
97 std::map<UserId, std::unique_ptr<UserDisplayManager>> user_display_managers_; | 103 std::map<UserId, std::unique_ptr<UserDisplayManager>> user_display_managers_; |
98 | 104 |
99 // ID to use for next root node. | 105 // ID to use for next root node. |
100 ClientSpecificId next_root_id_; | 106 ClientSpecificId next_root_id_; |
101 | 107 |
102 DISALLOW_COPY_AND_ASSIGN(DisplayManager); | 108 DISALLOW_COPY_AND_ASSIGN(DisplayManager); |
103 }; | 109 }; |
104 | 110 |
105 } // namespace ws | 111 } // namespace ws |
106 } // namespace ui | 112 } // namespace ui |
107 | 113 |
108 #endif // SERVICES_UI_WS_DISPLAY_MANAGER_H_ | 114 #endif // SERVICES_UI_WS_DISPLAY_MANAGER_H_ |
OLD | NEW |