Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 UI_DISPLAY_MANAGER_DISPLAY_MANAGER_H_ | 5 #ifndef UI_DISPLAY_MANAGER_DISPLAY_MANAGER_H_ |
| 6 #define UI_DISPLAY_MANAGER_DISPLAY_MANAGER_H_ | 6 #define UI_DISPLAY_MANAGER_DISPLAY_MANAGER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 106 // When set to true, the DisplayManager calls OnDisplayMetricsChanged even if | 106 // When set to true, the DisplayManager calls OnDisplayMetricsChanged even if |
| 107 // the display's bounds didn't change. Used to swap primary display. | 107 // the display's bounds didn't change. Used to swap primary display. |
| 108 void set_force_bounds_changed(bool force_bounds_changed) { | 108 void set_force_bounds_changed(bool force_bounds_changed) { |
| 109 force_bounds_changed_ = force_bounds_changed; | 109 force_bounds_changed_ = force_bounds_changed; |
| 110 } | 110 } |
| 111 | 111 |
| 112 void set_configure_displays(bool configure_displays) { | 112 void set_configure_displays(bool configure_displays) { |
| 113 configure_displays_ = configure_displays; | 113 configure_displays_ = configure_displays; |
| 114 } | 114 } |
| 115 | 115 |
| 116 void set_internal_display_has_accelerometer(bool has_accelerometer) { | |
| 117 internal_display_has_accelerometer_ = has_accelerometer; | |
| 118 } | |
| 119 | |
| 116 // Returns the display id of the first display in the outupt list. | 120 // Returns the display id of the first display in the outupt list. |
| 117 int64_t first_display_id() const { return first_display_id_; } | 121 int64_t first_display_id() const { return first_display_id_; } |
| 118 | 122 |
| 119 // Initializes displays using command line flag. Returns false if no command | 123 // Initializes displays using command line flag. Returns false if no command |
| 120 // line flag was provided. | 124 // line flag was provided. |
| 121 bool InitFromCommandLine(); | 125 bool InitFromCommandLine(); |
| 122 | 126 |
| 123 // Initialize default display. | 127 // Initialize default display. |
| 124 void InitDefaultDisplay(); | 128 void InitDefaultDisplay(); |
| 125 | 129 |
| (...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 483 bool mirror_mode_for_metrics_ = false; | 487 bool mirror_mode_for_metrics_ = false; |
| 484 | 488 |
| 485 // User preference for rotation lock of the internal display. | 489 // User preference for rotation lock of the internal display. |
| 486 bool registered_internal_display_rotation_lock_ = false; | 490 bool registered_internal_display_rotation_lock_ = false; |
| 487 | 491 |
| 488 // User preference for the rotation of the internal display. | 492 // User preference for the rotation of the internal display. |
| 489 Display::Rotation registered_internal_display_rotation_ = Display::ROTATE_0; | 493 Display::Rotation registered_internal_display_rotation_ = Display::ROTATE_0; |
| 490 | 494 |
| 491 bool unified_desktop_enabled_ = false; | 495 bool unified_desktop_enabled_ = false; |
| 492 | 496 |
| 497 int64_t internal_display_has_accelerometer_ = false; | |
|
kylechar
2017/06/22 15:28:31
Should this be bool?
oshima
2017/06/22 18:58:43
Doh, thank you for catching this. I was going back
| |
| 498 | |
| 493 base::Closure created_mirror_window_; | 499 base::Closure created_mirror_window_; |
| 494 | 500 |
| 495 base::ObserverList<DisplayObserver> observers_; | 501 base::ObserverList<DisplayObserver> observers_; |
| 496 | 502 |
| 497 base::WeakPtrFactory<DisplayManager> weak_ptr_factory_; | 503 base::WeakPtrFactory<DisplayManager> weak_ptr_factory_; |
| 498 | 504 |
| 499 DISALLOW_COPY_AND_ASSIGN(DisplayManager); | 505 DISALLOW_COPY_AND_ASSIGN(DisplayManager); |
| 500 }; | 506 }; |
| 501 | 507 |
| 502 } // namespace display | 508 } // namespace display |
| 503 | 509 |
| 504 #endif // UI_DISPLAY_MANAGER_DISPLAY_MANAGER_H_ | 510 #endif // UI_DISPLAY_MANAGER_DISPLAY_MANAGER_H_ |
| OLD | NEW |