Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(556)

Side by Side Diff: ui/display/display.h

Issue 2151563002: Add the fields bits-per-pixel and bits-per-component to Display. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/display/android/screen_android.cc ('k') | ui/display/display.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 147
148 // True if there is an internal display. 148 // True if there is an internal display.
149 static bool HasInternalDisplay(); 149 static bool HasInternalDisplay();
150 150
151 // Maximum cursor size in native pixels. 151 // Maximum cursor size in native pixels.
152 const gfx::Size& maximum_cursor_size() const { return maximum_cursor_size_; } 152 const gfx::Size& maximum_cursor_size() const { return maximum_cursor_size_; }
153 void set_maximum_cursor_size(const gfx::Size& size) { 153 void set_maximum_cursor_size(const gfx::Size& size) {
154 maximum_cursor_size_ = size; 154 maximum_cursor_size_ = size;
155 } 155 }
156 156
157 int bits_per_pixel() const { return bits_per_pixel_; }
158 void set_bits_per_pixel(int bits_per_pixel) {
159 bits_per_pixel_ = bits_per_pixel;
160 }
161
162 int bits_per_component() const { return bits_per_component_; }
163 void set_bits_per_component(int bits_per_component) {
164 bits_per_component_ = bits_per_component;
165 }
166
157 private: 167 private:
158 int64_t id_; 168 int64_t id_;
159 gfx::Rect bounds_; 169 gfx::Rect bounds_;
160 gfx::Rect work_area_; 170 gfx::Rect work_area_;
161 float device_scale_factor_; 171 float device_scale_factor_;
162 Rotation rotation_; 172 Rotation rotation_;
163 TouchSupport touch_support_; 173 TouchSupport touch_support_;
164 gfx::Size maximum_cursor_size_; 174 gfx::Size maximum_cursor_size_;
175 int bits_per_pixel_;
176 int bits_per_component_;
oshima 2016/07/14 14:09:37 In WebScreenInfo, they're depth depthPerComponent
gsennton 2016/07/14 14:34:07 I don't have a strong opinion about the naming her
165 }; 177 };
166 178
167 } // namespace display 179 } // namespace display
168 180
169 #endif // UI_DISPLAY_DISPLAY_H_ 181 #endif // UI_DISPLAY_DISPLAY_H_
OLDNEW
« no previous file with comments | « ui/display/android/screen_android.cc ('k') | ui/display/display.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698