| 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 "webkit/plugins/ppapi/resource_creation_impl.h" | 5 #include "webkit/plugins/ppapi/resource_creation_impl.h" |
| 6 | 6 |
| 7 #include "ppapi/c/pp_size.h" | 7 #include "ppapi/c/pp_size.h" |
| 8 #include "ppapi/shared_impl/ppb_audio_config_shared.h" | 8 #include "ppapi/shared_impl/ppb_audio_config_shared.h" |
| 9 #include "ppapi/shared_impl/private/ppb_browser_font_trusted_shared.h" | 9 #include "ppapi/shared_impl/private/ppb_browser_font_trusted_shared.h" |
| 10 #include "ppapi/shared_impl/ppb_input_event_shared.h" | 10 #include "ppapi/shared_impl/ppb_input_event_shared.h" |
| 11 #include "ppapi/shared_impl/ppb_resource_array_shared.h" | 11 #include "ppapi/shared_impl/ppb_resource_array_shared.h" |
| 12 #include "ppapi/shared_impl/var.h" | 12 #include "ppapi/shared_impl/var.h" |
| 13 #include "webkit/plugins/ppapi/common.h" | 13 #include "webkit/plugins/ppapi/common.h" |
| 14 #include "webkit/plugins/ppapi/ppb_audio_impl.h" | 14 #include "webkit/plugins/ppapi/ppb_audio_impl.h" |
| 15 #include "webkit/plugins/ppapi/ppb_audio_input_impl.h" | 15 #include "webkit/plugins/ppapi/ppb_audio_input_impl.h" |
| 16 #include "webkit/plugins/ppapi/ppb_broker_impl.h" | 16 #include "webkit/plugins/ppapi/ppb_broker_impl.h" |
| 17 #include "webkit/plugins/ppapi/ppb_buffer_impl.h" | 17 #include "webkit/plugins/ppapi/ppb_buffer_impl.h" |
| 18 #include "webkit/plugins/ppapi/ppb_directory_reader_impl.h" | 18 #include "webkit/plugins/ppapi/ppb_directory_reader_impl.h" |
| 19 #include "webkit/plugins/ppapi/ppb_file_chooser_impl.h" | 19 #include "webkit/plugins/ppapi/ppb_file_chooser_impl.h" |
| 20 #include "webkit/plugins/ppapi/ppb_file_io_impl.h" | 20 #include "webkit/plugins/ppapi/ppb_file_io_impl.h" |
| 21 #include "webkit/plugins/ppapi/ppb_file_ref_impl.h" | 21 #include "webkit/plugins/ppapi/ppb_file_ref_impl.h" |
| 22 #include "webkit/plugins/ppapi/ppb_file_system_impl.h" | 22 #include "webkit/plugins/ppapi/ppb_file_system_impl.h" |
| 23 #include "webkit/plugins/ppapi/ppb_flash_menu_impl.h" | 23 #include "webkit/plugins/ppapi/ppb_flash_menu_impl.h" |
| 24 #include "webkit/plugins/ppapi/ppb_flash_message_loop_impl.h" | 24 #include "webkit/plugins/ppapi/ppb_flash_message_loop_impl.h" |
| 25 #include "webkit/plugins/ppapi/ppb_flash_net_connector_impl.h" | 25 #include "webkit/plugins/ppapi/ppb_flash_net_connector_impl.h" |
| 26 #include "webkit/plugins/ppapi/ppb_graphics_2d_impl.h" | 26 #include "webkit/plugins/ppapi/ppb_graphics_2d_impl.h" |
| 27 #include "webkit/plugins/ppapi/ppb_graphics_3d_impl.h" | 27 #include "webkit/plugins/ppapi/ppb_graphics_3d_impl.h" |
| 28 #include "webkit/plugins/ppapi/ppb_host_resolver_private_impl.h" |
| 28 #include "webkit/plugins/ppapi/ppb_image_data_impl.h" | 29 #include "webkit/plugins/ppapi/ppb_image_data_impl.h" |
| 29 #include "webkit/plugins/ppapi/ppb_scrollbar_impl.h" | 30 #include "webkit/plugins/ppapi/ppb_scrollbar_impl.h" |
| 30 #include "webkit/plugins/ppapi/ppb_tcp_server_socket_private_impl.h" | 31 #include "webkit/plugins/ppapi/ppb_tcp_server_socket_private_impl.h" |
| 31 #include "webkit/plugins/ppapi/ppb_tcp_socket_private_impl.h" | 32 #include "webkit/plugins/ppapi/ppb_tcp_socket_private_impl.h" |
| 32 #include "webkit/plugins/ppapi/ppb_transport_impl.h" | 33 #include "webkit/plugins/ppapi/ppb_transport_impl.h" |
| 33 #include "webkit/plugins/ppapi/ppb_udp_socket_private_impl.h" | 34 #include "webkit/plugins/ppapi/ppb_udp_socket_private_impl.h" |
| 34 #include "webkit/plugins/ppapi/ppb_url_loader_impl.h" | 35 #include "webkit/plugins/ppapi/ppb_url_loader_impl.h" |
| 35 #include "webkit/plugins/ppapi/ppb_url_request_info_impl.h" | 36 #include "webkit/plugins/ppapi/ppb_url_request_info_impl.h" |
| 36 #include "webkit/plugins/ppapi/ppb_video_capture_impl.h" | 37 #include "webkit/plugins/ppapi/ppb_video_capture_impl.h" |
| 37 #include "webkit/plugins/ppapi/ppb_video_decoder_impl.h" | 38 #include "webkit/plugins/ppapi/ppb_video_decoder_impl.h" |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 172 return PPB_Graphics3D_Impl::Create(instance, share_context, attrib_list); | 173 return PPB_Graphics3D_Impl::Create(instance, share_context, attrib_list); |
| 173 } | 174 } |
| 174 | 175 |
| 175 PP_Resource ResourceCreationImpl::CreateGraphics3DRaw( | 176 PP_Resource ResourceCreationImpl::CreateGraphics3DRaw( |
| 176 PP_Instance instance, | 177 PP_Instance instance, |
| 177 PP_Resource share_context, | 178 PP_Resource share_context, |
| 178 const int32_t* attrib_list) { | 179 const int32_t* attrib_list) { |
| 179 return PPB_Graphics3D_Impl::CreateRaw(instance, share_context, attrib_list); | 180 return PPB_Graphics3D_Impl::CreateRaw(instance, share_context, attrib_list); |
| 180 } | 181 } |
| 181 | 182 |
| 183 PP_Resource ResourceCreationImpl::CreateHostResolverPrivate( |
| 184 PP_Instance instance) { |
| 185 return (new PPB_HostResolver_Private_Impl(instance))->GetReference(); |
| 186 } |
| 187 |
| 182 PP_Resource ResourceCreationImpl::CreateImageData(PP_Instance instance, | 188 PP_Resource ResourceCreationImpl::CreateImageData(PP_Instance instance, |
| 183 PP_ImageDataFormat format, | 189 PP_ImageDataFormat format, |
| 184 const PP_Size& size, | 190 const PP_Size& size, |
| 185 PP_Bool init_to_zero) { | 191 PP_Bool init_to_zero) { |
| 186 return PPB_ImageData_Impl::Create(instance, format, size, init_to_zero); | 192 return PPB_ImageData_Impl::Create(instance, format, size, init_to_zero); |
| 187 } | 193 } |
| 188 | 194 |
| 189 PP_Resource ResourceCreationImpl::CreateKeyboardInputEvent( | 195 PP_Resource ResourceCreationImpl::CreateKeyboardInputEvent( |
| 190 PP_Instance instance, | 196 PP_Instance instance, |
| 191 PP_InputEvent_Type type, | 197 PP_InputEvent_Type type, |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 329 data.wheel_delta = *wheel_delta; | 335 data.wheel_delta = *wheel_delta; |
| 330 data.wheel_ticks = *wheel_ticks; | 336 data.wheel_ticks = *wheel_ticks; |
| 331 data.wheel_scroll_by_page = PP_ToBool(scroll_by_page); | 337 data.wheel_scroll_by_page = PP_ToBool(scroll_by_page); |
| 332 | 338 |
| 333 return (new PPB_InputEvent_Shared(::ppapi::OBJECT_IS_IMPL, | 339 return (new PPB_InputEvent_Shared(::ppapi::OBJECT_IS_IMPL, |
| 334 instance, data))->GetReference(); | 340 instance, data))->GetReference(); |
| 335 } | 341 } |
| 336 | 342 |
| 337 } // namespace ppapi | 343 } // namespace ppapi |
| 338 } // namespace webkit | 344 } // namespace webkit |
| OLD | NEW |