OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ | 5 #ifndef PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ |
6 #define PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ | 6 #define PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "ipc/ipc_message_utils.h" | 11 #include "ipc/ipc_message_utils.h" |
12 #include "ipc/ipc_platform_file.h" | 12 #include "ipc/ipc_platform_file.h" |
13 #include "ppapi/c/pp_completion_callback.h" | 13 #include "ppapi/c/pp_completion_callback.h" |
14 #include "ppapi/c/pp_input_event.h" | |
15 #include "ppapi/c/pp_rect.h" | 14 #include "ppapi/c/pp_rect.h" |
16 #include "ppapi/c/pp_var.h" | 15 #include "ppapi/c/pp_var.h" |
17 | 16 |
18 struct PP_FileInfo; | 17 struct PP_FileInfo; |
19 struct PP_ObjectProperty; | 18 struct PP_ObjectProperty; |
20 struct PP_Flash_Menu; | 19 struct PP_Flash_Menu; |
21 struct PP_Flash_NetAddress; | 20 struct PP_Flash_NetAddress; |
22 | 21 |
23 namespace pp { | 22 namespace pp { |
24 namespace proxy { | 23 namespace proxy { |
(...skipping 30 matching lines...) Expand all Loading... |
55 | 54 |
56 template <> | 55 template <> |
57 struct ParamTraits<PP_Flash_NetAddress> { | 56 struct ParamTraits<PP_Flash_NetAddress> { |
58 typedef PP_Flash_NetAddress param_type; | 57 typedef PP_Flash_NetAddress param_type; |
59 static void Write(Message* m, const param_type& p); | 58 static void Write(Message* m, const param_type& p); |
60 static bool Read(const Message* m, void** iter, param_type* p); | 59 static bool Read(const Message* m, void** iter, param_type* p); |
61 static void Log(const param_type& p, std::string* l); | 60 static void Log(const param_type& p, std::string* l); |
62 }; | 61 }; |
63 | 62 |
64 template<> | 63 template<> |
65 struct ParamTraits<PP_InputEvent> { | |
66 typedef PP_InputEvent param_type; | |
67 static void Write(Message* m, const param_type& p); | |
68 static bool Read(const Message* m, void** iter, param_type* r); | |
69 static void Log(const param_type& p, std::string* l); | |
70 }; | |
71 | |
72 template<> | |
73 struct ParamTraits<PP_ObjectProperty> { | 64 struct ParamTraits<PP_ObjectProperty> { |
74 typedef PP_ObjectProperty param_type; | 65 typedef PP_ObjectProperty param_type; |
75 static void Write(Message* m, const param_type& p); | 66 static void Write(Message* m, const param_type& p); |
76 static bool Read(const Message* m, void** iter, param_type* r); | 67 static bool Read(const Message* m, void** iter, param_type* r); |
77 static void Log(const param_type& p, std::string* l); | 68 static void Log(const param_type& p, std::string* l); |
78 }; | 69 }; |
79 | 70 |
80 template<> | 71 template<> |
81 struct ParamTraits<pp::proxy::PPBFlash_DrawGlyphs_Params> { | 72 struct ParamTraits<pp::proxy::PPBFlash_DrawGlyphs_Params> { |
82 typedef pp::proxy::PPBFlash_DrawGlyphs_Params param_type; | 73 typedef pp::proxy::PPBFlash_DrawGlyphs_Params param_type; |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 struct ParamTraits<pp::proxy::SerializedFlashMenu> { | 144 struct ParamTraits<pp::proxy::SerializedFlashMenu> { |
154 typedef pp::proxy::SerializedFlashMenu param_type; | 145 typedef pp::proxy::SerializedFlashMenu param_type; |
155 static void Write(Message* m, const param_type& p); | 146 static void Write(Message* m, const param_type& p); |
156 static bool Read(const Message* m, void** iter, param_type* r); | 147 static bool Read(const Message* m, void** iter, param_type* r); |
157 static void Log(const param_type& p, std::string* l); | 148 static void Log(const param_type& p, std::string* l); |
158 }; | 149 }; |
159 | 150 |
160 } // namespace IPC | 151 } // namespace IPC |
161 | 152 |
162 #endif // PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ | 153 #endif // PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ |
OLD | NEW |