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/resource_creation_proxy.h" | 5 #include "ppapi/proxy/resource_creation_proxy.h" |
6 | 6 |
7 #include "ppapi/c/pp_errors.h" | 7 #include "ppapi/c/pp_errors.h" |
8 #include "ppapi/c/pp_size.h" | 8 #include "ppapi/c/pp_size.h" |
9 #include "ppapi/proxy/interface_id.h" | 9 #include "ppapi/proxy/interface_id.h" |
10 #include "ppapi/proxy/plugin_dispatcher.h" | 10 #include "ppapi/proxy/plugin_dispatcher.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 #include "ppapi/proxy/ppb_flash_menu_proxy.h" | 21 #include "ppapi/proxy/ppb_flash_menu_proxy.h" |
22 #include "ppapi/proxy/ppb_flash_net_connector_proxy.h" | 22 #include "ppapi/proxy/ppb_flash_net_connector_proxy.h" |
23 #include "ppapi/proxy/ppb_flash_tcp_socket_proxy.h" | 23 #include "ppapi/proxy/ppb_flash_tcp_socket_proxy.h" |
24 #include "ppapi/proxy/ppb_font_proxy.h" | 24 #include "ppapi/proxy/ppb_font_proxy.h" |
25 #include "ppapi/proxy/ppb_graphics_2d_proxy.h" | 25 #include "ppapi/proxy/ppb_graphics_2d_proxy.h" |
26 #include "ppapi/proxy/ppb_graphics_3d_proxy.h" | 26 #include "ppapi/proxy/ppb_graphics_3d_proxy.h" |
27 #include "ppapi/proxy/ppb_image_data_proxy.h" | 27 #include "ppapi/proxy/ppb_image_data_proxy.h" |
28 #include "ppapi/proxy/ppb_input_event_proxy.h" | 28 #include "ppapi/proxy/ppb_input_event_proxy.h" |
29 #include "ppapi/proxy/ppb_surface_3d_proxy.h" | 29 #include "ppapi/proxy/ppb_surface_3d_proxy.h" |
30 #include "ppapi/proxy/ppb_url_loader_proxy.h" | 30 #include "ppapi/proxy/ppb_url_loader_proxy.h" |
31 #include "ppapi/proxy/ppb_url_request_info_proxy.h" | |
32 #include "ppapi/proxy/ppb_video_capture_proxy.h" | 31 #include "ppapi/proxy/ppb_video_capture_proxy.h" |
33 #include "ppapi/proxy/ppb_video_decoder_proxy.h" | 32 #include "ppapi/proxy/ppb_video_decoder_proxy.h" |
34 #include "ppapi/shared_impl/audio_config_impl.h" | 33 #include "ppapi/shared_impl/audio_config_impl.h" |
35 #include "ppapi/shared_impl/font_impl.h" | 34 #include "ppapi/shared_impl/font_impl.h" |
36 #include "ppapi/shared_impl/function_group_base.h" | 35 #include "ppapi/shared_impl/function_group_base.h" |
37 #include "ppapi/shared_impl/host_resource.h" | 36 #include "ppapi/shared_impl/host_resource.h" |
38 #include "ppapi/shared_impl/input_event_impl.h" | 37 #include "ppapi/shared_impl/input_event_impl.h" |
| 38 #include "ppapi/shared_impl/url_request_info_impl.h" |
39 #include "ppapi/shared_impl/var.h" | 39 #include "ppapi/shared_impl/var.h" |
40 #include "ppapi/thunk/enter.h" | 40 #include "ppapi/thunk/enter.h" |
41 #include "ppapi/thunk/ppb_image_data_api.h" | 41 #include "ppapi/thunk/ppb_image_data_api.h" |
42 | 42 |
43 using ppapi::thunk::ResourceCreationAPI; | 43 using ppapi::thunk::ResourceCreationAPI; |
44 | 44 |
45 namespace ppapi { | 45 namespace ppapi { |
46 namespace proxy { | 46 namespace proxy { |
47 | 47 |
48 ResourceCreationProxy::ResourceCreationProxy(Dispatcher* dispatcher) | 48 ResourceCreationProxy::ResourceCreationProxy(Dispatcher* dispatcher) |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
283 const char* name, | 283 const char* name, |
284 const char* proto) { | 284 const char* proto) { |
285 NOTIMPLEMENTED(); // Not proxied yet. | 285 NOTIMPLEMENTED(); // Not proxied yet. |
286 return 0; | 286 return 0; |
287 } | 287 } |
288 | 288 |
289 PP_Resource ResourceCreationProxy::CreateURLLoader(PP_Instance instance) { | 289 PP_Resource ResourceCreationProxy::CreateURLLoader(PP_Instance instance) { |
290 return PPB_URLLoader_Proxy::CreateProxyResource(instance); | 290 return PPB_URLLoader_Proxy::CreateProxyResource(instance); |
291 } | 291 } |
292 | 292 |
293 PP_Resource ResourceCreationProxy::CreateURLRequestInfo(PP_Instance instance) { | 293 PP_Resource ResourceCreationProxy::CreateURLRequestInfo( |
294 return PPB_URLRequestInfo_Proxy::CreateProxyResource(instance); | 294 PP_Instance instance, |
| 295 const PPB_URLRequestInfo_Data& data) { |
| 296 return (new URLRequestInfoImpl( |
| 297 HostResource::MakeInstanceOnly(instance), data))->GetReference(); |
295 } | 298 } |
296 | 299 |
297 PP_Resource ResourceCreationProxy::CreateVideoCapture(PP_Instance instance) { | 300 PP_Resource ResourceCreationProxy::CreateVideoCapture(PP_Instance instance) { |
298 return PPB_VideoCapture_Proxy::CreateProxyResource(instance); | 301 return PPB_VideoCapture_Proxy::CreateProxyResource(instance); |
299 } | 302 } |
300 | 303 |
301 PP_Resource ResourceCreationProxy::CreateVideoDecoder( | 304 PP_Resource ResourceCreationProxy::CreateVideoDecoder( |
302 PP_Instance instance, | 305 PP_Instance instance, |
303 PP_Resource context3d_id, | 306 PP_Resource context3d_id, |
304 const PP_VideoConfigElement* config) { | 307 const PP_VideoConfigElement* config) { |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
401 *result_image_handle = dispatcher_->ShareHandleWithRemote(ih, false); | 404 *result_image_handle = dispatcher_->ShareHandleWithRemote(ih, false); |
402 #else | 405 #else |
403 *result_image_handle = ImageData::HandleFromInt(handle); | 406 *result_image_handle = ImageData::HandleFromInt(handle); |
404 #endif | 407 #endif |
405 } | 408 } |
406 } | 409 } |
407 } | 410 } |
408 | 411 |
409 } // namespace proxy | 412 } // namespace proxy |
410 } // namespace ppapi | 413 } // namespace ppapi |
OLD | NEW |