| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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_MOJO_DISPLAY_SNAPSHOT_MOJO_STRUCT_TRAITS_H_ | 5 #ifndef UI_DISPLAY_MOJO_DISPLAY_SNAPSHOT_MOJO_STRUCT_TRAITS_H_ |
| 6 #define UI_DISPLAY_MOJO_DISPLAY_SNAPSHOT_MOJO_STRUCT_TRAITS_H_ | 6 #define UI_DISPLAY_MOJO_DISPLAY_SNAPSHOT_MOJO_STRUCT_TRAITS_H_ |
| 7 | 7 |
| 8 #include "ui/display/display_snapshot_mojo.h" | |
| 9 #include "ui/display/mojo/display_snapshot_mojo.mojom.h" | 8 #include "ui/display/mojo/display_snapshot_mojo.mojom.h" |
| 10 #include "ui/display/types/display_mode.h" | 9 #include "ui/display/types/display_mode.h" |
| 10 #include "ui/display/types/display_snapshot_mojo.h" |
| 11 | 11 |
| 12 namespace mojo { | 12 namespace mojo { |
| 13 | 13 |
| 14 template <> | 14 template <> |
| 15 struct StructTraits<display::mojom::DisplaySnapshotMojoDataView, | 15 struct StructTraits<display::mojom::DisplaySnapshotMojoDataView, |
| 16 std::unique_ptr<display::DisplaySnapshotMojo>> { | 16 std::unique_ptr<display::DisplaySnapshotMojo>> { |
| 17 static int64_t display_id( | 17 static int64_t display_id( |
| 18 const std::unique_ptr<display::DisplaySnapshotMojo>& snapshot) { | 18 const std::unique_ptr<display::DisplaySnapshotMojo>& snapshot) { |
| 19 return snapshot->display_id(); | 19 return snapshot->display_id(); |
| 20 } | 20 } |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 return snapshot->maximum_cursor_size(); | 93 return snapshot->maximum_cursor_size(); |
| 94 } | 94 } |
| 95 | 95 |
| 96 static bool Read(display::mojom::DisplaySnapshotMojoDataView data, | 96 static bool Read(display::mojom::DisplaySnapshotMojoDataView data, |
| 97 std::unique_ptr<display::DisplaySnapshotMojo>* out); | 97 std::unique_ptr<display::DisplaySnapshotMojo>* out); |
| 98 }; | 98 }; |
| 99 | 99 |
| 100 } // namespace mojo | 100 } // namespace mojo |
| 101 | 101 |
| 102 #endif // UI_DISPLAY_MOJO_DISPLAY_SNAPSHOT_MOJO_STRUCT_TRAITS_H_ | 102 #endif // UI_DISPLAY_MOJO_DISPLAY_SNAPSHOT_MOJO_STRUCT_TRAITS_H_ |
| OLD | NEW |