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 #include "ppapi/proxy/ppapi_param_traits.h" | 5 #include "ppapi/proxy/ppapi_param_traits.h" |
6 | 6 |
7 #include <string.h> // For memcpy | 7 #include <string.h> // For memcpy |
8 | 8 |
9 #include "ppapi/c/dev/pp_file_info_dev.h" | 9 #include "ppapi/c/dev/pp_file_info_dev.h" |
10 #include "ppapi/c/pp_resource.h" | 10 #include "ppapi/c/pp_resource.h" |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 ParamTraits<std::vector<PP_Point> >::Read(m, iter, &r->glyph_advances) && | 234 ParamTraits<std::vector<PP_Point> >::Read(m, iter, &r->glyph_advances) && |
235 r->glyph_indices.size() == r->glyph_advances.size(); | 235 r->glyph_indices.size() == r->glyph_advances.size(); |
236 } | 236 } |
237 | 237 |
238 // static | 238 // static |
239 void ParamTraits<pp::proxy::PPBFlash_DrawGlyphs_Params>::Log( | 239 void ParamTraits<pp::proxy::PPBFlash_DrawGlyphs_Params>::Log( |
240 const param_type& p, | 240 const param_type& p, |
241 std::string* l) { | 241 std::string* l) { |
242 } | 242 } |
243 | 243 |
| 244 // PPBFileRef_CreateInfo ------------------------------------------------------- |
| 245 |
| 246 // static |
| 247 void ParamTraits<pp::proxy::PPBFileRef_CreateInfo>::Write( |
| 248 Message* m, |
| 249 const param_type& p) { |
| 250 ParamTraits<pp::proxy::HostResource>::Write(m, p.resource); |
| 251 ParamTraits<int>::Write(m, p.file_system_type); |
| 252 ParamTraits<pp::proxy::SerializedVar>::Write(m, p.path); |
| 253 ParamTraits<pp::proxy::SerializedVar>::Write(m, p.name); |
| 254 } |
| 255 |
| 256 // static |
| 257 bool ParamTraits<pp::proxy::PPBFileRef_CreateInfo>::Read(const Message* m, |
| 258 void** iter, |
| 259 param_type* r) { |
| 260 return |
| 261 ParamTraits<pp::proxy::HostResource>::Read(m, iter, &r->resource) && |
| 262 ParamTraits<int>::Read(m, iter, &r->file_system_type) && |
| 263 ParamTraits<pp::proxy::SerializedVar>::Read(m, iter, &r->path) && |
| 264 ParamTraits<pp::proxy::SerializedVar>::Read(m, iter, &r->name); |
| 265 } |
| 266 |
| 267 // static |
| 268 void ParamTraits<pp::proxy::PPBFileRef_CreateInfo>::Log( |
| 269 const param_type& p, |
| 270 std::string* l) { |
| 271 } |
| 272 |
244 // PPBFont_DrawTextAt_Params --------------------------------------------------- | 273 // PPBFont_DrawTextAt_Params --------------------------------------------------- |
245 | 274 |
246 // static | 275 // static |
247 void ParamTraits<pp::proxy::PPBFont_DrawTextAt_Params>::Write( | 276 void ParamTraits<pp::proxy::PPBFont_DrawTextAt_Params>::Write( |
248 Message* m, | 277 Message* m, |
249 const param_type& p) { | 278 const param_type& p) { |
250 ParamTraits<pp::proxy::HostResource>::Write(m, p.font); | 279 ParamTraits<pp::proxy::HostResource>::Write(m, p.font); |
251 ParamTraits<pp::proxy::HostResource>::Write(m, p.image_data); | 280 ParamTraits<pp::proxy::HostResource>::Write(m, p.image_data); |
252 ParamTraits<PP_Bool>::Write(m, p.text_is_rtl); | 281 ParamTraits<PP_Bool>::Write(m, p.text_is_rtl); |
253 ParamTraits<PP_Bool>::Write(m, p.override_direction); | 282 ParamTraits<PP_Bool>::Write(m, p.override_direction); |
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
492 param_type* r) { | 521 param_type* r) { |
493 return r->ReadFromMessage(m, iter); | 522 return r->ReadFromMessage(m, iter); |
494 } | 523 } |
495 | 524 |
496 // static | 525 // static |
497 void ParamTraits<pp::proxy::SerializedFlashMenu>::Log(const param_type& p, | 526 void ParamTraits<pp::proxy::SerializedFlashMenu>::Log(const param_type& p, |
498 std::string* l) { | 527 std::string* l) { |
499 } | 528 } |
500 | 529 |
501 } // namespace IPC | 530 } // namespace IPC |
OLD | NEW |