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_TEST_TEST_DISPLAY_SNAPSHOT_H_ | 5 #ifndef UI_DISPLAY_CHROMEOS_TEST_TEST_DISPLAY_SNAPSHOT_H_ |
6 #define UI_DISPLAY_CHROMEOS_TEST_TEST_DISPLAY_SNAPSHOT_H_ | 6 #define UI_DISPLAY_CHROMEOS_TEST_TEST_DISPLAY_SNAPSHOT_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "ui/display/display_export.h" | 11 #include "ui/display/display_export.h" |
12 #include "ui/display/types/display_snapshot.h" | 12 #include "ui/display/types/display_snapshot.h" |
13 | 13 |
14 namespace ui { | 14 namespace ui { |
15 | 15 |
16 class DISPLAY_EXPORT TestDisplaySnapshot : public DisplaySnapshot { | 16 class DISPLAY_EXPORT TestDisplaySnapshot : public DisplaySnapshot { |
17 public: | 17 public: |
18 TestDisplaySnapshot(); | 18 TestDisplaySnapshot(); |
19 TestDisplaySnapshot(int64_t display_id, | 19 TestDisplaySnapshot(int64_t display_id, |
20 const gfx::Point& origin, | 20 const gfx::Point& origin, |
21 const gfx::Size& physical_size, | 21 const gfx::Size& physical_size, |
22 DisplayConnectionType type, | 22 DisplayConnectionType type, |
23 bool is_aspect_preserving_scaling, | 23 bool is_aspect_preserving_scaling, |
24 int64_t product_id, | 24 int64_t product_id, |
| 25 bool has_color_correction_matrix, |
25 const std::vector<const DisplayMode*>& modes, | 26 const std::vector<const DisplayMode*>& modes, |
26 const DisplayMode* current_mode, | 27 const DisplayMode* current_mode, |
27 const DisplayMode* native_mode); | 28 const DisplayMode* native_mode); |
28 ~TestDisplaySnapshot() override; | 29 ~TestDisplaySnapshot() override; |
29 | 30 |
30 void set_type(DisplayConnectionType type) { type_ = type; } | 31 void set_type(DisplayConnectionType type) { type_ = type; } |
31 void set_modes(const std::vector<const DisplayMode*>& modes) { | 32 void set_modes(const std::vector<const DisplayMode*>& modes) { |
32 modes_ = modes; | 33 modes_ = modes; |
33 } | 34 } |
34 void set_current_mode(const ui::DisplayMode* mode) { current_mode_ = mode; } | 35 void set_current_mode(const ui::DisplayMode* mode) { current_mode_ = mode; } |
35 void set_native_mode(const ui::DisplayMode* mode) { native_mode_ = mode; } | 36 void set_native_mode(const ui::DisplayMode* mode) { native_mode_ = mode; } |
36 void set_is_aspect_preserving_scaling(bool state) { | 37 void set_is_aspect_preserving_scaling(bool state) { |
37 is_aspect_preserving_scaling_ = state; | 38 is_aspect_preserving_scaling_ = state; |
38 } | 39 } |
39 void set_display_id(int64_t id) { display_id_ = id; } | 40 void set_display_id(int64_t id) { display_id_ = id; } |
40 | 41 |
41 // DisplaySnapshot overrides: | 42 // DisplaySnapshot overrides: |
42 std::string ToString() const override; | 43 std::string ToString() const override; |
43 | 44 |
44 private: | 45 private: |
45 DISALLOW_COPY_AND_ASSIGN(TestDisplaySnapshot); | 46 DISALLOW_COPY_AND_ASSIGN(TestDisplaySnapshot); |
46 }; | 47 }; |
47 | 48 |
48 } // namespace ui | 49 } // namespace ui |
49 | 50 |
50 #endif // UI_DISPLAY_CHROMEOS_TEST_TEST_DISPLAY_SNAPSHOT_H_ | 51 #endif // UI_DISPLAY_CHROMEOS_TEST_TEST_DISPLAY_SNAPSHOT_H_ |
OLD | NEW |