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

Side by Side Diff: ui/display/mojo/display_struct_traits.cc

Issue 2857033002: Remove DisplayStructTraitsTest interface. (Closed)
Patch Set: SerializeAndDeserialize. Created 3 years, 7 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "ui/display/mojo/display_struct_traits.h" 5 #include "ui/display/mojo/display_struct_traits.h"
6 6
7 #include "ui/gfx/geometry/mojo/geometry_struct_traits.h"
8
9 namespace mojo { 7 namespace mojo {
10 8
11 display::mojom::Rotation 9 display::mojom::Rotation
12 EnumTraits<display::mojom::Rotation, display::Display::Rotation>::ToMojom( 10 EnumTraits<display::mojom::Rotation, display::Display::Rotation>::ToMojom(
13 display::Display::Rotation rotation) { 11 display::Display::Rotation rotation) {
14 switch (rotation) { 12 switch (rotation) {
15 case display::Display::ROTATE_0: 13 case display::Display::ROTATE_0:
16 return display::mojom::Rotation::VALUE_0; 14 return display::mojom::Rotation::VALUE_0;
17 case display::Display::ROTATE_90: 15 case display::Display::ROTATE_90:
18 return display::mojom::Rotation::VALUE_90; 16 return display::mojom::Rotation::VALUE_90;
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 if (!data.ReadTouchSupport(&out->touch_support_)) 96 if (!data.ReadTouchSupport(&out->touch_support_))
99 return false; 97 return false;
100 98
101 if (!data.ReadMaximumCursorSize(&out->maximum_cursor_size_)) 99 if (!data.ReadMaximumCursorSize(&out->maximum_cursor_size_))
102 return false; 100 return false;
103 101
104 return true; 102 return true;
105 } 103 }
106 104
107 } // namespace mojo 105 } // namespace mojo
OLDNEW
« no previous file with comments | « ui/display/mojo/display_struct_traits.h ('k') | ui/display/mojo/display_struct_traits_test.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698