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_rect.h" | 14 #include "ppapi/c/pp_rect.h" |
15 #include "ppapi/c/pp_var.h" | 15 #include "ppapi/c/pp_var.h" |
16 #include "ppapi/shared_impl/file_ref_impl.h" | |
bbudge
2011/08/23 20:35:59
I don't understand why you need this include here.
brettw
2011/08/24 23:41:09
It defines FileRef_CreateInfo for which there's a
| |
16 | 17 |
17 struct PP_FileInfo; | 18 struct PP_FileInfo; |
18 struct PP_ObjectProperty; | 19 struct PP_ObjectProperty; |
19 struct PP_Flash_Menu; | 20 struct PP_Flash_Menu; |
20 struct PP_Flash_NetAddress; | 21 struct PP_Flash_NetAddress; |
21 | 22 |
22 namespace ppapi { | 23 namespace ppapi { |
23 | 24 |
24 class HostResource; | 25 class HostResource; |
26 struct PPB_FileRef_CreateInfo; | |
25 | 27 |
26 namespace proxy { | 28 namespace proxy { |
27 | 29 |
28 struct PPBFileRef_CreateInfo; | |
29 struct PPBFlash_DrawGlyphs_Params; | 30 struct PPBFlash_DrawGlyphs_Params; |
30 struct PPBURLLoader_UpdateProgress_Params; | 31 struct PPBURLLoader_UpdateProgress_Params; |
31 struct SerializedDirEntry; | 32 struct SerializedDirEntry; |
32 struct SerializedFontDescription; | 33 struct SerializedFontDescription; |
33 class SerializedFlashMenu; | 34 class SerializedFlashMenu; |
34 class SerializedVar; | 35 class SerializedVar; |
35 | 36 |
36 } // namespace proxy | 37 } // namespace proxy |
37 } // namespace ppapi | 38 } // namespace ppapi |
38 | 39 |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
72 | 73 |
73 template<> | 74 template<> |
74 struct ParamTraits<ppapi::proxy::PPBFlash_DrawGlyphs_Params> { | 75 struct ParamTraits<ppapi::proxy::PPBFlash_DrawGlyphs_Params> { |
75 typedef ppapi::proxy::PPBFlash_DrawGlyphs_Params param_type; | 76 typedef ppapi::proxy::PPBFlash_DrawGlyphs_Params param_type; |
76 static void Write(Message* m, const param_type& p); | 77 static void Write(Message* m, const param_type& p); |
77 static bool Read(const Message* m, void** iter, param_type* r); | 78 static bool Read(const Message* m, void** iter, param_type* r); |
78 static void Log(const param_type& p, std::string* l); | 79 static void Log(const param_type& p, std::string* l); |
79 }; | 80 }; |
80 | 81 |
81 template<> | 82 template<> |
82 struct ParamTraits<ppapi::proxy::PPBFileRef_CreateInfo> { | 83 struct ParamTraits<ppapi::PPB_FileRef_CreateInfo> { |
83 typedef ppapi::proxy::PPBFileRef_CreateInfo param_type; | 84 typedef ppapi::PPB_FileRef_CreateInfo param_type; |
84 static void Write(Message* m, const param_type& p); | 85 static void Write(Message* m, const param_type& p); |
85 static bool Read(const Message* m, void** iter, param_type* r); | 86 static bool Read(const Message* m, void** iter, param_type* r); |
86 static void Log(const param_type& p, std::string* l); | 87 static void Log(const param_type& p, std::string* l); |
87 }; | 88 }; |
88 | 89 |
89 template<> | 90 template<> |
90 struct ParamTraits<ppapi::proxy::PPBURLLoader_UpdateProgress_Params> { | 91 struct ParamTraits<ppapi::proxy::PPBURLLoader_UpdateProgress_Params> { |
91 typedef ppapi::proxy::PPBURLLoader_UpdateProgress_Params param_type; | 92 typedef ppapi::proxy::PPBURLLoader_UpdateProgress_Params param_type; |
92 static void Write(Message* m, const param_type& p); | 93 static void Write(Message* m, const param_type& p); |
93 static bool Read(const Message* m, void** iter, param_type* r); | 94 static bool Read(const Message* m, void** iter, param_type* r); |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
128 | 129 |
129 template<> | 130 template<> |
130 struct ParamTraits< std::vector<ppapi::proxy::SerializedVar> > { | 131 struct ParamTraits< std::vector<ppapi::proxy::SerializedVar> > { |
131 typedef std::vector<ppapi::proxy::SerializedVar> param_type; | 132 typedef std::vector<ppapi::proxy::SerializedVar> param_type; |
132 static void Write(Message* m, const param_type& p); | 133 static void Write(Message* m, const param_type& p); |
133 static bool Read(const Message* m, void** iter, param_type* r); | 134 static bool Read(const Message* m, void** iter, param_type* r); |
134 static void Log(const param_type& p, std::string* l); | 135 static void Log(const param_type& p, std::string* l); |
135 }; | 136 }; |
136 | 137 |
137 template<> | 138 template<> |
138 struct ParamTraits< std::vector<ppapi::proxy::PPBFileRef_CreateInfo> > { | 139 struct ParamTraits< std::vector<ppapi::PPB_FileRef_CreateInfo> > { |
139 typedef std::vector<ppapi::proxy::PPBFileRef_CreateInfo> param_type; | 140 typedef std::vector<ppapi::PPB_FileRef_CreateInfo> param_type; |
140 static void Write(Message* m, const param_type& p); | 141 static void Write(Message* m, const param_type& p); |
141 static bool Read(const Message* m, void** iter, param_type* r); | 142 static bool Read(const Message* m, void** iter, param_type* r); |
142 static void Log(const param_type& p, std::string* l); | 143 static void Log(const param_type& p, std::string* l); |
143 }; | 144 }; |
144 | 145 |
145 template<> | 146 template<> |
146 struct ParamTraits<ppapi::proxy::SerializedFlashMenu> { | 147 struct ParamTraits<ppapi::proxy::SerializedFlashMenu> { |
147 typedef ppapi::proxy::SerializedFlashMenu param_type; | 148 typedef ppapi::proxy::SerializedFlashMenu param_type; |
148 static void Write(Message* m, const param_type& p); | 149 static void Write(Message* m, const param_type& p); |
149 static bool Read(const Message* m, void** iter, param_type* r); | 150 static bool Read(const Message* m, void** iter, param_type* r); |
150 static void Log(const param_type& p, std::string* l); | 151 static void Log(const param_type& p, std::string* l); |
151 }; | 152 }; |
152 | 153 |
153 } // namespace IPC | 154 } // namespace IPC |
154 | 155 |
155 #endif // PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ | 156 #endif // PPAPI_PROXY_PPAPI_PARAM_TRAITS_H_ |
OLD | NEW |