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 MOJO_EXAMPLES_PEPPER_CONTAINER_APP_TYPE_CONVERTERS_H_ | 5 #ifndef MOJO_EXAMPLES_PEPPER_CONTAINER_APP_TYPE_CONVERTERS_H_ |
6 #define MOJO_EXAMPLES_PEPPER_CONTAINER_APP_TYPE_CONVERTERS_H_ | 6 #define MOJO_EXAMPLES_PEPPER_CONTAINER_APP_TYPE_CONVERTERS_H_ |
7 | 7 |
8 #include "mojo/public/bindings/type_converter.h" | 8 #include "mojo/public/cpp/bindings/type_converter.h" |
9 #include "mojo/services/native_viewport/native_viewport.mojom.h" | 9 #include "mojo/services/native_viewport/native_viewport.mojom.h" |
10 #include "ppapi/c/pp_point.h" | 10 #include "ppapi/c/pp_point.h" |
11 #include "ppapi/c/pp_rect.h" | 11 #include "ppapi/c/pp_rect.h" |
12 #include "ppapi/c/pp_size.h" | 12 #include "ppapi/c/pp_size.h" |
13 | 13 |
14 namespace mojo { | 14 namespace mojo { |
15 | 15 |
16 template <> | 16 template <> |
17 class TypeConverter<Point, PP_Point> { | 17 class TypeConverter<Point, PP_Point> { |
18 public: | 18 public: |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 static PP_Rect ConvertTo(const Rect& input) { | 58 static PP_Rect ConvertTo(const Rect& input) { |
59 PP_Rect rect = { input.position().To<PP_Point>(), | 59 PP_Rect rect = { input.position().To<PP_Point>(), |
60 input.size().To<PP_Size>() }; | 60 input.size().To<PP_Size>() }; |
61 return rect; | 61 return rect; |
62 } | 62 } |
63 }; | 63 }; |
64 | 64 |
65 } // namespace mojo | 65 } // namespace mojo |
66 | 66 |
67 #endif // MOJO_EXAMPLES_PEPPER_CONTAINER_APP_TYPE_CONVERTERS_H_ | 67 #endif // MOJO_EXAMPLES_PEPPER_CONTAINER_APP_TYPE_CONVERTERS_H_ |
OLD | NEW |