ppapi_messages.h revision 868fa2fe829687343ffae624259930155e16dbd8
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 3// found in the LICENSE file. 4 5// Multiply-included message header, no traditional include guard. 6#include <string> 7#include <vector> 8 9#include "base/basictypes.h" 10#include "base/files/file_path.h" 11#include "base/process.h" 12#include "base/shared_memory.h" 13#include "base/string16.h" 14#include "base/sync_socket.h" 15#include "base/values.h" 16#include "gpu/command_buffer/common/command_buffer.h" 17#include "gpu/ipc/gpu_command_buffer_traits.h" 18#include "ipc/ipc_channel_handle.h" 19#include "ipc/ipc_message_macros.h" 20#include "ipc/ipc_message_utils.h" 21#include "ipc/ipc_platform_file.h" 22#include "ppapi/c/dev/pp_video_capture_dev.h" 23#include "ppapi/c/dev/pp_video_dev.h" 24#include "ppapi/c/dev/ppb_text_input_dev.h" 25#include "ppapi/c/dev/ppb_truetype_font_dev.h" 26#include "ppapi/c/dev/ppb_url_util_dev.h" 27#include "ppapi/c/dev/ppp_printing_dev.h" 28#include "ppapi/c/pp_bool.h" 29#include "ppapi/c/pp_file_info.h" 30#include "ppapi/c/pp_instance.h" 31#include "ppapi/c/pp_module.h" 32#include "ppapi/c/pp_point.h" 33#include "ppapi/c/pp_rect.h" 34#include "ppapi/c/pp_resource.h" 35#include "ppapi/c/pp_size.h" 36#include "ppapi/c/pp_time.h" 37#include "ppapi/c/ppb_audio_config.h" 38#include "ppapi/c/ppb_image_data.h" 39#include "ppapi/c/private/pp_content_decryptor.h" 40#include "ppapi/c/private/pp_private_font_charset.h" 41#include "ppapi/c/private/ppb_flash.h" 42#include "ppapi/c/private/ppb_host_resolver_private.h" 43#include "ppapi/c/private/ppb_net_address_private.h" 44#include "ppapi/c/private/ppb_pdf.h" 45#include "ppapi/c/private/ppb_tcp_socket_private.h" 46#include "ppapi/c/private/ppb_udp_socket_private.h" 47#include "ppapi/c/private/ppp_flash_browser_operations.h" 48#include "ppapi/c/private/ppb_flash_drm.h" 49#include "ppapi/c/private/ppb_talk_private.h" 50#include "ppapi/proxy/host_resolver_private_resource.h" 51#include "ppapi/proxy/ppapi_param_traits.h" 52#include "ppapi/proxy/ppapi_proxy_export.h" 53#include "ppapi/proxy/resource_message_params.h" 54#include "ppapi/proxy/serialized_flash_menu.h" 55#include "ppapi/proxy/serialized_handle.h" 56#include "ppapi/proxy/serialized_structs.h" 57#include "ppapi/proxy/serialized_var.h" 58#include "ppapi/shared_impl/dir_contents.h" 59#include "ppapi/shared_impl/file_path.h" 60#include "ppapi/shared_impl/ppapi_nacl_channel_args.h" 61#include "ppapi/shared_impl/ppapi_preferences.h" 62#include "ppapi/shared_impl/ppb_device_ref_shared.h" 63#include "ppapi/shared_impl/ppb_input_event_shared.h" 64#include "ppapi/shared_impl/ppb_network_list_private_shared.h" 65#include "ppapi/shared_impl/ppb_view_shared.h" 66#include "ppapi/shared_impl/ppp_flash_browser_operations_shared.h" 67#include "ppapi/shared_impl/private/ppb_x509_certificate_private_shared.h" 68#include "ppapi/shared_impl/url_request_info_data.h" 69#include "ppapi/shared_impl/url_response_info_data.h" 70 71#undef IPC_MESSAGE_EXPORT 72#define IPC_MESSAGE_EXPORT PPAPI_PROXY_EXPORT 73 74#define IPC_MESSAGE_START PpapiMsgStart 75 76IPC_ENUM_TRAITS(PP_AudioSampleRate) 77IPC_ENUM_TRAITS(PP_DeviceType_Dev) 78IPC_ENUM_TRAITS(PP_DecryptorStreamType) 79IPC_ENUM_TRAITS(PP_FileSystemType) 80IPC_ENUM_TRAITS(PP_FileType) 81IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_Permission) 82IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_SettingType) 83IPC_ENUM_TRAITS(PP_FlashSetting) 84IPC_ENUM_TRAITS(PP_ImageDataFormat) 85IPC_ENUM_TRAITS(PP_InputEvent_MouseButton) 86IPC_ENUM_TRAITS(PP_InputEvent_Type) 87IPC_ENUM_TRAITS(PP_NetAddressFamily_Private) 88IPC_ENUM_TRAITS(PP_NetworkListState_Private) 89IPC_ENUM_TRAITS(PP_NetworkListType_Private) 90IPC_ENUM_TRAITS(PP_PrintOrientation_Dev) 91IPC_ENUM_TRAITS(PP_PrintOutputFormat_Dev) 92IPC_ENUM_TRAITS(PP_PrintScalingOption_Dev) 93IPC_ENUM_TRAITS(PP_PrivateFontCharset) 94IPC_ENUM_TRAITS(PP_ResourceImage) 95IPC_ENUM_TRAITS(PP_ResourceString) 96IPC_ENUM_TRAITS_MAX_VALUE(PP_TalkEvent, PP_TALKEVENT_NUM_EVENTS - 1) 97IPC_ENUM_TRAITS_MAX_VALUE(PP_TalkPermission, 98 PP_TALKPERMISSION_NUM_PERMISSIONS - 1) 99IPC_ENUM_TRAITS(PP_TextInput_Type) 100IPC_ENUM_TRAITS(PP_TrueTypeFontFamily_Dev) 101IPC_ENUM_TRAITS(PP_TrueTypeFontStyle_Dev) 102IPC_ENUM_TRAITS(PP_TrueTypeFontWeight_Dev) 103IPC_ENUM_TRAITS(PP_TrueTypeFontWidth_Dev) 104IPC_ENUM_TRAITS(PP_TrueTypeFontCharset_Dev) 105IPC_ENUM_TRAITS(PP_VideoDecodeError_Dev) 106IPC_ENUM_TRAITS(PP_VideoDecoder_Profile) 107 108IPC_STRUCT_TRAITS_BEGIN(PP_Point) 109 IPC_STRUCT_TRAITS_MEMBER(x) 110 IPC_STRUCT_TRAITS_MEMBER(y) 111IPC_STRUCT_TRAITS_END() 112 113IPC_STRUCT_TRAITS_BEGIN(PP_FloatPoint) 114 IPC_STRUCT_TRAITS_MEMBER(x) 115 IPC_STRUCT_TRAITS_MEMBER(y) 116IPC_STRUCT_TRAITS_END() 117 118IPC_STRUCT_TRAITS_BEGIN(PP_Size) 119 IPC_STRUCT_TRAITS_MEMBER(height) 120 IPC_STRUCT_TRAITS_MEMBER(width) 121IPC_STRUCT_TRAITS_END() 122 123IPC_STRUCT_TRAITS_BEGIN(PP_Rect) 124 IPC_STRUCT_TRAITS_MEMBER(point) 125 IPC_STRUCT_TRAITS_MEMBER(size) 126IPC_STRUCT_TRAITS_END() 127 128IPC_STRUCT_TRAITS_BEGIN(PP_ImageDataDesc) 129 IPC_STRUCT_TRAITS_MEMBER(format) 130 IPC_STRUCT_TRAITS_MEMBER(size) 131 IPC_STRUCT_TRAITS_MEMBER(stride) 132IPC_STRUCT_TRAITS_END() 133 134IPC_STRUCT_TRAITS_BEGIN(PP_PictureBuffer_Dev) 135 IPC_STRUCT_TRAITS_MEMBER(id) 136 IPC_STRUCT_TRAITS_MEMBER(size) 137 IPC_STRUCT_TRAITS_MEMBER(texture_id) 138IPC_STRUCT_TRAITS_END() 139 140IPC_STRUCT_TRAITS_BEGIN(PP_Picture_Dev) 141 IPC_STRUCT_TRAITS_MEMBER(picture_buffer_id) 142 IPC_STRUCT_TRAITS_MEMBER(bitstream_buffer_id) 143IPC_STRUCT_TRAITS_END() 144 145IPC_STRUCT_TRAITS_BEGIN(PP_PrintPageNumberRange_Dev) 146 IPC_STRUCT_TRAITS_MEMBER(first_page_number) 147 IPC_STRUCT_TRAITS_MEMBER(last_page_number) 148IPC_STRUCT_TRAITS_END() 149 150IPC_STRUCT_TRAITS_BEGIN(PP_VideoCaptureDeviceInfo_Dev) 151 IPC_STRUCT_TRAITS_MEMBER(width) 152 IPC_STRUCT_TRAITS_MEMBER(height) 153 IPC_STRUCT_TRAITS_MEMBER(frames_per_second) 154IPC_STRUCT_TRAITS_END() 155 156IPC_STRUCT_TRAITS_BEGIN(PP_HostResolver_Private_Hint) 157 IPC_STRUCT_TRAITS_MEMBER(family) 158 IPC_STRUCT_TRAITS_MEMBER(flags) 159IPC_STRUCT_TRAITS_END() 160 161IPC_STRUCT_TRAITS_BEGIN(PP_PrintSettings_Dev) 162 IPC_STRUCT_TRAITS_MEMBER(printable_area) 163 IPC_STRUCT_TRAITS_MEMBER(content_area) 164 IPC_STRUCT_TRAITS_MEMBER(paper_size) 165 IPC_STRUCT_TRAITS_MEMBER(dpi) 166 IPC_STRUCT_TRAITS_MEMBER(orientation) 167 IPC_STRUCT_TRAITS_MEMBER(print_scaling_option) 168 IPC_STRUCT_TRAITS_MEMBER(grayscale) 169 IPC_STRUCT_TRAITS_MEMBER(format) 170IPC_STRUCT_TRAITS_END() 171 172IPC_STRUCT_TRAITS_BEGIN(PP_URLComponent_Dev) 173 IPC_STRUCT_TRAITS_MEMBER(begin) 174 IPC_STRUCT_TRAITS_MEMBER(len) 175IPC_STRUCT_TRAITS_END() 176 177IPC_STRUCT_TRAITS_BEGIN(PP_URLComponents_Dev) 178 IPC_STRUCT_TRAITS_MEMBER(scheme) 179 IPC_STRUCT_TRAITS_MEMBER(username) 180 IPC_STRUCT_TRAITS_MEMBER(password) 181 IPC_STRUCT_TRAITS_MEMBER(host) 182 IPC_STRUCT_TRAITS_MEMBER(port) 183 IPC_STRUCT_TRAITS_MEMBER(path) 184 IPC_STRUCT_TRAITS_MEMBER(query) 185 IPC_STRUCT_TRAITS_MEMBER(ref) 186IPC_STRUCT_TRAITS_END() 187 188IPC_STRUCT_TRAITS_BEGIN(ppapi::DeviceRefData) 189 IPC_STRUCT_TRAITS_MEMBER(type) 190 IPC_STRUCT_TRAITS_MEMBER(name) 191 IPC_STRUCT_TRAITS_MEMBER(id) 192IPC_STRUCT_TRAITS_END() 193 194IPC_STRUCT_TRAITS_BEGIN(ppapi::DirEntry) 195 IPC_STRUCT_TRAITS_MEMBER(name) 196 IPC_STRUCT_TRAITS_MEMBER(is_dir) 197IPC_STRUCT_TRAITS_END() 198 199IPC_STRUCT_TRAITS_BEGIN(ppapi::FlashSiteSetting) 200 IPC_STRUCT_TRAITS_MEMBER(site) 201 IPC_STRUCT_TRAITS_MEMBER(permission) 202IPC_STRUCT_TRAITS_END() 203 204IPC_STRUCT_TRAITS_BEGIN(ppapi::ViewData) 205 IPC_STRUCT_TRAITS_MEMBER(rect) 206 IPC_STRUCT_TRAITS_MEMBER(is_fullscreen) 207 IPC_STRUCT_TRAITS_MEMBER(is_page_visible) 208 IPC_STRUCT_TRAITS_MEMBER(clip_rect) 209 IPC_STRUCT_TRAITS_MEMBER(device_scale) 210 IPC_STRUCT_TRAITS_MEMBER(css_scale) 211IPC_STRUCT_TRAITS_END() 212 213IPC_STRUCT_TRAITS_BEGIN(PP_TouchPoint) 214 IPC_STRUCT_TRAITS_MEMBER(id) 215 IPC_STRUCT_TRAITS_MEMBER(position) 216 IPC_STRUCT_TRAITS_MEMBER(radius) 217 IPC_STRUCT_TRAITS_MEMBER(rotation_angle) 218 IPC_STRUCT_TRAITS_MEMBER(pressure) 219IPC_STRUCT_TRAITS_END() 220 221IPC_STRUCT_TRAITS_BEGIN(ppapi::Preferences) 222 IPC_STRUCT_TRAITS_MEMBER(standard_font_family_map) 223 IPC_STRUCT_TRAITS_MEMBER(fixed_font_family_map) 224 IPC_STRUCT_TRAITS_MEMBER(serif_font_family_map) 225 IPC_STRUCT_TRAITS_MEMBER(sans_serif_font_family_map) 226 IPC_STRUCT_TRAITS_MEMBER(default_font_size) 227 IPC_STRUCT_TRAITS_MEMBER(default_fixed_font_size) 228 IPC_STRUCT_TRAITS_MEMBER(number_of_cpu_cores) 229 IPC_STRUCT_TRAITS_MEMBER(is_3d_supported) 230 IPC_STRUCT_TRAITS_MEMBER(is_stage3d_supported) 231 IPC_STRUCT_TRAITS_MEMBER(is_stage3d_baseline_supported) 232IPC_STRUCT_TRAITS_END() 233 234IPC_STRUCT_TRAITS_BEGIN(ppapi::InputEventData) 235 IPC_STRUCT_TRAITS_MEMBER(is_filtered) 236 IPC_STRUCT_TRAITS_MEMBER(event_type) 237 IPC_STRUCT_TRAITS_MEMBER(event_time_stamp) 238 IPC_STRUCT_TRAITS_MEMBER(event_modifiers) 239 IPC_STRUCT_TRAITS_MEMBER(mouse_button) 240 IPC_STRUCT_TRAITS_MEMBER(mouse_position) 241 IPC_STRUCT_TRAITS_MEMBER(mouse_click_count) 242 IPC_STRUCT_TRAITS_MEMBER(mouse_movement) 243 IPC_STRUCT_TRAITS_MEMBER(wheel_delta) 244 IPC_STRUCT_TRAITS_MEMBER(wheel_ticks) 245 IPC_STRUCT_TRAITS_MEMBER(wheel_scroll_by_page) 246 IPC_STRUCT_TRAITS_MEMBER(key_code) 247 IPC_STRUCT_TRAITS_MEMBER(usb_key_code) 248 IPC_STRUCT_TRAITS_MEMBER(character_text) 249 IPC_STRUCT_TRAITS_MEMBER(composition_segment_offsets) 250 IPC_STRUCT_TRAITS_MEMBER(composition_target_segment) 251 IPC_STRUCT_TRAITS_MEMBER(composition_selection_start) 252 IPC_STRUCT_TRAITS_MEMBER(composition_selection_end) 253 IPC_STRUCT_TRAITS_MEMBER(touches) 254 IPC_STRUCT_TRAITS_MEMBER(changed_touches) 255 IPC_STRUCT_TRAITS_MEMBER(target_touches) 256IPC_STRUCT_TRAITS_END() 257 258IPC_STRUCT_TRAITS_BEGIN(ppapi::HostPortPair) 259 IPC_STRUCT_TRAITS_MEMBER(host) 260 IPC_STRUCT_TRAITS_MEMBER(port) 261IPC_STRUCT_TRAITS_END() 262 263IPC_STRUCT_TRAITS_BEGIN(ppapi::URLRequestInfoData) 264 IPC_STRUCT_TRAITS_MEMBER(url) 265 IPC_STRUCT_TRAITS_MEMBER(method) 266 IPC_STRUCT_TRAITS_MEMBER(headers) 267 IPC_STRUCT_TRAITS_MEMBER(stream_to_file) 268 IPC_STRUCT_TRAITS_MEMBER(follow_redirects) 269 IPC_STRUCT_TRAITS_MEMBER(record_download_progress) 270 IPC_STRUCT_TRAITS_MEMBER(record_upload_progress) 271 IPC_STRUCT_TRAITS_MEMBER(has_custom_referrer_url) 272 IPC_STRUCT_TRAITS_MEMBER(custom_referrer_url) 273 IPC_STRUCT_TRAITS_MEMBER(allow_cross_origin_requests) 274 IPC_STRUCT_TRAITS_MEMBER(allow_credentials) 275 IPC_STRUCT_TRAITS_MEMBER(has_custom_content_transfer_encoding) 276 IPC_STRUCT_TRAITS_MEMBER(custom_content_transfer_encoding) 277 IPC_STRUCT_TRAITS_MEMBER(prefetch_buffer_upper_threshold) 278 IPC_STRUCT_TRAITS_MEMBER(prefetch_buffer_lower_threshold) 279 IPC_STRUCT_TRAITS_MEMBER(has_custom_user_agent) 280 IPC_STRUCT_TRAITS_MEMBER(custom_user_agent) 281 IPC_STRUCT_TRAITS_MEMBER(body) 282IPC_STRUCT_TRAITS_END() 283 284IPC_STRUCT_TRAITS_BEGIN(ppapi::URLRequestInfoData::BodyItem) 285 IPC_STRUCT_TRAITS_MEMBER(is_file) 286 IPC_STRUCT_TRAITS_MEMBER(data) 287 // Note: we don't serialize file_ref. 288 IPC_STRUCT_TRAITS_MEMBER(file_ref_host_resource) 289 IPC_STRUCT_TRAITS_MEMBER(start_offset) 290 IPC_STRUCT_TRAITS_MEMBER(number_of_bytes) 291 IPC_STRUCT_TRAITS_MEMBER(expected_last_modified_time) 292IPC_STRUCT_TRAITS_END() 293 294IPC_STRUCT_TRAITS_BEGIN(ppapi::URLResponseInfoData) 295 IPC_STRUCT_TRAITS_MEMBER(url) 296 IPC_STRUCT_TRAITS_MEMBER(headers) 297 IPC_STRUCT_TRAITS_MEMBER(status_code) 298 IPC_STRUCT_TRAITS_MEMBER(status_text) 299 IPC_STRUCT_TRAITS_MEMBER(redirect_url) 300 IPC_STRUCT_TRAITS_MEMBER(body_as_file_ref) 301IPC_STRUCT_TRAITS_END() 302 303IPC_STRUCT_TRAITS_BEGIN(ppapi::NetworkInfo) 304 IPC_STRUCT_TRAITS_MEMBER(name) 305 IPC_STRUCT_TRAITS_MEMBER(type) 306 IPC_STRUCT_TRAITS_MEMBER(state) 307 IPC_STRUCT_TRAITS_MEMBER(addresses) 308 IPC_STRUCT_TRAITS_MEMBER(display_name) 309 IPC_STRUCT_TRAITS_MEMBER(mtu) 310IPC_STRUCT_TRAITS_END() 311 312// Only whitelisted switches passed through NaClChannelArgs. 313// The list of switches can be found in: 314// chrome/browser/nacl_host/nacl_process_host.cc 315IPC_STRUCT_TRAITS_BEGIN(ppapi::PpapiNaClChannelArgs) 316 IPC_STRUCT_TRAITS_MEMBER(off_the_record) 317 IPC_STRUCT_TRAITS_MEMBER(permissions) 318 IPC_STRUCT_TRAITS_MEMBER(switch_names) 319 IPC_STRUCT_TRAITS_MEMBER(switch_values) 320IPC_STRUCT_TRAITS_END() 321 322#if !defined(OS_NACL) && !defined(NACL_WIN64) 323 324IPC_STRUCT_TRAITS_BEGIN(ppapi::proxy::PPPDecryptor_Buffer) 325 IPC_STRUCT_TRAITS_MEMBER(resource) 326 IPC_STRUCT_TRAITS_MEMBER(handle) 327 IPC_STRUCT_TRAITS_MEMBER(size) 328IPC_STRUCT_TRAITS_END() 329 330#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 331 332// These are from the browser to the plugin. 333// Loads the given plugin. 334IPC_MESSAGE_CONTROL2(PpapiMsg_LoadPlugin, 335 base::FilePath /* path */, 336 ppapi::PpapiPermissions /* permissions */) 337 338// Creates a channel to talk to a renderer. The plugin will respond with 339// PpapiHostMsg_ChannelCreated. 340IPC_MESSAGE_CONTROL3(PpapiMsg_CreateChannel, 341 base::ProcessId /* renderer_pid */, 342 int /* renderer_child_id */, 343 bool /* incognito */) 344 345// Creates a channel to talk to a renderer. This message is only used by the 346// NaCl IPC proxy. It is intercepted by NaClIPCAdapter, which creates the 347// actual channel and rewrites the message for the untrusted side. 348IPC_MESSAGE_CONTROL3(PpapiMsg_CreateNaClChannel, 349 int /* renderer_id */, 350 ppapi::PpapiNaClChannelArgs /* args */, 351 ppapi::proxy::SerializedHandle /* channel_handle */) 352 353// Instructs the plugin process to crash. 354IPC_MESSAGE_CONTROL0(PpapiMsg_Crash) 355 356// Instructs the plugin process to hang. 357IPC_MESSAGE_CONTROL0(PpapiMsg_Hang) 358 359// Each plugin may be referenced by multiple renderers. We need the instance 360// IDs to be unique within a plugin, despite coming from different renderers, 361// and unique within a renderer, despite going to different plugins. This means 362// that neither the renderer nor the plugin can generate instance IDs without 363// consulting the other. 364// 365// We resolve this by having the renderer generate a unique instance ID inside 366// its process. It then asks the plugin to reserve that ID by sending this sync 367// message. If the plugin has not yet seen this ID, it will remember it as used 368// (to prevent a race condition if another renderer tries to then use the same 369// instance), and set usable as true. 370// 371// If the plugin has already seen the instance ID, it will set usable as false 372// and the renderer must retry a new instance ID. 373IPC_SYNC_MESSAGE_CONTROL1_1(PpapiMsg_ReserveInstanceId, 374 PP_Instance /* instance */, 375 bool /* usable */) 376 377// Passes the WebKit preferences to the plugin. 378IPC_MESSAGE_CONTROL1(PpapiMsg_SetPreferences, 379 ppapi::Preferences) 380 381// Sent in both directions to see if the other side supports the given 382// interface. 383IPC_SYNC_MESSAGE_CONTROL1_1(PpapiMsg_SupportsInterface, 384 std::string /* interface_name */, 385 bool /* result */) 386 387#if !defined(OS_NACL) && !defined(NACL_WIN64) 388// Network state notification from the browser for implementing 389// PPP_NetworkState_Dev. 390IPC_MESSAGE_CONTROL1(PpapiMsg_SetNetworkState, 391 bool /* online */) 392 393// Requests a list of sites that have data stored from the plugin. The plugin 394// process will respond with PpapiHostMsg_GetSitesWithDataResult. This is used 395// for Flash. 396IPC_MESSAGE_CONTROL2(PpapiMsg_GetSitesWithData, 397 uint32 /* request_id */, 398 base::FilePath /* plugin_data_path */) 399IPC_MESSAGE_CONTROL2(PpapiHostMsg_GetSitesWithDataResult, 400 uint32 /* request_id */, 401 std::vector<std::string> /* sites */) 402 403// Instructs the plugin to clear data for the given site & time. The plugin 404// process will respond with PpapiHostMsg_ClearSiteDataResult. This is used 405// for Flash. 406IPC_MESSAGE_CONTROL5(PpapiMsg_ClearSiteData, 407 uint32 /* request_id */, 408 base::FilePath /* plugin_data_path */, 409 std::string /* site */, 410 uint64 /* flags */, 411 uint64 /* max_age */) 412IPC_MESSAGE_CONTROL2(PpapiHostMsg_ClearSiteDataResult, 413 uint32 /* request_id */, 414 bool /* success */) 415 416IPC_MESSAGE_CONTROL2(PpapiMsg_DeauthorizeContentLicenses, 417 uint32 /* request_id */, 418 base::FilePath /* plugin_data_path */) 419IPC_MESSAGE_CONTROL2(PpapiHostMsg_DeauthorizeContentLicensesResult, 420 uint32 /* request_id */, 421 bool /* success */) 422 423IPC_MESSAGE_CONTROL3(PpapiMsg_GetPermissionSettings, 424 uint32 /* request_id */, 425 base::FilePath /* plugin_data_path */, 426 PP_Flash_BrowserOperations_SettingType /* setting_type */) 427IPC_MESSAGE_CONTROL4( 428 PpapiHostMsg_GetPermissionSettingsResult, 429 uint32 /* request_id */, 430 bool /* success */, 431 PP_Flash_BrowserOperations_Permission /* default_permission */, 432 ppapi::FlashSiteSettings /* sites */) 433 434IPC_MESSAGE_CONTROL5(PpapiMsg_SetDefaultPermission, 435 uint32 /* request_id */, 436 base::FilePath /* plugin_data_path */, 437 PP_Flash_BrowserOperations_SettingType /* setting_type */, 438 PP_Flash_BrowserOperations_Permission /* permission */, 439 bool /* clear_site_specific */) 440IPC_MESSAGE_CONTROL2(PpapiHostMsg_SetDefaultPermissionResult, 441 uint32 /* request_id */, 442 bool /* success */) 443 444IPC_MESSAGE_CONTROL4(PpapiMsg_SetSitePermission, 445 uint32 /* request_id */, 446 base::FilePath /* plugin_data_path */, 447 PP_Flash_BrowserOperations_SettingType /* setting_type */, 448 ppapi::FlashSiteSettings /* sites */) 449IPC_MESSAGE_CONTROL2(PpapiHostMsg_SetSitePermissionResult, 450 uint32 /* request_id */, 451 bool /* success */) 452 453// Broker Process. 454IPC_SYNC_MESSAGE_CONTROL2_1(PpapiMsg_ConnectToPlugin, 455 PP_Instance /* instance */, 456 IPC::PlatformFileForTransit /* handle */, 457 int32_t /* result */) 458#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 459 460// PPB_Audio. 461 462// Notifies the result of the audio stream create call. This is called in 463// both error cases and in the normal success case. These cases are 464// differentiated by the result code, which is one of the standard PPAPI 465// result codes. 466// 467// The handler of this message should always close all of the handles passed 468// in, since some could be valid even in the error case. 469IPC_MESSAGE_ROUTED4(PpapiMsg_PPBAudio_NotifyAudioStreamCreated, 470 ppapi::HostResource /* audio_id */, 471 int32_t /* result_code (will be != PP_OK on failure) */, 472 ppapi::proxy::SerializedHandle /* socket_handle */, 473 ppapi::proxy::SerializedHandle /* handle */) 474 475// PPB_FileRef. 476IPC_MESSAGE_ROUTED3( 477 PpapiMsg_PPBFileRef_CallbackComplete, 478 ppapi::HostResource /* resource */, 479 uint32_t /* callback_id */, 480 int32_t /* result */) 481 482IPC_MESSAGE_ROUTED4( 483 PpapiMsg_PPBFileRef_QueryCallbackComplete, 484 ppapi::HostResource /* resource */, 485 PP_FileInfo /* file_info */, 486 uint32_t /* callback_id */, 487 int32_t /* result */) 488 489IPC_MESSAGE_ROUTED5( 490 PpapiMsg_PPBFileRef_ReadDirectoryEntriesCallbackComplete, 491 ppapi::HostResource /* resource */, 492 std::vector<ppapi::PPB_FileRef_CreateInfo> /* files */, 493 std::vector<PP_FileType> /* file_types */, 494 uint32_t /* callback_id */, 495 int32_t /* result */) 496 497// PPB_FileSystem. 498IPC_MESSAGE_ROUTED2( 499 PpapiMsg_PPBFileSystem_OpenComplete, 500 ppapi::HostResource /* filesystem */, 501 int32_t /* result */) 502 503// PPB_Graphics3D. 504IPC_MESSAGE_ROUTED2(PpapiMsg_PPBGraphics3D_SwapBuffersACK, 505 ppapi::HostResource /* graphics_3d */, 506 int32_t /* pp_error */) 507 508// PPB_ImageData. 509IPC_MESSAGE_ROUTED1(PpapiMsg_PPBImageData_NotifyUnusedImageData, 510 ppapi::HostResource /* old_image_data */) 511 512// PPB_Instance. 513IPC_MESSAGE_ROUTED2(PpapiMsg_PPBInstance_MouseLockComplete, 514 PP_Instance /* instance */, 515 int32_t /* result */) 516 517// PPP_Class. 518IPC_SYNC_MESSAGE_ROUTED3_2(PpapiMsg_PPPClass_HasProperty, 519 int64 /* ppp_class */, 520 int64 /* object */, 521 ppapi::proxy::SerializedVar /* property */, 522 ppapi::proxy::SerializedVar /* out_exception */, 523 bool /* result */) 524IPC_SYNC_MESSAGE_ROUTED3_2(PpapiMsg_PPPClass_HasMethod, 525 int64 /* ppp_class */, 526 int64 /* object */, 527 ppapi::proxy::SerializedVar /* method */, 528 ppapi::proxy::SerializedVar /* out_exception */, 529 bool /* result */) 530IPC_SYNC_MESSAGE_ROUTED3_2(PpapiMsg_PPPClass_GetProperty, 531 int64 /* ppp_class */, 532 int64 /* object */, 533 ppapi::proxy::SerializedVar /* property */, 534 ppapi::proxy::SerializedVar /* out_exception */, 535 ppapi::proxy::SerializedVar /* result */) 536IPC_SYNC_MESSAGE_ROUTED2_2(PpapiMsg_PPPClass_EnumerateProperties, 537 int64 /* ppp_class */, 538 int64 /* object */, 539 std::vector<ppapi::proxy::SerializedVar> /* props */, 540 ppapi::proxy::SerializedVar /* out_exception */) 541IPC_SYNC_MESSAGE_ROUTED4_1(PpapiMsg_PPPClass_SetProperty, 542 int64 /* ppp_class */, 543 int64 /* object */, 544 ppapi::proxy::SerializedVar /* name */, 545 ppapi::proxy::SerializedVar /* value */, 546 ppapi::proxy::SerializedVar /* out_exception */) 547IPC_SYNC_MESSAGE_ROUTED3_1(PpapiMsg_PPPClass_RemoveProperty, 548 int64 /* ppp_class */, 549 int64 /* object */, 550 ppapi::proxy::SerializedVar /* property */, 551 ppapi::proxy::SerializedVar /* out_exception */) 552IPC_SYNC_MESSAGE_ROUTED4_2(PpapiMsg_PPPClass_Call, 553 int64 /* ppp_class */, 554 int64 /* object */, 555 ppapi::proxy::SerializedVar /* method_name */, 556 std::vector<ppapi::proxy::SerializedVar> /* args */, 557 ppapi::proxy::SerializedVar /* out_exception */, 558 ppapi::proxy::SerializedVar /* result */) 559IPC_SYNC_MESSAGE_ROUTED3_2(PpapiMsg_PPPClass_Construct, 560 int64 /* ppp_class */, 561 int64 /* object */, 562 std::vector<ppapi::proxy::SerializedVar> /* args */, 563 ppapi::proxy::SerializedVar /* out_exception */, 564 ppapi::proxy::SerializedVar /* result */) 565IPC_MESSAGE_ROUTED2(PpapiMsg_PPPClass_Deallocate, 566 int64 /* ppp_class */, 567 int64 /* object */) 568 569// PPP_Graphics3D_Dev. 570IPC_MESSAGE_ROUTED1(PpapiMsg_PPPGraphics3D_ContextLost, 571 PP_Instance /* instance */) 572 573// PPP_InputEvent. 574IPC_MESSAGE_ROUTED2(PpapiMsg_PPPInputEvent_HandleInputEvent, 575 PP_Instance /* instance */, 576 ppapi::InputEventData /* data */) 577IPC_SYNC_MESSAGE_ROUTED2_1(PpapiMsg_PPPInputEvent_HandleFilteredInputEvent, 578 PP_Instance /* instance */, 579 ppapi::InputEventData /* data */, 580 PP_Bool /* result */) 581 582// PPP_Instance. 583IPC_SYNC_MESSAGE_ROUTED3_1(PpapiMsg_PPPInstance_DidCreate, 584 PP_Instance /* instance */, 585 std::vector<std::string> /* argn */, 586 std::vector<std::string> /* argv */, 587 PP_Bool /* result */) 588IPC_SYNC_MESSAGE_ROUTED1_0(PpapiMsg_PPPInstance_DidDestroy, 589 PP_Instance /* instance */) 590IPC_MESSAGE_ROUTED3(PpapiMsg_PPPInstance_DidChangeView, 591 PP_Instance /* instance */, 592 ppapi::ViewData /* new_data */, 593 PP_Bool /* flash_fullscreen */) 594IPC_MESSAGE_ROUTED2(PpapiMsg_PPPInstance_DidChangeFocus, 595 PP_Instance /* instance */, 596 PP_Bool /* has_focus */) 597IPC_MESSAGE_ROUTED3(PpapiMsg_PPPInstance_HandleDocumentLoad, 598 PP_Instance /* instance */, 599 int /* pending_loader_host_id */, 600 ppapi::URLResponseInfoData /* response */) 601 602// PPP_Messaging. 603IPC_MESSAGE_ROUTED2(PpapiMsg_PPPMessaging_HandleMessage, 604 PP_Instance /* instance */, 605 ppapi::proxy::SerializedVar /* message */) 606 607// PPP_MouseLock. 608IPC_MESSAGE_ROUTED1(PpapiMsg_PPPMouseLock_MouseLockLost, 609 PP_Instance /* instance */) 610 611// PPB_NetworkMonitor_Private. 612IPC_MESSAGE_ROUTED2(PpapiMsg_PPBNetworkMonitor_NetworkList, 613 uint32 /* plugin_dispatcher_id */, 614 ppapi::NetworkList /* network_list */) 615 616// PPP_Printing 617IPC_SYNC_MESSAGE_ROUTED1_1(PpapiMsg_PPPPrinting_QuerySupportedFormats, 618 PP_Instance /* instance */, 619 uint32_t /* result */) 620IPC_SYNC_MESSAGE_ROUTED2_1(PpapiMsg_PPPPrinting_Begin, 621 PP_Instance /* instance */, 622 std::string /* settings_string */, 623 int32_t /* result */) 624IPC_SYNC_MESSAGE_ROUTED2_1(PpapiMsg_PPPPrinting_PrintPages, 625 PP_Instance /* instance */, 626 std::vector<PP_PrintPageNumberRange_Dev> /* pages */, 627 ppapi::HostResource /* result */) 628IPC_MESSAGE_ROUTED1(PpapiMsg_PPPPrinting_End, 629 PP_Instance /* instance */) 630IPC_SYNC_MESSAGE_ROUTED1_1(PpapiMsg_PPPPrinting_IsScalingDisabled, 631 PP_Instance /* instance */, 632 bool /* result */) 633 634// PPP_TextInput. 635IPC_MESSAGE_ROUTED2(PpapiMsg_PPPTextInput_RequestSurroundingText, 636 PP_Instance /* instance */, 637 uint32_t /* desired_number_of_characters */) 638 639#if !defined(OS_NACL) && !defined(NACL_WIN64) 640// PPB_Broker. 641IPC_MESSAGE_ROUTED3( 642 PpapiMsg_PPBBroker_ConnectComplete, 643 ppapi::HostResource /* broker */, 644 IPC::PlatformFileForTransit /* handle */, 645 int32_t /* result */) 646 647// PPP_ContentDecryptor_Dev 648IPC_MESSAGE_ROUTED4(PpapiMsg_PPPContentDecryptor_GenerateKeyRequest, 649 PP_Instance /* instance */, 650 ppapi::proxy::SerializedVar /* key_system, String */, 651 ppapi::proxy::SerializedVar /* type, String */, 652 ppapi::proxy::SerializedVar /* init_data, ArrayBuffer */) 653IPC_MESSAGE_ROUTED4(PpapiMsg_PPPContentDecryptor_AddKey, 654 PP_Instance /* instance */, 655 ppapi::proxy::SerializedVar /* session_id, String */, 656 ppapi::proxy::SerializedVar /* key, ArrayBuffer */, 657 ppapi::proxy::SerializedVar /* init_data, ArrayBuffer */) 658IPC_MESSAGE_ROUTED2(PpapiMsg_PPPContentDecryptor_CancelKeyRequest, 659 PP_Instance /* instance */, 660 ppapi::proxy::SerializedVar /* session_id, String */) 661IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_Decrypt, 662 PP_Instance /* instance */, 663 ppapi::proxy::PPPDecryptor_Buffer /* buffer */, 664 std::string /* serialized_block_info */) 665IPC_MESSAGE_ROUTED3( 666 PpapiMsg_PPPContentDecryptor_InitializeAudioDecoder, 667 PP_Instance /* instance */, 668 std::string /* serialized_decoder_config */, 669 ppapi::proxy::PPPDecryptor_Buffer /* extra_data_buffer */) 670IPC_MESSAGE_ROUTED3( 671 PpapiMsg_PPPContentDecryptor_InitializeVideoDecoder, 672 PP_Instance /* instance */, 673 std::string /* serialized_decoder_config */, 674 ppapi::proxy::PPPDecryptor_Buffer /* extra_data_buffer. */) 675IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_DeinitializeDecoder, 676 PP_Instance /* instance */, 677 PP_DecryptorStreamType /* decoder_type */, 678 uint32_t /* request_id */) 679IPC_MESSAGE_ROUTED3(PpapiMsg_PPPContentDecryptor_ResetDecoder, 680 PP_Instance /* instance */, 681 PP_DecryptorStreamType /* decoder_type */, 682 uint32_t /* request_id */) 683IPC_MESSAGE_ROUTED4(PpapiMsg_PPPContentDecryptor_DecryptAndDecode, 684 PP_Instance /* instance */, 685 PP_DecryptorStreamType /* decoder_type */, 686 ppapi::proxy::PPPDecryptor_Buffer /* buffer */, 687 std::string /* serialized_block_info */) 688#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 689 690// PPB_TCPSocket_Private. 691IPC_MESSAGE_ROUTED5(PpapiMsg_PPBTCPSocket_ConnectACK, 692 uint32 /* plugin_dispatcher_id */, 693 uint32 /* socket_id */, 694 bool /* succeeded */, 695 PP_NetAddress_Private /* local_addr */, 696 PP_NetAddress_Private /* remote_addr */) 697IPC_MESSAGE_ROUTED4(PpapiMsg_PPBTCPSocket_SSLHandshakeACK, 698 uint32 /* plugin_dispatcher_id */, 699 uint32 /* socket_id */, 700 bool /* succeeded */, 701 ppapi::PPB_X509Certificate_Fields /* certificate_fields */) 702IPC_MESSAGE_ROUTED4(PpapiMsg_PPBTCPSocket_ReadACK, 703 uint32 /* plugin_dispatcher_id */, 704 uint32 /* socket_id */, 705 bool /* succeeded */, 706 std::string /* data */) 707IPC_MESSAGE_ROUTED4(PpapiMsg_PPBTCPSocket_WriteACK, 708 uint32 /* plugin_dispatcher_id */, 709 uint32 /* socket_id */, 710 bool /* succeeded */, 711 int32_t /* bytes_written */) 712IPC_MESSAGE_ROUTED3(PpapiMsg_PPBTCPSocket_SetBoolOptionACK, 713 uint32 /* plugin_dispatcher_id */, 714 uint32 /* socket_id */, 715 bool /* succeeded */) 716 717// PPB_TCPServerSocket_Private. 718 719// |socket_resource| should not be used as Resource in browser. The 720// only purpose of this argument is to be echoed back. 721// |status| == PP_ERROR_NOSPACE means that the socket table is full 722// and new socket can't be initialized. 723// |status| == PP_ERROR_FAILED means that socket is correctly 724// initialized (if needed) but Listen call is failed. 725// |status| == PP_OK means that socket is correctly initialized (if 726// needed) and Listen call succeeds. 727IPC_MESSAGE_ROUTED5(PpapiMsg_PPBTCPServerSocket_ListenACK, 728 uint32 /* plugin_dispatcher_id */, 729 PP_Resource /* socket_resource */, 730 uint32 /* socket_id */, 731 PP_NetAddress_Private /* local_addr */, 732 int32_t /* status */) 733IPC_MESSAGE_ROUTED5(PpapiMsg_PPBTCPServerSocket_AcceptACK, 734 uint32 /* plugin_dispatcher_id */, 735 uint32 /* server_socket_id */, 736 uint32 /* accepted_socket_id */, 737 PP_NetAddress_Private /* local_addr */, 738 PP_NetAddress_Private /* remote_addr */) 739 740#if !defined(OS_NACL) && !defined(NACL_WIN64) 741// PPP_Instance_Private. 742IPC_SYNC_MESSAGE_ROUTED1_1(PpapiMsg_PPPInstancePrivate_GetInstanceObject, 743 PP_Instance /* instance */, 744 ppapi::proxy::SerializedVar /* result */) 745 746// PPB_VideoDecoder_Dev. 747// (Messages from renderer to plugin to notify it to run callbacks.) 748IPC_MESSAGE_ROUTED3(PpapiMsg_PPBVideoDecoder_EndOfBitstreamACK, 749 ppapi::HostResource /* video_decoder */, 750 int32_t /* bitstream buffer id */, 751 int32_t /* PP_CompletionCallback result */) 752IPC_MESSAGE_ROUTED2(PpapiMsg_PPBVideoDecoder_FlushACK, 753 ppapi::HostResource /* video_decoder */, 754 int32_t /* PP_CompletionCallback result */) 755IPC_MESSAGE_ROUTED2(PpapiMsg_PPBVideoDecoder_ResetACK, 756 ppapi::HostResource /* video_decoder */, 757 int32_t /* PP_CompletionCallback result */) 758 759// PPP_VideoDecoder_Dev. 760IPC_MESSAGE_ROUTED4(PpapiMsg_PPPVideoDecoder_ProvidePictureBuffers, 761 ppapi::HostResource /* video_decoder */, 762 uint32_t /* requested number of buffers */, 763 PP_Size /* dimensions of buffers */, 764 uint32_t /* texture_target */) 765IPC_MESSAGE_ROUTED2(PpapiMsg_PPPVideoDecoder_DismissPictureBuffer, 766 ppapi::HostResource /* video_decoder */, 767 int32_t /* picture buffer id */) 768IPC_MESSAGE_ROUTED2(PpapiMsg_PPPVideoDecoder_PictureReady, 769 ppapi::HostResource /* video_decoder */, 770 PP_Picture_Dev /* output picture */) 771IPC_MESSAGE_ROUTED2(PpapiMsg_PPPVideoDecoder_NotifyError, 772 ppapi::HostResource /* video_decoder */, 773 PP_VideoDecodeError_Dev /* error */) 774#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 775 776// ----------------------------------------------------------------------------- 777// These are from the plugin to the renderer. 778 779// Reply to PpapiMsg_CreateChannel. The handle will be NULL if the channel 780// could not be established. This could be because the IPC could not be created 781// for some weird reason, but more likely that the plugin failed to load or 782// initialize properly. 783IPC_MESSAGE_CONTROL1(PpapiHostMsg_ChannelCreated, 784 IPC::ChannelHandle /* handle */) 785 786// Logs the given message to the console of all instances. 787IPC_MESSAGE_CONTROL4(PpapiHostMsg_LogWithSource, 788 PP_Instance /* instance */, 789 int /* log_level */, 790 std::string /* source */, 791 std::string /* value */) 792 793// PPB_Audio. 794IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBAudio_Create, 795 PP_Instance /* instance_id */, 796 int32_t /* sample_rate */, 797 uint32_t /* sample_frame_count */, 798 ppapi::HostResource /* result */) 799IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBAudio_StartOrStop, 800 ppapi::HostResource /* audio_id */, 801 bool /* play */) 802 803// PPB_Core. 804IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBCore_AddRefResource, 805 ppapi::HostResource) 806IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBCore_ReleaseResource, 807 ppapi::HostResource) 808 809// PPB_FileRef. 810IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBFileRef_Create, 811 PP_Instance /* instance */, 812 PP_Resource /* file_system */, 813 std::string /* path */, 814 ppapi::PPB_FileRef_CreateInfo /* result */) 815IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBFileRef_GetParent, 816 ppapi::HostResource /* file_ref */, 817 ppapi::PPB_FileRef_CreateInfo /* result */) 818IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBFileRef_MakeDirectory, 819 ppapi::HostResource /* file_ref */, 820 PP_Bool /* make_ancestors */, 821 uint32_t /* callback_id */) 822IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBFileRef_Touch, 823 ppapi::HostResource /* file_ref */, 824 PP_Time /* last_access */, 825 PP_Time /* last_modified */, 826 uint32_t /* callback_id */) 827IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBFileRef_Delete, 828 ppapi::HostResource /* file_ref */, 829 uint32_t /* callback_id */) 830IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBFileRef_Rename, 831 ppapi::HostResource /* file_ref */, 832 ppapi::HostResource /* new_file_ref */, 833 uint32_t /* callback_id */) 834IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBFileRef_Query, 835 ppapi::HostResource /* file_ref */, 836 uint32_t /* callback_id */) 837IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBFileRef_GetAbsolutePath, 838 ppapi::HostResource /* file_ref */, 839 ppapi::proxy::SerializedVar /* result */) 840IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBFileRef_ReadDirectoryEntries, 841 ppapi::HostResource /* file_ref */, 842 uint32_t /* callback_id */) 843 844// PPB_Graphics3D. 845IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBGraphics3D_Create, 846 PP_Instance /* instance */, 847 ppapi::HostResource /* share_context */, 848 std::vector<int32_t> /* attrib_list */, 849 ppapi::HostResource /* result */) 850IPC_SYNC_MESSAGE_ROUTED2_0(PpapiHostMsg_PPBGraphics3D_SetGetBuffer, 851 ppapi::HostResource /* context */, 852 int32 /* transfer_buffer_id */) 853IPC_SYNC_MESSAGE_ROUTED1_2(PpapiHostMsg_PPBGraphics3D_GetState, 854 ppapi::HostResource /* context */, 855 gpu::CommandBuffer::State /* state */, 856 bool /* success */) 857IPC_SYNC_MESSAGE_ROUTED3_2(PpapiHostMsg_PPBGraphics3D_Flush, 858 ppapi::HostResource /* context */, 859 int32 /* put_offset */, 860 int32 /* last_known_get */, 861 gpu::CommandBuffer::State /* state */, 862 bool /* success */) 863IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBGraphics3D_AsyncFlush, 864 ppapi::HostResource /* context */, 865 int32 /* put_offset */) 866IPC_SYNC_MESSAGE_ROUTED2_1(PpapiHostMsg_PPBGraphics3D_CreateTransferBuffer, 867 ppapi::HostResource /* context */, 868 uint32 /* size */, 869 int32 /* id */) 870IPC_SYNC_MESSAGE_ROUTED2_0(PpapiHostMsg_PPBGraphics3D_DestroyTransferBuffer, 871 ppapi::HostResource /* context */, 872 int32 /* id */) 873IPC_SYNC_MESSAGE_ROUTED2_1(PpapiHostMsg_PPBGraphics3D_GetTransferBuffer, 874 ppapi::HostResource /* context */, 875 int32 /* id */, 876 ppapi::proxy::SerializedHandle /* transfer_buffer */) 877IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBGraphics3D_SwapBuffers, 878 ppapi::HostResource /* graphics_3d */) 879IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBGraphics3D_InsertSyncPoint, 880 ppapi::HostResource /* context */, 881 uint32 /* sync_point */) 882 883// PPB_ImageData. 884IPC_SYNC_MESSAGE_ROUTED4_3(PpapiHostMsg_PPBImageData_Create, 885 PP_Instance /* instance */, 886 int32 /* format */, 887 PP_Size /* size */, 888 PP_Bool /* init_to_zero */, 889 ppapi::HostResource /* result_resource */, 890 std::string /* image_data_desc */, 891 ppapi::proxy::ImageHandle /* result */) 892IPC_SYNC_MESSAGE_ROUTED4_3(PpapiHostMsg_PPBImageData_CreateNaCl, 893 PP_Instance /* instance */, 894 int32 /* format */, 895 PP_Size /* size */, 896 PP_Bool /* init_to_zero */, 897 ppapi::HostResource /* result_resource */, 898 std::string /* image_data_desc */, 899 ppapi::proxy::SerializedHandle /* result */) 900 901// PPB_Instance. 902IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBInstance_GetWindowObject, 903 PP_Instance /* instance */, 904 ppapi::proxy::SerializedVar /* result */) 905IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBInstance_GetOwnerElementObject, 906 PP_Instance /* instance */, 907 ppapi::proxy::SerializedVar /* result */) 908IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBInstance_BindGraphics, 909 PP_Instance /* instance */, 910 PP_Resource /* device */) 911IPC_SYNC_MESSAGE_ROUTED1_1( 912 PpapiHostMsg_PPBInstance_GetAudioHardwareOutputSampleRate, 913 PP_Instance /* instance */, 914 uint32_t /* result */) 915IPC_SYNC_MESSAGE_ROUTED1_1( 916 PpapiHostMsg_PPBInstance_GetAudioHardwareOutputBufferSize, 917 PP_Instance /* instance */, 918 uint32_t /* result */) 919IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBInstance_IsFullFrame, 920 PP_Instance /* instance */, 921 PP_Bool /* result */) 922IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBInstance_ExecuteScript, 923 PP_Instance /* instance */, 924 ppapi::proxy::SerializedVar /* script */, 925 ppapi::proxy::SerializedVar /* out_exception */, 926 ppapi::proxy::SerializedVar /* result */) 927IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBInstance_GetDefaultCharSet, 928 PP_Instance /* instance */, 929 ppapi::proxy::SerializedVar /* result */) 930IPC_SYNC_MESSAGE_ROUTED2_1(PpapiHostMsg_PPBInstance_SetFullscreen, 931 PP_Instance /* instance */, 932 PP_Bool /* fullscreen */, 933 PP_Bool /* result */) 934IPC_SYNC_MESSAGE_ROUTED1_2(PpapiHostMsg_PPBInstance_GetScreenSize, 935 PP_Instance /* instance */, 936 PP_Bool /* result */, 937 PP_Size /* size */) 938IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_RequestInputEvents, 939 PP_Instance /* instance */, 940 bool /* is_filtering */, 941 uint32_t /* event_classes */) 942IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBInstance_ClearInputEvents, 943 PP_Instance /* instance */, 944 uint32_t /* event_classes */) 945IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBInstance_PostMessage, 946 PP_Instance /* instance */, 947 ppapi::proxy::SerializedVar /* message */) 948IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBInstance_LockMouse, 949 PP_Instance /* instance */) 950IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBInstance_UnlockMouse, 951 PP_Instance /* instance */) 952IPC_SYNC_MESSAGE_ROUTED2_1(PpapiHostMsg_PPBInstance_ResolveRelativeToDocument, 953 PP_Instance /* instance */, 954 ppapi::proxy::SerializedVar /* relative */, 955 ppapi::proxy::SerializedVar /* result */) 956IPC_SYNC_MESSAGE_ROUTED2_1(PpapiHostMsg_PPBInstance_DocumentCanRequest, 957 PP_Instance /* instance */, 958 ppapi::proxy::SerializedVar /* relative */, 959 PP_Bool /* result */) 960IPC_SYNC_MESSAGE_ROUTED2_1(PpapiHostMsg_PPBInstance_DocumentCanAccessDocument, 961 PP_Instance /* active */, 962 PP_Instance /* target */, 963 PP_Bool /* result */) 964IPC_SYNC_MESSAGE_ROUTED1_2(PpapiHostMsg_PPBInstance_GetDocumentURL, 965 PP_Instance /* active */, 966 PP_URLComponents_Dev /* components */, 967 ppapi::proxy::SerializedVar /* result */) 968IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBInstance_GetPluginInstanceURL, 969 PP_Instance /* active */, 970 ppapi::proxy::SerializedVar /* result */) 971IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBInstance_SetCursor, 972 PP_Instance /* instance */, 973 int32_t /* type */, 974 ppapi::HostResource /* custom_image */, 975 PP_Point /* hot_spot */) 976IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBInstance_SetTextInputType, 977 PP_Instance /* instance */, 978 PP_TextInput_Type /* type */) 979IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_UpdateCaretPosition, 980 PP_Instance /* instance */, 981 PP_Rect /* caret */, 982 PP_Rect /* bounding_box */) 983IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBInstance_CancelCompositionText, 984 PP_Instance /* instance */) 985IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBInstance_UpdateSurroundingText, 986 PP_Instance /* instance */, 987 std::string /* text */, 988 uint32_t /* caret */, 989 uint32_t /* anchor */) 990 991// PPB_Var. 992IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBVar_AddRefObject, 993 int64 /* object_id */, 994 int /* unused - need a return value for sync msgs */) 995IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBVar_ReleaseObject, 996 int64 /* object_id */) 997IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBVar_HasProperty, 998 ppapi::proxy::SerializedVar /* object */, 999 ppapi::proxy::SerializedVar /* property */, 1000 ppapi::proxy::SerializedVar /* out_exception */, 1001 PP_Bool /* result */) 1002IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBVar_HasMethodDeprecated, 1003 ppapi::proxy::SerializedVar /* object */, 1004 ppapi::proxy::SerializedVar /* method */, 1005 ppapi::proxy::SerializedVar /* out_exception */, 1006 PP_Bool /* result */) 1007IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBVar_GetProperty, 1008 ppapi::proxy::SerializedVar /* object */, 1009 ppapi::proxy::SerializedVar /* property */, 1010 ppapi::proxy::SerializedVar /* out_exception */, 1011 ppapi::proxy::SerializedVar /* result */) 1012IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBVar_DeleteProperty, 1013 ppapi::proxy::SerializedVar /* object */, 1014 ppapi::proxy::SerializedVar /* property */, 1015 ppapi::proxy::SerializedVar /* out_exception */, 1016 PP_Bool /* result */) 1017IPC_SYNC_MESSAGE_ROUTED1_2(PpapiHostMsg_PPBVar_EnumerateProperties, 1018 ppapi::proxy::SerializedVar /* object */, 1019 std::vector<ppapi::proxy::SerializedVar> /* props */, 1020 ppapi::proxy::SerializedVar /* out_exception */) 1021IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBVar_SetPropertyDeprecated, 1022 ppapi::proxy::SerializedVar /* object */, 1023 ppapi::proxy::SerializedVar /* name */, 1024 ppapi::proxy::SerializedVar /* value */, 1025 ppapi::proxy::SerializedVar /* out_exception */) 1026IPC_SYNC_MESSAGE_ROUTED3_2(PpapiHostMsg_PPBVar_CallDeprecated, 1027 ppapi::proxy::SerializedVar /* object */, 1028 ppapi::proxy::SerializedVar /* method_name */, 1029 std::vector<ppapi::proxy::SerializedVar> /* args */, 1030 ppapi::proxy::SerializedVar /* out_exception */, 1031 ppapi::proxy::SerializedVar /* result */) 1032IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBVar_Construct, 1033 ppapi::proxy::SerializedVar /* object */, 1034 std::vector<ppapi::proxy::SerializedVar> /* args */, 1035 ppapi::proxy::SerializedVar /* out_exception */, 1036 ppapi::proxy::SerializedVar /* result */) 1037IPC_SYNC_MESSAGE_ROUTED2_2(PpapiHostMsg_PPBVar_IsInstanceOfDeprecated, 1038 ppapi::proxy::SerializedVar /* var */, 1039 int64 /* object_class */, 1040 int64 /* object-data */, 1041 PP_Bool /* result */) 1042IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBVar_CreateObjectDeprecated, 1043 PP_Instance /* instance */, 1044 int64 /* object_class */, 1045 int64 /* object_data */, 1046 ppapi::proxy::SerializedVar /* result */) 1047 1048#if !defined(OS_NACL) && !defined(NACL_WIN64) 1049// PPB_Broker. 1050IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBBroker_Create, 1051 PP_Instance /* instance */, 1052 ppapi::HostResource /* result_resource */) 1053IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBBroker_Connect, 1054 ppapi::HostResource /* broker */) 1055 1056// PPB_Buffer. 1057IPC_SYNC_MESSAGE_ROUTED2_2( 1058 PpapiHostMsg_PPBBuffer_Create, 1059 PP_Instance /* instance */, 1060 uint32_t /* size */, 1061 ppapi::HostResource /* result_resource */, 1062 ppapi::proxy::SerializedHandle /* result_shm_handle */) 1063 1064// PPB_ContentDecryptor_Dev messages handled in PPB_Instance_Proxy. 1065IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBInstance_NeedKey, 1066 PP_Instance /* instance */, 1067 ppapi::proxy::SerializedVar /* key_system, String */, 1068 ppapi::proxy::SerializedVar /* session_id, String */, 1069 ppapi::proxy::SerializedVar /* init_data, ArrayBuffer */) 1070IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_KeyAdded, 1071 PP_Instance /* instance */, 1072 ppapi::proxy::SerializedVar /* key_system, String */, 1073 ppapi::proxy::SerializedVar /* session_id, String */) 1074IPC_MESSAGE_ROUTED5(PpapiHostMsg_PPBInstance_KeyMessage, 1075 PP_Instance /* instance */, 1076 ppapi::proxy::SerializedVar /* key_system, String */, 1077 ppapi::proxy::SerializedVar /* session_id, String */, 1078 ppapi::proxy::SerializedVar /* message, ArrayBuffer */, 1079 ppapi::proxy::SerializedVar /* default_url, String */) 1080IPC_MESSAGE_ROUTED5(PpapiHostMsg_PPBInstance_KeyError, 1081 PP_Instance /* instance */, 1082 ppapi::proxy::SerializedVar /* key_system, String */, 1083 ppapi::proxy::SerializedVar /* session_id, String */, 1084 int32_t /* media_error */, 1085 int32_t /* system_code */) 1086IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_DeliverBlock, 1087 PP_Instance /* instance */, 1088 PP_Resource /* decrypted_block, PPB_Buffer_Dev */, 1089 std::string /* serialized_block_info */) 1090IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBInstance_DecoderInitializeDone, 1091 PP_Instance /* instance */, 1092 PP_DecryptorStreamType /* decoder_type */, 1093 uint32_t /* request_id */, 1094 PP_Bool /* success */) 1095IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_DecoderDeinitializeDone, 1096 PP_Instance /* instance */, 1097 PP_DecryptorStreamType /* decoder_type */, 1098 uint32_t /* request_id */) 1099IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_DecoderResetDone, 1100 PP_Instance /* instance */, 1101 PP_DecryptorStreamType /* decoder_type */, 1102 uint32_t /* request_id */) 1103IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_DeliverFrame, 1104 PP_Instance /* instance */, 1105 PP_Resource /* decrypted_frame, PPB_Buffer_Dev */, 1106 std::string /* serialized_block_info */) 1107IPC_MESSAGE_ROUTED3(PpapiHostMsg_PPBInstance_DeliverSamples, 1108 PP_Instance /* instance */, 1109 PP_Resource /* audio_frames, PPB_Buffer_Dev */, 1110 std::string /* serialized_block_info */) 1111#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 1112 1113// PPB_NetworkMonitor_Private. 1114IPC_MESSAGE_CONTROL1(PpapiHostMsg_PPBNetworkMonitor_Start, 1115 uint32 /* plugin_dispatcher_id */) 1116IPC_MESSAGE_CONTROL1(PpapiHostMsg_PPBNetworkMonitor_Stop, 1117 uint32 /* plugin_dispatcher_id */) 1118 1119// PPB_Testing. 1120IPC_SYNC_MESSAGE_ROUTED3_1( 1121 PpapiHostMsg_PPBTesting_ReadImageData, 1122 ppapi::HostResource /* device_context_2d */, 1123 ppapi::HostResource /* image */, 1124 PP_Point /* top_left */, 1125 PP_Bool /* result */) 1126IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBTesting_GetLiveObjectsForInstance, 1127 PP_Instance /* instance */, 1128 uint32 /* result */) 1129IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBTesting_SimulateInputEvent, 1130 PP_Instance /* instance */, 1131 ppapi::InputEventData /* input_event */) 1132IPC_SYNC_MESSAGE_ROUTED1_0( 1133 PpapiHostMsg_PPBTesting_SetMinimumArrayBufferSizeForShmem, 1134 uint32_t /* threshold */) 1135 1136#if !defined(OS_NACL) && !defined(NACL_WIN64) 1137 1138// PPB_VideoDecoder. 1139IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBVideoDecoder_Create, 1140 PP_Instance /* instance */, 1141 ppapi::HostResource /* context */, 1142 PP_VideoDecoder_Profile /* profile */, 1143 ppapi::HostResource /* result */) 1144IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBVideoDecoder_Decode, 1145 ppapi::HostResource /* video_decoder */, 1146 ppapi::HostResource /* bitstream buffer */, 1147 int32 /* bitstream buffer id */, 1148 uint32 /* size of buffer */) 1149IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBVideoDecoder_AssignPictureBuffers, 1150 ppapi::HostResource /* video_decoder */, 1151 std::vector<PP_PictureBuffer_Dev> /* picture buffers */) 1152IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBVideoDecoder_ReusePictureBuffer, 1153 ppapi::HostResource /* video_decoder */, 1154 int32_t /* picture buffer id */) 1155IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBVideoDecoder_Flush, 1156 ppapi::HostResource /* video_decoder */) 1157IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBVideoDecoder_Reset, 1158 ppapi::HostResource /* video_decoder */) 1159IPC_SYNC_MESSAGE_ROUTED1_0(PpapiHostMsg_PPBVideoDecoder_Destroy, 1160 ppapi::HostResource /* video_decoder */) 1161 1162// PPB_Flash_MessageLoop. 1163IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBFlashMessageLoop_Create, 1164 PP_Instance /* instance */, 1165 ppapi::HostResource /* result */) 1166IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBFlashMessageLoop_Run, 1167 ppapi::HostResource /* flash_message_loop */, 1168 int32_t /* result */) 1169IPC_SYNC_MESSAGE_ROUTED1_0(PpapiHostMsg_PPBFlashMessageLoop_Quit, 1170 ppapi::HostResource /* flash_message_loop */) 1171#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 1172 1173// PPB_TCPSocket_Private. 1174IPC_SYNC_MESSAGE_CONTROL2_1(PpapiHostMsg_PPBTCPSocket_Create, 1175 int32 /* routing_id */, 1176 uint32 /* plugin_dispatcher_id */, 1177 uint32 /* socket_id */) 1178IPC_MESSAGE_CONTROL4(PpapiHostMsg_PPBTCPSocket_Connect, 1179 int32 /* routing_id */, 1180 uint32 /* socket_id */, 1181 std::string /* host */, 1182 uint16_t /* port */) 1183IPC_MESSAGE_CONTROL3(PpapiHostMsg_PPBTCPSocket_ConnectWithNetAddress, 1184 int32 /* routing_id */, 1185 uint32 /* socket_id */, 1186 PP_NetAddress_Private /* net_addr */) 1187IPC_MESSAGE_CONTROL5(PpapiHostMsg_PPBTCPSocket_SSLHandshake, 1188 uint32 /* socket_id */, 1189 std::string /* server_name */, 1190 uint16_t /* server_port */, 1191 std::vector<std::vector<char> > /* trusted_certs */, 1192 std::vector<std::vector<char> > /* untrusted_certs */) 1193IPC_MESSAGE_CONTROL2(PpapiHostMsg_PPBTCPSocket_Read, 1194 uint32 /* socket_id */, 1195 int32_t /* bytes_to_read */) 1196IPC_MESSAGE_CONTROL2(PpapiHostMsg_PPBTCPSocket_Write, 1197 uint32 /* socket_id */, 1198 std::string /* data */) 1199IPC_MESSAGE_CONTROL1(PpapiHostMsg_PPBTCPSocket_Disconnect, 1200 uint32 /* socket_id */) 1201IPC_MESSAGE_CONTROL3(PpapiHostMsg_PPBTCPSocket_SetBoolOption, 1202 uint32 /* socket_id */, 1203 uint32 /* name */, 1204 bool /* value */) 1205 1206// UDPSocketPrivate. 1207IPC_MESSAGE_CONTROL0(PpapiHostMsg_UDPSocketPrivate_Create) 1208IPC_MESSAGE_CONTROL2(PpapiHostMsg_UDPSocketPrivate_SetBoolSocketFeature, 1209 int32_t /* name */, 1210 bool /* value */) 1211IPC_MESSAGE_CONTROL1(PpapiHostMsg_UDPSocketPrivate_Bind, 1212 PP_NetAddress_Private /* net_addr */) 1213IPC_MESSAGE_CONTROL1(PpapiHostMsg_UDPSocketPrivate_RecvFrom, 1214 int32_t /* num_bytes */) 1215IPC_MESSAGE_CONTROL2(PpapiHostMsg_UDPSocketPrivate_SendTo, 1216 std::string /* data */, 1217 PP_NetAddress_Private /* net_addr */) 1218IPC_MESSAGE_CONTROL0(PpapiHostMsg_UDPSocketPrivate_Close) 1219IPC_MESSAGE_CONTROL1(PpapiPluginMsg_UDPSocketPrivate_BindReply, 1220 PP_NetAddress_Private /* bound_addr */) 1221IPC_MESSAGE_CONTROL2(PpapiPluginMsg_UDPSocketPrivate_RecvFromReply, 1222 std::string /* data */, 1223 PP_NetAddress_Private /* remote_addr */) 1224IPC_MESSAGE_CONTROL1(PpapiPluginMsg_UDPSocketPrivate_SendToReply, 1225 int32_t /* bytes_written */) 1226 1227// PPB_TCPServerSocket_Private. 1228IPC_MESSAGE_CONTROL5(PpapiHostMsg_PPBTCPServerSocket_Listen, 1229 int32 /* routing_id */, 1230 uint32 /* plugin_dispatcher_id */, 1231 PP_Resource /* socket_resource */, 1232 PP_NetAddress_Private /* addr */, 1233 int32_t /* backlog */) 1234IPC_MESSAGE_CONTROL2(PpapiHostMsg_PPBTCPServerSocket_Accept, 1235 int32 /* tcp_client_socket_routing_id */, 1236 uint32 /* server_socket_id */) 1237IPC_MESSAGE_CONTROL1(PpapiHostMsg_PPBTCPServerSocket_Destroy, 1238 uint32 /* socket_id */) 1239 1240// PPB_X509Certificate_Private 1241IPC_SYNC_MESSAGE_CONTROL1_2(PpapiHostMsg_PPBX509Certificate_ParseDER, 1242 std::vector<char> /* der */, 1243 bool /* succeeded */, 1244 ppapi::PPB_X509Certificate_Fields /* result */) 1245 1246//----------------------------------------------------------------------------- 1247// Resource call/reply messages. 1248// 1249// These are the new-style resource implementations where the resource is only 1250// implemented in the proxy and "resource messages" are sent between this and a 1251// host object. Resource messages are a wrapper around some general routing 1252// information and a separate message of a type defined by the specific resource 1253// sending/receiving it. The extra paremeters allow the nested message to be 1254// routed automatically to the correct resource. 1255 1256// Notification that a resource has been created in the plugin. The nested 1257// message will be resource-type-specific. 1258IPC_MESSAGE_CONTROL3(PpapiHostMsg_ResourceCreated, 1259 ppapi::proxy::ResourceMessageCallParams /* call_params */, 1260 PP_Instance /* instance */, 1261 IPC::Message /* nested_msg */) 1262 1263// Notification that a resource has been destroyed in the plugin. 1264IPC_MESSAGE_CONTROL1(PpapiHostMsg_ResourceDestroyed, 1265 PP_Resource /* resource */) 1266 1267// Most resources are created by the plugin, which then sends a ResourceCreated 1268// message to create a corresponding ResourceHost in the renderer or browser 1269// host process. However, some resources are first created in the host and 1270// "pushed" or returned to the plugin. 1271// 1272// In this case, the host will create a "pending" ResourceHost object which 1273// is identified by an ID. The ID is sent to the plugin process and the 1274// PluginResource object is created. This message is sent from the plugin to 1275// the host process to connect the PluginResource and the pending ResourceHost 1276// (at which point, it's no longer pending). 1277IPC_MESSAGE_CONTROL2(PpapiHostMsg_AttachToPendingHost, 1278 PP_Resource /* resource */, 1279 int /* pending_host_id */) 1280 1281// A resource call is a request from the plugin to the host. It may or may not 1282// require a reply, depending on the params. The nested message will be 1283// resource-type-specific. 1284IPC_MESSAGE_CONTROL2(PpapiHostMsg_ResourceCall, 1285 ppapi::proxy::ResourceMessageCallParams /* call_params */, 1286 IPC::Message /* nested_msg */) 1287 1288// A resource reply is a response to a ResourceCall from a host to the 1289// plugin. The resource ID + sequence number in the params will correspond to 1290// that of the previous ResourceCall. 1291IPC_MESSAGE_CONTROL2( 1292 PpapiPluginMsg_ResourceReply, 1293 ppapi::proxy::ResourceMessageReplyParams /* reply_params */, 1294 IPC::Message /* nested_msg */) 1295 1296IPC_SYNC_MESSAGE_CONTROL2_2(PpapiHostMsg_ResourceSyncCall, 1297 ppapi::proxy::ResourceMessageCallParams /* call_params */, 1298 IPC::Message /* nested_msg */, 1299 ppapi::proxy::ResourceMessageReplyParams /* reply_params */, 1300 IPC::Message /* reply_msg */) 1301 1302// This message is sent from the renderer to the browser when it wants to create 1303// a ResourceHost in the browser. It contains the process ID of the plugin and 1304// the instance of the plugin for which to create the resource for. params 1305// contains the sequence number for the message to track the response. 1306// The nested message is a ResourceHost creation message. 1307IPC_MESSAGE_CONTROL4( 1308 PpapiHostMsg_CreateResourceHostFromHost, 1309 int /* child_process_id */, 1310 ppapi::proxy::ResourceMessageCallParams /* params */, 1311 PP_Instance /* instance */, 1312 IPC::Message /* nested_msg */) 1313 1314// This message is sent from the browser to the renderer when it has created a 1315// ResourceHost for the renderer. It contains the sequence number that was sent 1316// in the request and the ID of the pending ResourceHost which was created in 1317// the browser. This ID is only useful for the plugin which can attach to the 1318// ResourceHost in the browser. 1319IPC_MESSAGE_CONTROL2( 1320 PpapiHostMsg_CreateResourceHostFromHostReply, 1321 int32_t /* sequence */, 1322 int /* pending_host_id */) 1323 1324//----------------------------------------------------------------------------- 1325// Messages for resources using call/reply above. 1326 1327// Broker ---------------------------------------------------------------------- 1328IPC_MESSAGE_CONTROL0(PpapiHostMsg_Broker_Create) 1329 1330// Queries whether the plugin has permission to connect to the Pepper broker. 1331// The response is contained in the error value of the 1332// ResourceMessageReplyParams in the reply message. 1333IPC_MESSAGE_CONTROL0(PpapiHostMsg_Broker_IsAllowed) 1334 1335// Extensions common ----------------------------------------------------------- 1336IPC_MESSAGE_CONTROL0(PpapiHostMsg_ExtensionsCommon_Create) 1337 1338// Starts an extension API request which doesn't expect a response. 1339// |request_name| is an API function name. |args| is a list of input arguments. 1340IPC_MESSAGE_CONTROL2(PpapiHostMsg_ExtensionsCommon_Post, 1341 std::string /* request_name */, 1342 base::ListValue /* args */) 1343 1344// Starts an extension API request which expects a response sent back using a 1345// PpapiPluginMsg_ExtensionsCommon_CallReply message. 1346// |request_name| is an API function name. |args| is a list of input arguments. 1347// |output| is a list of output results. 1348IPC_MESSAGE_CONTROL2(PpapiHostMsg_ExtensionsCommon_Call, 1349 std::string /* request_name */, 1350 base::ListValue /* args */) 1351IPC_MESSAGE_CONTROL1(PpapiPluginMsg_ExtensionsCommon_CallReply, 1352 base::ListValue /* output */) 1353 1354// Ext_CrxFileSystem 1355IPC_MESSAGE_CONTROL0(PpapiHostMsg_Ext_CrxFileSystem_Create) 1356IPC_MESSAGE_CONTROL0(PpapiHostMsg_Ext_CrxFileSystem_BrowserOpen) 1357IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Ext_CrxFileSystem_BrowserOpenReply, 1358 std::string /* fsid */) 1359 1360// File chooser. 1361IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileChooser_Create) 1362IPC_MESSAGE_CONTROL4(PpapiHostMsg_FileChooser_Show, 1363 bool /* save_as */, 1364 bool /* open_multiple */, 1365 std::string /* suggested_file_name */, 1366 std::vector<std::string> /* accept_mime_types */) 1367IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FileChooser_ShowReply, 1368 std::vector<ppapi::PPB_FileRef_CreateInfo> /* files */) 1369 1370// FileIO 1371IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileIO_Create) 1372IPC_MESSAGE_CONTROL2(PpapiHostMsg_FileIO_Open, 1373 PP_Resource /* file_ref_resource */, 1374 int32_t /* open_flags */) 1375IPC_MESSAGE_CONTROL0(PpapiPluginMsg_FileIO_OpenReply) 1376IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileIO_Close) 1377IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileIO_Query) 1378IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FileIO_QueryReply, PP_FileInfo /* info */) 1379IPC_MESSAGE_CONTROL2(PpapiHostMsg_FileIO_Touch, 1380 PP_Time /* last_access_time */, 1381 PP_Time /* last_modified_time */) 1382IPC_MESSAGE_CONTROL2(PpapiHostMsg_FileIO_Read, 1383 int64_t /* offset */, 1384 int32_t /* bytes_to_read */) 1385IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FileIO_ReadReply, std::string /* data */) 1386IPC_MESSAGE_CONTROL2(PpapiHostMsg_FileIO_Write, 1387 int64_t /* offset */, 1388 std::string /* data */) 1389IPC_MESSAGE_CONTROL1(PpapiHostMsg_FileIO_SetLength, 1390 int64_t /* length */) 1391IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileIO_Flush) 1392IPC_MESSAGE_CONTROL2(PpapiHostMsg_FileIO_WillWrite, 1393 int64_t /* offset */, 1394 int32_t /* bytes_to_write */) 1395IPC_MESSAGE_CONTROL1(PpapiHostMsg_FileIO_WillSetLength, 1396 int64_t /* length */) 1397IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileIO_GetOSFileDescriptor) 1398IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FileIO_GetOSFileDescriptorReply, 1399 int32_t /* file descriptor */) 1400IPC_MESSAGE_CONTROL0(PpapiHostMsg_FileIO_RequestOSFileHandle) 1401IPC_MESSAGE_CONTROL0(PpapiPluginMsg_FileIO_RequestOSFileHandleReply) 1402IPC_MESSAGE_CONTROL0(PpapiPluginMsg_FileIO_GeneralReply) 1403 1404// FileSystem 1405IPC_MESSAGE_CONTROL1(PpapiHostMsg_FileSystem_Create, 1406 PP_FileSystemType /* type */) 1407IPC_MESSAGE_CONTROL1(PpapiHostMsg_FileSystem_Open, 1408 int64_t /* expected_size */) 1409IPC_MESSAGE_CONTROL0(PpapiPluginMsg_FileSystem_OpenReply) 1410IPC_MESSAGE_CONTROL1(PpapiHostMsg_FileSystem_InitIsolatedFileSystem, 1411 std::string /* fsid */) 1412 1413// Flash DRM ------------------------------------------------------------------ 1414IPC_MESSAGE_CONTROL0(PpapiHostMsg_FlashDRM_Create) 1415 1416// Requests the device ID. 1417IPC_MESSAGE_CONTROL0(PpapiHostMsg_FlashDRM_GetDeviceID) 1418// Reply for GetDeviceID which includes the device ID as a string. 1419IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashDRM_GetDeviceIDReply, 1420 std::string /* id */) 1421 1422// Gamepad. 1423IPC_MESSAGE_CONTROL0(PpapiHostMsg_Gamepad_Create) 1424 1425// Requests that the gamepad host send the shared memory handle to the plugin 1426// process. 1427IPC_MESSAGE_CONTROL0(PpapiHostMsg_Gamepad_RequestMemory) 1428 1429// Reply to a RequestMemory call. This supplies the shared memory handle. The 1430// actual handle is passed in the ReplyParams struct. 1431IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Gamepad_SendMemory) 1432 1433 1434// Graphics2D, plugin -> host 1435IPC_MESSAGE_CONTROL2(PpapiHostMsg_Graphics2D_Create, 1436 PP_Size /* size */, 1437 PP_Bool /* is_always_opaque */) 1438IPC_MESSAGE_CONTROL4(PpapiHostMsg_Graphics2D_PaintImageData, 1439 ppapi::HostResource /* image_data */, 1440 PP_Point /* top_left */, 1441 bool /* src_rect_specified */, 1442 PP_Rect /* src_rect */) 1443IPC_MESSAGE_CONTROL3(PpapiHostMsg_Graphics2D_Scroll, 1444 bool /* clip_specified */, 1445 PP_Rect /* clip */, 1446 PP_Point /* amount */) 1447IPC_MESSAGE_CONTROL1(PpapiHostMsg_Graphics2D_ReplaceContents, 1448 ppapi::HostResource /* image_data */) 1449IPC_MESSAGE_CONTROL1(PpapiHostMsg_Graphics2D_Dev_SetScale, 1450 float /* scale */) 1451 1452// Graphics2D, plugin -> host -> plugin 1453IPC_MESSAGE_CONTROL0(PpapiHostMsg_Graphics2D_Flush) 1454IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Graphics2D_FlushAck) 1455 1456IPC_MESSAGE_CONTROL2(PpapiHostMsg_Graphics2D_ReadImageData, 1457 PP_Resource /* image */, 1458 PP_Point /* top_left */) 1459IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Graphics2D_ReadImageDataAck) 1460 1461// TrueTypeFont. 1462IPC_MESSAGE_CONTROL0(PpapiHostMsg_TrueTypeFontSingleton_Create) 1463IPC_MESSAGE_CONTROL0(PpapiHostMsg_TrueTypeFontSingleton_GetFontFamilies) 1464IPC_MESSAGE_CONTROL1(PpapiPluginMsg_TrueTypeFontSingleton_GetFontFamiliesReply, 1465 std::vector<std::string> /* font_families */) 1466IPC_MESSAGE_CONTROL1(PpapiHostMsg_TrueTypeFontSingleton_GetFontsInFamily, 1467 std::string /* family */) 1468IPC_MESSAGE_CONTROL1(PpapiPluginMsg_TrueTypeFontSingleton_GetFontsInFamilyReply, 1469 std::vector<ppapi::proxy::SerializedTrueTypeFontDesc> 1470 /* fonts */) 1471IPC_MESSAGE_CONTROL1(PpapiHostMsg_TrueTypeFont_Create, 1472 ppapi::proxy::SerializedTrueTypeFontDesc /* desc */) 1473IPC_MESSAGE_CONTROL0(PpapiHostMsg_TrueTypeFont_Describe) 1474IPC_MESSAGE_CONTROL1(PpapiPluginMsg_TrueTypeFont_DescribeReply, 1475 ppapi::proxy::SerializedTrueTypeFontDesc /* desc */) 1476IPC_MESSAGE_CONTROL0(PpapiHostMsg_TrueTypeFont_GetTableTags) 1477IPC_MESSAGE_CONTROL1(PpapiPluginMsg_TrueTypeFont_GetTableTagsReply, 1478 std::vector<uint32_t> /* tags */) 1479IPC_MESSAGE_CONTROL3(PpapiHostMsg_TrueTypeFont_GetTable, 1480 uint32_t /* table */, 1481 int32_t /* offset */, 1482 int32_t /* max_data_length */) 1483IPC_MESSAGE_CONTROL1(PpapiPluginMsg_TrueTypeFont_GetTableReply, 1484 std::string /* data */) 1485 1486// HostResolverPrivate, plugin -> host -> plugin 1487IPC_MESSAGE_CONTROL0(PpapiHostMsg_HostResolverPrivate_Create) 1488IPC_MESSAGE_CONTROL2(PpapiHostMsg_HostResolverPrivate_Resolve, 1489 ppapi::HostPortPair /* host_port */, 1490 PP_HostResolver_Private_Hint /* hint */) 1491IPC_MESSAGE_CONTROL2(PpapiPluginMsg_HostResolverPrivate_ResolveReply, 1492 std::string /* canonical_name */, 1493 std::vector<PP_NetAddress_Private> /* net_address_list */) 1494 1495// Printing. 1496IPC_MESSAGE_CONTROL0(PpapiHostMsg_Printing_Create) 1497IPC_MESSAGE_CONTROL0(PpapiHostMsg_Printing_GetDefaultPrintSettings) 1498IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Printing_GetDefaultPrintSettingsReply, 1499 PP_PrintSettings_Dev /* print_settings */) 1500 1501// URLLoader ------------------------------------------------------------------ 1502 1503IPC_MESSAGE_CONTROL0(PpapiHostMsg_URLLoader_Create) 1504 1505// These messages correspond to PPAPI calls and all should get a 1506// CallbackComplete message. 1507IPC_MESSAGE_CONTROL1(PpapiHostMsg_URLLoader_Open, 1508 ppapi::URLRequestInfoData /* request_data */) 1509 1510// The plugin can tell the host to defer a load to hold off on sending more 1511// data because the buffer in the plugin is full. When defers_loading is set to 1512// false, data streaming will resume. 1513// 1514// When auditing redirects (no auto follow) the load will be automatically 1515// deferred each time we get a redirect. The plugin will reset this to false 1516// by sending this message when it wants to continue following the redirect. 1517// 1518// When streaming data, the host may still send more data after this call (for 1519// example, it could already be in-flight at the time of this request). 1520IPC_MESSAGE_CONTROL1(PpapiHostMsg_URLLoader_SetDeferLoading, 1521 bool /* defers_loading */) 1522 1523// Closes the URLLoader. There is no reply. 1524IPC_MESSAGE_CONTROL0(PpapiHostMsg_URLLoader_Close) 1525 1526// Requests that cross-site restrictions be ignored. The plugin must have 1527// the private permission set. Otherwise this message will be ignored by the 1528// renderer. There is no reply. 1529IPC_MESSAGE_CONTROL0(PpapiHostMsg_URLLoader_GrantUniversalAccess) 1530 1531// Push notification that a response is available. 1532IPC_MESSAGE_CONTROL1(PpapiPluginMsg_URLLoader_ReceivedResponse, 1533 ppapi::URLResponseInfoData /* response */) 1534 1535// Push notification with load data from the renderer. It is a custom generated 1536// message with the response data (array of bytes stored via WriteData) 1537// appended. 1538IPC_MESSAGE_CONTROL0(PpapiPluginMsg_URLLoader_SendData) 1539 1540// Push notification indicating that all data has been sent, either via 1541// SendData or by streaming it to a file. Note that since this is a push 1542// notification, we don't use the result field of the ResourceMessageReply. 1543IPC_MESSAGE_CONTROL1(PpapiPluginMsg_URLLoader_FinishedLoading, 1544 int32_t /* result */) 1545 1546// Push notification from the renderer to the plugin to tell it about download 1547// and upload progress. This will only be sent if the plugin has requested 1548// progress updates, and only the fields requested by the plugin will be 1549// valid. 1550IPC_MESSAGE_CONTROL4(PpapiPluginMsg_URLLoader_UpdateProgress, 1551 int64_t /* bytes_sent */, 1552 int64_t /* total_bytes_to_be_sent */, 1553 int64_t /* bytes_received */, 1554 int64_t /* total_bytes_to_be_received */) 1555 1556// Shared memory --------------------------------------------------------------- 1557 1558// Creates shared memory on the host side, returning a handle to the shared 1559// memory on the plugin and keeping the memory mapped in on the host. 1560// We return a "host handle_id" that can be mapped back to the 1561// handle on the host side by PpapiGlobals::UntrackSharedMemoryHandle(). 1562IPC_SYNC_MESSAGE_CONTROL2_2(PpapiHostMsg_SharedMemory_CreateSharedMemory, 1563 PP_Instance /* instance */, 1564 uint32_t /* size */, 1565 int /* host_handle_id */, 1566 ppapi::proxy::SerializedHandle /* plugin_handle */) 1567 1568// WebSocket ------------------------------------------------------------------- 1569 1570IPC_MESSAGE_CONTROL0(PpapiHostMsg_WebSocket_Create) 1571 1572// Establishes the connection to a server. This message requires 1573// WebSocket_ConnectReply as a reply message. 1574IPC_MESSAGE_CONTROL2(PpapiHostMsg_WebSocket_Connect, 1575 std::string /* url */, 1576 std::vector<std::string> /* protocols */) 1577 1578// Closes established connection with graceful closing handshake. This message 1579// requires WebSocket_CloseReply as a reply message. 1580IPC_MESSAGE_CONTROL2(PpapiHostMsg_WebSocket_Close, 1581 int32_t /* code */, 1582 std::string /* reason */) 1583 1584// Sends a text frame to the server. No reply is defined. 1585IPC_MESSAGE_CONTROL1(PpapiHostMsg_WebSocket_SendText, 1586 std::string /* message */) 1587 1588// Sends a binary frame to the server. No reply is defined. 1589IPC_MESSAGE_CONTROL1(PpapiHostMsg_WebSocket_SendBinary, 1590 std::vector<uint8_t> /* message */) 1591 1592// Fails the connection. This message invokes RFC6455 defined 1593// _Fail the WebSocket Connection_ operation. No reply is defined. 1594IPC_MESSAGE_CONTROL1(PpapiHostMsg_WebSocket_Fail, 1595 std::string /* message */) 1596 1597// This message is a reply to WebSocket_Connect. If the |url| and |protocols| 1598// are invalid, WebSocket_ConnectReply is issued immediately and it contains 1599// proper error code in its result. Otherwise, WebSocket_ConnectReply is sent 1600// with valid |url|, |protocol|, and result PP_OK. |protocol| is not a passed 1601// |protocols|, but a result of opening handshake negotiation. If the 1602// connection can not be established successfully, WebSocket_ConnectReply is 1603// not issued, but WebSocket_ClosedReply is sent instead. 1604IPC_MESSAGE_CONTROL2(PpapiPluginMsg_WebSocket_ConnectReply, 1605 std::string /* url */, 1606 std::string /* protocol */) 1607 1608// This message is a reply to WebSocket_Close. If the operation fails, 1609// WebSocket_CloseReply is issued immediately and it contains PP_ERROR_FAILED. 1610// Otherwise, CloseReply will be issued after the closing handshake is 1611// finished. All arguments will be valid iff the result is PP_OK and it means 1612// that the client initiated closing handshake is finished gracefully. 1613IPC_MESSAGE_CONTROL4(PpapiPluginMsg_WebSocket_CloseReply, 1614 uint64_t /* buffered_amount */, 1615 bool /* was_clean */, 1616 uint16_t /* code */, 1617 std::string /* reason */) 1618 1619// Unsolicited reply message to transmit a receiving text frame. 1620IPC_MESSAGE_CONTROL1(PpapiPluginMsg_WebSocket_ReceiveTextReply, 1621 std::string /* message */) 1622 1623// Unsolicited reply message to transmit a receiving binary frame. 1624IPC_MESSAGE_CONTROL1(PpapiPluginMsg_WebSocket_ReceiveBinaryReply, 1625 std::vector<uint8_t> /* message */) 1626 1627// Unsolicited reply message to notify a error on underlying network connetion. 1628IPC_MESSAGE_CONTROL0(PpapiPluginMsg_WebSocket_ErrorReply) 1629 1630// Unsolicited reply message to update the buffered amount value. 1631IPC_MESSAGE_CONTROL1(PpapiPluginMsg_WebSocket_BufferedAmountReply, 1632 uint64_t /* buffered_amount */) 1633 1634// Unsolicited reply message to update |state| because of incoming external 1635// events, e.g., protocol error, or unexpected network closure. 1636IPC_MESSAGE_CONTROL1(PpapiPluginMsg_WebSocket_StateReply, 1637 int32_t /* state */) 1638 1639// Unsolicited reply message to notify that the connection is closed without 1640// any WebSocket_Close request. Server initiated closing handshake or 1641// unexpected network errors will invoke this message. 1642IPC_MESSAGE_CONTROL4(PpapiPluginMsg_WebSocket_ClosedReply, 1643 uint64_t /* buffered_amount */, 1644 bool /* was_clean */, 1645 uint16_t /* code */, 1646 std::string /* reason */) 1647 1648#if !defined(OS_NACL) && !defined(NACL_WIN64) 1649 1650// Audio input. 1651IPC_MESSAGE_CONTROL0(PpapiHostMsg_AudioInput_Create) 1652IPC_MESSAGE_CONTROL3(PpapiHostMsg_AudioInput_Open, 1653 std::string /* device_id */, 1654 PP_AudioSampleRate /* sample_rate */, 1655 uint32_t /* sample_frame_count */) 1656// Reply to an Open call. This supplies a socket handle and a shared memory 1657// handle. Both handles are passed in the ReplyParams struct. 1658IPC_MESSAGE_CONTROL0(PpapiPluginMsg_AudioInput_OpenReply) 1659IPC_MESSAGE_CONTROL1(PpapiHostMsg_AudioInput_StartOrStop, bool /* capture */) 1660IPC_MESSAGE_CONTROL0(PpapiHostMsg_AudioInput_Close) 1661 1662// BrowserFont ----------------------------------------------------------------- 1663 1664IPC_MESSAGE_CONTROL0(PpapiHostMsg_BrowserFontSingleton_Create) 1665 1666// Requests that the browser reply with the list of font families via 1667// PpapiPluginMsg_BrowserFontSingleton_GetFontFamiliesReply. 1668IPC_MESSAGE_CONTROL0(PpapiHostMsg_BrowserFontSingleton_GetFontFamilies) 1669 1670// Reply to PpapiHostMsg_BrowserFontSingleton_GetFontFamilies with the font 1671// family list. The |families| result is encoded by separating each family name 1672// by a null character. 1673IPC_MESSAGE_CONTROL1(PpapiPluginMsg_BrowserFontSingleton_GetFontFamiliesReply, 1674 std::string /* families */) 1675 1676// Flash ----------------------------------------------------------------------- 1677 1678IPC_MESSAGE_CONTROL0(PpapiHostMsg_Flash_Create) 1679 1680// Message to notify the browser to register an update in system activity. 1681IPC_MESSAGE_CONTROL0(PpapiHostMsg_Flash_UpdateActivity) 1682 1683// Query the browser for the proxy server to use for the given URL. 1684IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_GetProxyForURL, std::string /* url */) 1685// Reply message for GetProxyForURL containing the proxy server. 1686IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Flash_GetProxyForURLReply, 1687 std::string /* proxy */) 1688 1689// Queries the browser for the local time zone offset for a given time. 1690IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_GetLocalTimeZoneOffset, 1691 base::Time /* time */) 1692// Reply to GetLocalTimeZoneOffset containing the time zone offset as a double. 1693IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Flash_GetLocalTimeZoneOffsetReply, 1694 double /* offset */) 1695 1696// Query the browser for the restrictions on storing Flash LSOs. 1697IPC_MESSAGE_CONTROL0(PpapiHostMsg_Flash_GetLocalDataRestrictions) 1698// Reply message for GetLocalDataRestrictions containing the restrictions to 1699// use. These are PP_FlashLSORestrictions cast to an int32_t. 1700IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Flash_GetLocalDataRestrictionsReply, 1701 int32_t /* restrictions */) 1702 1703// Notifies the renderer whether the Flash instance is in windowed mode. No 1704// reply is sent. 1705IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_SetInstanceAlwaysOnTop, 1706 bool /* on_top */) 1707 1708// Notifies the renderer to draw text to the given PP_ImageData resource. All 1709// parmeters for drawing (including the resource to draw to) are contianed in 1710// the PPBFlash_DrawGlyphs_Params structure. An error code is sent in a reply 1711// message indicating success. 1712IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_DrawGlyphs, 1713 ppapi::proxy::PPBFlash_DrawGlyphs_Params /* params */) 1714 1715// Notifies the renderer to navigate to the given URL contained in the 1716// URLRequestInfoData. An error code is sent in a reply message indicating 1717// success. 1718IPC_MESSAGE_CONTROL3(PpapiHostMsg_Flash_Navigate, 1719 ppapi::URLRequestInfoData /* data */, 1720 std::string /* target */, 1721 bool /* from_user_action */) 1722 1723// Queries the renderer on whether the plugin instance is the topmost element 1724// in the area of the instance specified by the given PP_Rect. PP_OK is sent as 1725// the error code in a reply message if the rect is topmost otherwise 1726// PP_ERROR_FAILED is sent. 1727IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_IsRectTopmost, 1728 PP_Rect /* rect */) 1729 1730// Notifies the renderer to invoke printing for the given plugin instance. No 1731// reply is sent. 1732IPC_MESSAGE_CONTROL0(PpapiHostMsg_Flash_InvokePrinting) 1733 1734// DeviceEnumeration ----------------------------------------------------------- 1735// Device enumeration messages used by audio input and video capture. 1736IPC_MESSAGE_CONTROL0(PpapiHostMsg_DeviceEnumeration_EnumerateDevices) 1737IPC_MESSAGE_CONTROL1(PpapiPluginMsg_DeviceEnumeration_EnumerateDevicesReply, 1738 std::vector<ppapi::DeviceRefData> /* devices */) 1739IPC_MESSAGE_CONTROL1(PpapiHostMsg_DeviceEnumeration_MonitorDeviceChange, 1740 uint32_t /* callback_id */) 1741IPC_MESSAGE_CONTROL0(PpapiHostMsg_DeviceEnumeration_StopMonitoringDeviceChange) 1742IPC_MESSAGE_CONTROL2(PpapiPluginMsg_DeviceEnumeration_NotifyDeviceChange, 1743 uint32_t /* callback_id */, 1744 std::vector<ppapi::DeviceRefData> /* devices */) 1745 1746// Flash clipboard. 1747IPC_MESSAGE_CONTROL0(PpapiHostMsg_FlashClipboard_Create) 1748IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashClipboard_RegisterCustomFormat, 1749 std::string /* format_name */) 1750IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashClipboard_RegisterCustomFormatReply, 1751 uint32_t /* format */) 1752IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashClipboard_IsFormatAvailable, 1753 uint32_t /* clipboard_type */, 1754 uint32_t /* format */) 1755IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashClipboard_ReadData, 1756 uint32_t /* clipboard_type */, 1757 uint32_t /* format */) 1758IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashClipboard_ReadDataReply, 1759 std::string /* result */) 1760IPC_MESSAGE_CONTROL3(PpapiHostMsg_FlashClipboard_WriteData, 1761 uint32_t /* clipboard_type */, 1762 std::vector<uint32_t> /* formats */, 1763 std::vector<std::string> /* data */) 1764 1765// Flash file. 1766IPC_MESSAGE_CONTROL0(PpapiHostMsg_FlashFile_Create) 1767IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashFile_OpenFile, 1768 ppapi::PepperFilePath /* path */, 1769 int /* flags */) 1770IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashFile_RenameFile, 1771 ppapi::PepperFilePath /* from_path */, 1772 ppapi::PepperFilePath /* to_path */) 1773IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashFile_DeleteFileOrDir, 1774 ppapi::PepperFilePath /* path */, 1775 bool /* recursive */) 1776IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFile_CreateDir, 1777 ppapi::PepperFilePath /* path */) 1778IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFile_QueryFile, 1779 ppapi::PepperFilePath /* path */) 1780IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashFile_QueryFileReply, 1781 base::PlatformFileInfo /* file_info */) 1782IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFile_GetDirContents, 1783 ppapi::PepperFilePath /* path */) 1784IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashFile_GetDirContentsReply, 1785 ppapi::DirContents /* entries */) 1786IPC_MESSAGE_CONTROL0(PpapiHostMsg_FlashFile_CreateTemporaryFile) 1787 1788// Flash font file. 1789IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashFontFile_Create, 1790 ppapi::proxy::SerializedFontDescription /* description */, 1791 PP_PrivateFontCharset /* charset */) 1792IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFontFile_GetFontTable, 1793 uint32_t /* table */) 1794IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashFontFile_GetFontTableReply, 1795 std::string /* output */) 1796 1797// Flash fullscreen. 1798IPC_MESSAGE_CONTROL0(PpapiHostMsg_FlashFullscreen_Create) 1799IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFullscreen_SetFullscreen, 1800 bool /* fullscreen */) 1801 1802// FlashMenu ------------------------------------------------------------------ 1803 1804// Creates the flash menu with the given data. 1805IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashMenu_Create, 1806 ppapi::proxy::SerializedFlashMenu /* menu_data */) 1807 1808// Shows the menu at the given location relative to the plugin instance. 1809IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashMenu_Show, 1810 PP_Point /* location */) 1811 1812// Reply to a show command. If the resource reply is PP_OK, the selected_id 1813// will be the menu item ID chosen by the user. 1814IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashMenu_ShowReply, 1815 int32_t /* selected_id */) 1816 1817// PDF ------------------------------------------------------------------------ 1818 1819// Creates the PDF resource. 1820IPC_MESSAGE_CONTROL0(PpapiHostMsg_PDF_Create) 1821 1822// Requests the localized string for the given ID. 1823IPC_MESSAGE_CONTROL1(PpapiHostMsg_PDF_GetLocalizedString, 1824 PP_ResourceString /* string_id */) 1825// Reply for PpapiHostMsg_PDF_GetLocalizedString containing the localized 1826// string. 1827IPC_MESSAGE_CONTROL1(PpapiPluginMsg_PDF_GetLocalizedStringReply, 1828 std::string /* localized_string*/) 1829 1830// Notifies the renderer that the PDF started loading. 1831IPC_MESSAGE_CONTROL0(PpapiHostMsg_PDF_DidStartLoading) 1832 1833// Notifies the renderer that the PDF stopped loading. 1834IPC_MESSAGE_CONTROL0(PpapiHostMsg_PDF_DidStopLoading) 1835 1836// Sets any restrictions on the PDF content. 1837IPC_MESSAGE_CONTROL1(PpapiHostMsg_PDF_SetContentRestriction, 1838 int /* restrictions */) 1839 1840// Requests that the specified action be recorded with UMA. 1841IPC_MESSAGE_CONTROL1(PpapiHostMsg_PDF_UserMetricsRecordAction, 1842 std::string /* action */) 1843 1844// Notifies the renderer that the current PDF uses an unsupported feature. 1845IPC_MESSAGE_CONTROL0(PpapiHostMsg_PDF_HasUnsupportedFeature) 1846 1847// Notifies the renderer to print the current PDF. 1848IPC_MESSAGE_CONTROL0(PpapiHostMsg_PDF_Print) 1849 1850// Notifies the renderer to save the current PDF. 1851IPC_MESSAGE_CONTROL0(PpapiHostMsg_PDF_SaveAs) 1852 1853// Requests a resource image for the plugin at a particular scale. 1854IPC_MESSAGE_CONTROL2(PpapiHostMsg_PDF_GetResourceImage, 1855 PP_ResourceImage /* image_id */, 1856 float /* scale */) 1857// Reply for PpapiHostMsg_PDF_GetResourceImage containing the host resource id 1858// of the image and a PP_ImageDataDesc which describes the image. Also carries 1859// a shared memory handle pointing to the memory containg the image. On linux, 1860// the handle is transmitted in this message as |fd|. This is due to the 1861// unfortunate way that ImageHandles are defined for use with PPB_ImageData. 1862IPC_MESSAGE_CONTROL3(PpapiPluginMsg_PDF_GetResourceImageReply, 1863 ppapi::HostResource /* resource_id */, 1864 PP_ImageDataDesc /* image_data_desc */, 1865 int /* fd */) 1866 1867// VideoCapture_Dev, plugin -> host 1868IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoCapture_Create) 1869IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoCapture_StartCapture) 1870IPC_MESSAGE_CONTROL1(PpapiHostMsg_VideoCapture_ReuseBuffer, 1871 uint32_t /* buffer */) 1872IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoCapture_StopCapture) 1873IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoCapture_Close) 1874 1875// VideoCapture_Dev, plugin -> host -> plugin 1876IPC_MESSAGE_CONTROL3(PpapiHostMsg_VideoCapture_Open, 1877 std::string /* device_id */, 1878 PP_VideoCaptureDeviceInfo_Dev /* requested_info */, 1879 uint32_t /* buffer_count */) 1880IPC_MESSAGE_CONTROL0(PpapiPluginMsg_VideoCapture_OpenReply) 1881 1882// VideoCapture_Dev, host -> plugin 1883IPC_MESSAGE_CONTROL3(PpapiPluginMsg_VideoCapture_OnDeviceInfo, 1884 PP_VideoCaptureDeviceInfo_Dev /* info */, 1885 std::vector<ppapi::HostResource> /* buffers */, 1886 uint32_t /* buffer_size */) 1887IPC_MESSAGE_CONTROL1(PpapiPluginMsg_VideoCapture_OnStatus, 1888 uint32_t /* status */) 1889IPC_MESSAGE_CONTROL1(PpapiPluginMsg_VideoCapture_OnError, 1890 uint32_t /* error */) 1891IPC_MESSAGE_CONTROL1(PpapiPluginMsg_VideoCapture_OnBufferReady, 1892 uint32_t /* buffer */) 1893 1894// Talk ------------------------------------------------------------------------ 1895 1896IPC_MESSAGE_CONTROL0(PpapiHostMsg_Talk_Create) 1897IPC_MESSAGE_CONTROL1(PpapiHostMsg_Talk_RequestPermission, 1898 PP_TalkPermission /* permission */) 1899IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Talk_RequestPermissionReply) 1900IPC_MESSAGE_CONTROL0(PpapiHostMsg_Talk_StartRemoting) 1901IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Talk_StartRemotingReply) 1902IPC_MESSAGE_CONTROL0(PpapiHostMsg_Talk_StopRemoting) 1903IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Talk_StopRemotingReply) 1904IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Talk_NotifyEvent, PP_TalkEvent /* event */) 1905 1906// MediaStream ----------------------------------------------------------------- 1907 1908// VideoDestination Private. 1909IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoDestination_Create) 1910IPC_MESSAGE_CONTROL1(PpapiHostMsg_VideoDestination_Open, 1911 std::string /* stream_url */) 1912IPC_MESSAGE_CONTROL0(PpapiPluginMsg_VideoDestination_OpenReply) 1913IPC_MESSAGE_CONTROL2(PpapiHostMsg_VideoDestination_PutFrame, 1914 ppapi::HostResource /* image_data */, 1915 PP_TimeTicks /* timestamp */) 1916IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoDestination_Close) 1917 1918// VideoSource Private. 1919IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoSource_Create) 1920IPC_MESSAGE_CONTROL1(PpapiHostMsg_VideoSource_Open, 1921 std::string /* stream_url */) 1922IPC_MESSAGE_CONTROL0(PpapiPluginMsg_VideoSource_OpenReply) 1923IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoSource_GetFrame) 1924IPC_MESSAGE_CONTROL4(PpapiPluginMsg_VideoSource_GetFrameReply, 1925 ppapi::HostResource /* resource_id */, 1926 PP_ImageDataDesc /* image_data_desc */, 1927 int /* fd */, 1928 PP_TimeTicks /* timestamp */) 1929IPC_MESSAGE_CONTROL0(PpapiHostMsg_VideoSource_Close) 1930 1931#endif // !defined(OS_NACL) && !defined(NACL_WIN64) 1932