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_DISPLAY_H_ | 5 #ifndef UI_DISPLAY_DISPLAY_H_ |
6 #define UI_DISPLAY_DISPLAY_H_ | 6 #define UI_DISPLAY_DISPLAY_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
94 const gfx::Rect& work_area() const { return work_area_; } | 94 const gfx::Rect& work_area() const { return work_area_; } |
95 void set_work_area(const gfx::Rect& work_area) { work_area_ = work_area; } | 95 void set_work_area(const gfx::Rect& work_area) { work_area_ = work_area; } |
96 | 96 |
97 // Output device's pixel scale factor. This specifies how much the | 97 // Output device's pixel scale factor. This specifies how much the |
98 // UI should be scaled when the actual output has more pixels than | 98 // UI should be scaled when the actual output has more pixels than |
99 // standard displays (which is around 100~120dpi.) The potential return | 99 // standard displays (which is around 100~120dpi.) The potential return |
100 // values depend on each platforms. | 100 // values depend on each platforms. |
101 float device_scale_factor() const { return device_scale_factor_; } | 101 float device_scale_factor() const { return device_scale_factor_; } |
102 void set_device_scale_factor(float scale) { device_scale_factor_ = scale; } | 102 void set_device_scale_factor(float scale) { device_scale_factor_ = scale; } |
103 | 103 |
104 static int RotationAsDegree(Rotation rotation); | |
oshima
2017/03/28 12:50:15
Can you rename to RotateToDegree, and move it afte
Dominik Laskowski
2017/03/30 01:17:15
Done.
| |
105 | |
104 Rotation rotation() const { return rotation_; } | 106 Rotation rotation() const { return rotation_; } |
105 void set_rotation(Rotation rotation) { rotation_ = rotation; } | 107 void set_rotation(Rotation rotation) { rotation_ = rotation; } |
106 int RotationAsDegree() const; | 108 int RotationAsDegree() const; |
107 void SetRotationAsDegree(int rotation); | 109 void SetRotationAsDegree(int rotation); |
108 | 110 |
109 TouchSupport touch_support() const { return touch_support_; } | 111 TouchSupport touch_support() const { return touch_support_; } |
110 void set_touch_support(TouchSupport support) { touch_support_ = support; } | 112 void set_touch_support(TouchSupport support) { touch_support_ = support; } |
111 | 113 |
112 // Utility functions that just return the size of display and | 114 // Utility functions that just return the size of display and |
113 // work area. | 115 // work area. |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
203 gfx::Size maximum_cursor_size_; | 205 gfx::Size maximum_cursor_size_; |
204 gfx::ICCProfile icc_profile_; | 206 gfx::ICCProfile icc_profile_; |
205 int color_depth_; | 207 int color_depth_; |
206 int depth_per_component_; | 208 int depth_per_component_; |
207 bool is_monochrome_ = false; | 209 bool is_monochrome_ = false; |
208 }; | 210 }; |
209 | 211 |
210 } // namespace display | 212 } // namespace display |
211 | 213 |
212 #endif // UI_DISPLAY_DISPLAY_H_ | 214 #endif // UI_DISPLAY_DISPLAY_H_ |
OLD | NEW |