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 "ipc/ipc_message_utils.h" | 8 #include "ipc/ipc_message_utils.h" |
9 #include "ipc/ipc_platform_file.h" | 9 #include "ipc/ipc_platform_file.h" |
10 #include "ppapi/c/pp_completion_callback.h" | 10 #include "ppapi/c/pp_completion_callback.h" |
11 #include "ppapi/c/pp_input_event.h" | 11 #include "ppapi/c/pp_input_event.h" |
12 #include "ppapi/c/pp_rect.h" | 12 #include "ppapi/c/pp_rect.h" |
13 #include "ppapi/c/pp_var.h" | 13 #include "ppapi/c/pp_var.h" |
14 | 14 |
15 struct PP_FileInfo_Dev; | 15 struct PP_FileInfo_Dev; |
16 struct PP_ObjectProperty; | 16 struct PP_ObjectProperty; |
17 struct PP_Flash_Menu; | 17 struct PP_Flash_Menu; |
18 | 18 |
19 namespace pp { | 19 namespace pp { |
20 namespace proxy { | 20 namespace proxy { |
21 | 21 |
22 class HostResource; | 22 class HostResource; |
23 struct PPBFileRef_CreateInfo; | 23 struct PPBFileRef_CreateInfo; |
24 struct PPBFlash_DrawGlyphs_Params; | 24 struct PPBFlash_DrawGlyphs_Params; |
25 struct PPBFont_DrawTextAt_Params; | |
26 struct PPBURLLoader_UpdateProgress_Params; | 25 struct PPBURLLoader_UpdateProgress_Params; |
27 struct SerializedDirEntry; | 26 struct SerializedDirEntry; |
28 struct SerializedFontDescription; | 27 struct SerializedFontDescription; |
29 class SerializedFlashMenu; | 28 class SerializedFlashMenu; |
30 class SerializedVar; | 29 class SerializedVar; |
31 | 30 |
32 } // namespace proxy | 31 } // namespace proxy |
33 } // namespace pp | 32 } // namespace pp |
34 | 33 |
35 namespace IPC { | 34 namespace IPC { |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 | 75 |
77 template<> | 76 template<> |
78 struct ParamTraits<pp::proxy::PPBFileRef_CreateInfo> { | 77 struct ParamTraits<pp::proxy::PPBFileRef_CreateInfo> { |
79 typedef pp::proxy::PPBFileRef_CreateInfo param_type; | 78 typedef pp::proxy::PPBFileRef_CreateInfo param_type; |
80 static void Write(Message* m, const param_type& p); | 79 static void Write(Message* m, const param_type& p); |
81 static bool Read(const Message* m, void** iter, param_type* r); | 80 static bool Read(const Message* m, void** iter, param_type* r); |
82 static void Log(const param_type& p, std::string* l); | 81 static void Log(const param_type& p, std::string* l); |
83 }; | 82 }; |
84 | 83 |
85 template<> | 84 template<> |
86 struct ParamTraits<pp::proxy::PPBFont_DrawTextAt_Params> { | |
87 typedef pp::proxy::PPBFont_DrawTextAt_Params param_type; | |
88 static void Write(Message* m, const param_type& p); | |
89 static bool Read(const Message* m, void** iter, param_type* r); | |
90 static void Log(const param_type& p, std::string* l); | |
91 }; | |
92 | |
93 template<> | |
94 struct ParamTraits<pp::proxy::PPBURLLoader_UpdateProgress_Params> { | 85 struct ParamTraits<pp::proxy::PPBURLLoader_UpdateProgress_Params> { |
95 typedef pp::proxy::PPBURLLoader_UpdateProgress_Params param_type; | 86 typedef pp::proxy::PPBURLLoader_UpdateProgress_Params param_type; |
96 static void Write(Message* m, const param_type& p); | 87 static void Write(Message* m, const param_type& p); |
97 static bool Read(const Message* m, void** iter, param_type* r); | 88 static bool Read(const Message* m, void** iter, param_type* r); |
98 static void Log(const param_type& p, std::string* l); | 89 static void Log(const param_type& p, std::string* l); |
99 }; | 90 }; |
100 | 91 |
101 template<> | 92 template<> |
102 struct ParamTraits<pp::proxy::SerializedDirEntry> { | 93 struct ParamTraits<pp::proxy::SerializedDirEntry> { |
103 typedef pp::proxy::SerializedDirEntry param_type; | 94 typedef pp::proxy::SerializedDirEntry param_type; |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 struct ParamTraits<pp::proxy::SerializedFlashMenu> { | 141 struct ParamTraits<pp::proxy::SerializedFlashMenu> { |
151 typedef pp::proxy::SerializedFlashMenu param_type; | 142 typedef pp::proxy::SerializedFlashMenu param_type; |
152 static void Write(Message* m, const param_type& p); | 143 static void Write(Message* m, const param_type& p); |
153 static bool Read(const Message* m, void** iter, param_type* r); | 144 static bool Read(const Message* m, void** iter, param_type* r); |
154 static void Log(const param_type& p, std::string* l); | 145 static void Log(const param_type& p, std::string* l); |
155 }; | 146 }; |
156 | 147 |
157 } // namespace IPC | 148 } // namespace IPC |
158 | 149 |
159 #endif // PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ | 150 #endif // PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ |
OLD | NEW |