Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_CHROMEOS_DISPLAY_CONFIGURATOR_H_ | 5 #ifndef UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ |
| 6 #define UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ | 6 #define UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 119 // ConfigureDisplays(), and returns true; returns false otherwise. | 119 // ConfigureDisplays(), and returns true; returns false otherwise. |
| 120 bool TriggerConfigureTimeout(); | 120 bool TriggerConfigureTimeout(); |
| 121 | 121 |
| 122 private: | 122 private: |
| 123 DisplayConfigurator* configurator_; // not owned | 123 DisplayConfigurator* configurator_; // not owned |
| 124 | 124 |
| 125 DISALLOW_COPY_AND_ASSIGN(TestApi); | 125 DISALLOW_COPY_AND_ASSIGN(TestApi); |
| 126 }; | 126 }; |
| 127 | 127 |
| 128 // Flags that can be passed to SetDisplayPower(). | 128 // Flags that can be passed to SetDisplayPower(). |
| 129 static const int kSetDisplayPowerNoFlags = 0; | 129 static const int kSetDisplayPowerNoFlags; |
|
dnicoara
2014/08/12 18:39:44
If no one minds, I'd like to have a followup CL to
oshima
2014/08/12 20:26:13
sgtm
| |
| 130 // Configure displays even if the passed-in state matches |power_state_|. | 130 // Configure displays even if the passed-in state matches |power_state_|. |
| 131 static const int kSetDisplayPowerForceProbe = 1 << 0; | 131 static const int kSetDisplayPowerForceProbe; |
| 132 // Do not change the state if multiple displays are connected or if the | 132 // Do not change the state if multiple displays are connected or if the |
| 133 // only connected display is external. | 133 // only connected display is external. |
| 134 static const int kSetDisplayPowerOnlyIfSingleInternalDisplay = 1 << 1; | 134 static const int kSetDisplayPowerOnlyIfSingleInternalDisplay; |
| 135 | 135 |
| 136 // Gap between screens so cursor at bottom of active display doesn't | 136 // Gap between screens so cursor at bottom of active display doesn't |
| 137 // partially appear on top of inactive display. Higher numbers guard | 137 // partially appear on top of inactive display. Higher numbers guard |
| 138 // against larger cursors, but also waste more memory. | 138 // against larger cursors, but also waste more memory. |
| 139 // For simplicity, this is hard-coded to avoid the complexity of always | 139 // For simplicity, this is hard-coded to avoid the complexity of always |
| 140 // determining the DPI of the screen and rationalizing which screen we | 140 // determining the DPI of the screen and rationalizing which screen we |
| 141 // need to use for the DPI calculation. | 141 // need to use for the DPI calculation. |
| 142 // See crbug.com/130188 for initial discussion. | 142 // See crbug.com/130188 for initial discussion. |
| 143 static const int kVerticalGap = 60; | 143 static const int kVerticalGap = 60; |
| 144 | 144 |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 357 | 357 |
| 358 // Display protection requests of each client. | 358 // Display protection requests of each client. |
| 359 ProtectionRequests client_protection_requests_; | 359 ProtectionRequests client_protection_requests_; |
| 360 | 360 |
| 361 DISALLOW_COPY_AND_ASSIGN(DisplayConfigurator); | 361 DISALLOW_COPY_AND_ASSIGN(DisplayConfigurator); |
| 362 }; | 362 }; |
| 363 | 363 |
| 364 } // namespace ui | 364 } // namespace ui |
| 365 | 365 |
| 366 #endif // UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ | 366 #endif // UI_DISPLAY_CHROMEOS_DISPLAY_CONFIGURATOR_H_ |
| OLD | NEW |