| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/c/trusted/ppb_image_data_trusted.h" | 9 #include "ppapi/c/trusted/ppb_image_data_trusted.h" |
| 10 #include "ppapi/proxy/connection.h" | 10 #include "ppapi/proxy/connection.h" |
| 11 #include "ppapi/proxy/file_chooser_resource.h" | 11 #include "ppapi/proxy/file_chooser_resource.h" |
| 12 #include "ppapi/proxy/flash_device_id_resource.h" | 12 #include "ppapi/proxy/flash_device_id_resource.h" |
| 13 #include "ppapi/proxy/flash_font_file_resource.h" |
| 13 #include "ppapi/proxy/plugin_dispatcher.h" | 14 #include "ppapi/proxy/plugin_dispatcher.h" |
| 14 #include "ppapi/proxy/plugin_globals.h" | 15 #include "ppapi/proxy/plugin_globals.h" |
| 15 #include "ppapi/proxy/plugin_proxy_delegate.h" | 16 #include "ppapi/proxy/plugin_proxy_delegate.h" |
| 16 #include "ppapi/proxy/plugin_resource_tracker.h" | 17 #include "ppapi/proxy/plugin_resource_tracker.h" |
| 17 #include "ppapi/proxy/ppapi_messages.h" | 18 #include "ppapi/proxy/ppapi_messages.h" |
| 18 #include "ppapi/proxy/ppb_audio_input_proxy.h" | 19 #include "ppapi/proxy/ppb_audio_input_proxy.h" |
| 19 #include "ppapi/proxy/ppb_audio_proxy.h" | 20 #include "ppapi/proxy/ppb_audio_proxy.h" |
| 20 #include "ppapi/proxy/ppb_buffer_proxy.h" | 21 #include "ppapi/proxy/ppb_buffer_proxy.h" |
| 21 #include "ppapi/proxy/ppb_broker_proxy.h" | 22 #include "ppapi/proxy/ppb_broker_proxy.h" |
| 22 #include "ppapi/proxy/ppb_file_io_proxy.h" | 23 #include "ppapi/proxy/ppb_file_io_proxy.h" |
| (...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 307 PP_FileChooserMode_Dev mode, | 308 PP_FileChooserMode_Dev mode, |
| 308 const char* accept_types) { | 309 const char* accept_types) { |
| 309 return (new FileChooserResource(GetConnection(), instance, mode, | 310 return (new FileChooserResource(GetConnection(), instance, mode, |
| 310 accept_types))->GetReference(); | 311 accept_types))->GetReference(); |
| 311 } | 312 } |
| 312 | 313 |
| 313 PP_Resource ResourceCreationProxy::CreateFlashDeviceID(PP_Instance instance) { | 314 PP_Resource ResourceCreationProxy::CreateFlashDeviceID(PP_Instance instance) { |
| 314 return (new FlashDeviceIDResource(GetConnection(), instance))->GetReference(); | 315 return (new FlashDeviceIDResource(GetConnection(), instance))->GetReference(); |
| 315 } | 316 } |
| 316 | 317 |
| 318 PP_Resource ResourceCreationProxy::CreateFlashFontFile( |
| 319 PP_Instance instance, |
| 320 const PP_FontDescription_Dev* description, |
| 321 PP_PrivateFontCharset charset) { |
| 322 return (new FlashFontFileResource( |
| 323 GetConnection(), instance, description, charset))->GetReference(); |
| 324 } |
| 325 |
| 317 PP_Resource ResourceCreationProxy::CreateFlashMenu( | 326 PP_Resource ResourceCreationProxy::CreateFlashMenu( |
| 318 PP_Instance instance, | 327 PP_Instance instance, |
| 319 const PP_Flash_Menu* menu_data) { | 328 const PP_Flash_Menu* menu_data) { |
| 320 return PPB_Flash_Menu_Proxy::CreateProxyResource(instance, menu_data); | 329 return PPB_Flash_Menu_Proxy::CreateProxyResource(instance, menu_data); |
| 321 } | 330 } |
| 322 | 331 |
| 323 PP_Resource ResourceCreationProxy::CreateFlashMessageLoop( | 332 PP_Resource ResourceCreationProxy::CreateFlashMessageLoop( |
| 324 PP_Instance instance) { | 333 PP_Instance instance) { |
| 325 return PPB_Flash_MessageLoop_Proxy::CreateProxyResource(instance); | 334 return PPB_Flash_MessageLoop_Proxy::CreateProxyResource(instance); |
| 326 } | 335 } |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 367 } | 376 } |
| 368 | 377 |
| 369 Connection ResourceCreationProxy::GetConnection() { | 378 Connection ResourceCreationProxy::GetConnection() { |
| 370 return Connection( | 379 return Connection( |
| 371 PluginGlobals::Get()->plugin_proxy_delegate()->GetBrowserSender(), | 380 PluginGlobals::Get()->plugin_proxy_delegate()->GetBrowserSender(), |
| 372 dispatcher()); | 381 dispatcher()); |
| 373 } | 382 } |
| 374 | 383 |
| 375 } // namespace proxy | 384 } // namespace proxy |
| 376 } // namespace ppapi | 385 } // namespace ppapi |
| OLD | NEW |