| 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 // Multiply-included message header, no traditional include guard. | 5 // Multiply-included message header, no traditional include guard. |
| 6 #include <string> | 6 #include <string> |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "ppapi/c/dev/ppp_printing_dev.h" | 24 #include "ppapi/c/dev/ppp_printing_dev.h" |
| 25 #include "ppapi/c/pp_bool.h" | 25 #include "ppapi/c/pp_bool.h" |
| 26 #include "ppapi/c/pp_file_info.h" | 26 #include "ppapi/c/pp_file_info.h" |
| 27 #include "ppapi/c/pp_instance.h" | 27 #include "ppapi/c/pp_instance.h" |
| 28 #include "ppapi/c/pp_module.h" | 28 #include "ppapi/c/pp_module.h" |
| 29 #include "ppapi/c/pp_point.h" | 29 #include "ppapi/c/pp_point.h" |
| 30 #include "ppapi/c/pp_rect.h" | 30 #include "ppapi/c/pp_rect.h" |
| 31 #include "ppapi/c/pp_resource.h" | 31 #include "ppapi/c/pp_resource.h" |
| 32 #include "ppapi/c/pp_size.h" | 32 #include "ppapi/c/pp_size.h" |
| 33 #include "ppapi/c/pp_time.h" | 33 #include "ppapi/c/pp_time.h" |
| 34 #include "ppapi/c/ppb_audio_config.h" |
| 34 #include "ppapi/c/private/pp_content_decryptor.h" | 35 #include "ppapi/c/private/pp_content_decryptor.h" |
| 35 #include "ppapi/c/private/pp_private_font_charset.h" | 36 #include "ppapi/c/private/pp_private_font_charset.h" |
| 36 #include "ppapi/c/private/ppb_flash.h" | 37 #include "ppapi/c/private/ppb_flash.h" |
| 37 #include "ppapi/c/private/ppb_host_resolver_private.h" | 38 #include "ppapi/c/private/ppb_host_resolver_private.h" |
| 38 #include "ppapi/c/private/ppb_net_address_private.h" | 39 #include "ppapi/c/private/ppb_net_address_private.h" |
| 39 #include "ppapi/c/private/ppb_tcp_socket_private.h" | 40 #include "ppapi/c/private/ppb_tcp_socket_private.h" |
| 40 #include "ppapi/c/private/ppb_udp_socket_private.h" | 41 #include "ppapi/c/private/ppb_udp_socket_private.h" |
| 41 #include "ppapi/c/private/ppp_flash_browser_operations.h" | 42 #include "ppapi/c/private/ppp_flash_browser_operations.h" |
| 42 #include "ppapi/proxy/ppapi_param_traits.h" | 43 #include "ppapi/proxy/ppapi_param_traits.h" |
| 43 #include "ppapi/proxy/ppapi_proxy_export.h" | 44 #include "ppapi/proxy/ppapi_proxy_export.h" |
| 44 #include "ppapi/proxy/resource_message_params.h" | 45 #include "ppapi/proxy/resource_message_params.h" |
| 45 #include "ppapi/proxy/serialized_flash_menu.h" | 46 #include "ppapi/proxy/serialized_flash_menu.h" |
| 46 #include "ppapi/proxy/serialized_structs.h" | 47 #include "ppapi/proxy/serialized_structs.h" |
| 47 #include "ppapi/proxy/serialized_var.h" | 48 #include "ppapi/proxy/serialized_var.h" |
| 48 #include "ppapi/shared_impl/ppapi_preferences.h" | 49 #include "ppapi/shared_impl/ppapi_preferences.h" |
| 49 #include "ppapi/shared_impl/ppb_device_ref_shared.h" | 50 #include "ppapi/shared_impl/ppb_device_ref_shared.h" |
| 50 #include "ppapi/shared_impl/ppb_input_event_shared.h" | 51 #include "ppapi/shared_impl/ppb_input_event_shared.h" |
| 51 #include "ppapi/shared_impl/ppb_network_list_private_shared.h" | 52 #include "ppapi/shared_impl/ppb_network_list_private_shared.h" |
| 52 #include "ppapi/shared_impl/ppb_view_shared.h" | 53 #include "ppapi/shared_impl/ppb_view_shared.h" |
| 53 #include "ppapi/shared_impl/ppp_flash_browser_operations_shared.h" | 54 #include "ppapi/shared_impl/ppp_flash_browser_operations_shared.h" |
| 54 #include "ppapi/shared_impl/private/ppb_host_resolver_shared.h" | 55 #include "ppapi/shared_impl/private/ppb_host_resolver_shared.h" |
| 55 #include "ppapi/shared_impl/private/ppb_x509_certificate_private_shared.h" | 56 #include "ppapi/shared_impl/private/ppb_x509_certificate_private_shared.h" |
| 56 #include "ppapi/shared_impl/url_request_info_data.h" | 57 #include "ppapi/shared_impl/url_request_info_data.h" |
| 57 | 58 |
| 58 #undef IPC_MESSAGE_EXPORT | 59 #undef IPC_MESSAGE_EXPORT |
| 59 #define IPC_MESSAGE_EXPORT PPAPI_PROXY_EXPORT | 60 #define IPC_MESSAGE_EXPORT PPAPI_PROXY_EXPORT |
| 60 | 61 |
| 61 #define IPC_MESSAGE_START PpapiMsgStart | 62 #define IPC_MESSAGE_START PpapiMsgStart |
| 62 | 63 |
| 64 IPC_ENUM_TRAITS(PP_AudioSampleRate) |
| 63 IPC_ENUM_TRAITS(PP_DeviceType_Dev) | 65 IPC_ENUM_TRAITS(PP_DeviceType_Dev) |
| 64 IPC_ENUM_TRAITS(PP_DecryptorStreamType) | 66 IPC_ENUM_TRAITS(PP_DecryptorStreamType) |
| 65 IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_Permission) | 67 IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_Permission) |
| 66 IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_SettingType) | 68 IPC_ENUM_TRAITS(PP_Flash_BrowserOperations_SettingType) |
| 67 IPC_ENUM_TRAITS(PP_FlashSetting) | 69 IPC_ENUM_TRAITS(PP_FlashSetting) |
| 68 IPC_ENUM_TRAITS(PP_InputEvent_MouseButton) | 70 IPC_ENUM_TRAITS(PP_InputEvent_MouseButton) |
| 69 IPC_ENUM_TRAITS(PP_InputEvent_Type) | 71 IPC_ENUM_TRAITS(PP_InputEvent_Type) |
| 70 IPC_ENUM_TRAITS(PP_NetAddressFamily_Private) | 72 IPC_ENUM_TRAITS(PP_NetAddressFamily_Private) |
| 71 IPC_ENUM_TRAITS(PP_NetworkListState_Private) | 73 IPC_ENUM_TRAITS(PP_NetworkListState_Private) |
| 72 IPC_ENUM_TRAITS(PP_NetworkListType_Private) | 74 IPC_ENUM_TRAITS(PP_NetworkListType_Private) |
| (...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 392 // result codes. | 394 // result codes. |
| 393 // | 395 // |
| 394 // The handler of this message should always close all of the handles passed | 396 // The handler of this message should always close all of the handles passed |
| 395 // in, since some could be valid even in the error case. | 397 // in, since some could be valid even in the error case. |
| 396 IPC_MESSAGE_ROUTED4(PpapiMsg_PPBAudio_NotifyAudioStreamCreated, | 398 IPC_MESSAGE_ROUTED4(PpapiMsg_PPBAudio_NotifyAudioStreamCreated, |
| 397 ppapi::HostResource /* audio_id */, | 399 ppapi::HostResource /* audio_id */, |
| 398 int32_t /* result_code (will be != PP_OK on failure) */, | 400 int32_t /* result_code (will be != PP_OK on failure) */, |
| 399 ppapi::proxy::SerializedHandle /* socket_handle */, | 401 ppapi::proxy::SerializedHandle /* socket_handle */, |
| 400 ppapi::proxy::SerializedHandle /* handle */) | 402 ppapi::proxy::SerializedHandle /* handle */) |
| 401 | 403 |
| 402 // PPB_AudioInput_Dev. | |
| 403 IPC_MESSAGE_ROUTED3(PpapiMsg_PPBAudioInput_EnumerateDevicesACK, | |
| 404 ppapi::HostResource /* audio_input */, | |
| 405 int32_t /* result */, | |
| 406 std::vector<ppapi::DeviceRefData> /* devices */) | |
| 407 IPC_MESSAGE_ROUTED4(PpapiMsg_PPBAudioInput_OpenACK, | |
| 408 ppapi::HostResource /* audio_input */, | |
| 409 int32_t /* result_code (will be != PP_OK on failure) */, | |
| 410 ppapi::proxy::SerializedHandle /* socket_handle */, | |
| 411 ppapi::proxy::SerializedHandle /* handle */) | |
| 412 | |
| 413 // PPB_FileIO. | 404 // PPB_FileIO. |
| 414 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBFileIO_GeneralComplete, | 405 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBFileIO_GeneralComplete, |
| 415 ppapi::HostResource /* file_io */, | 406 ppapi::HostResource /* file_io */, |
| 416 int32_t /* result */) | 407 int32_t /* result */) |
| 417 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBFileIO_OpenFileComplete, | 408 IPC_MESSAGE_ROUTED2(PpapiMsg_PPBFileIO_OpenFileComplete, |
| 418 ppapi::HostResource /* file_io */, | 409 ppapi::HostResource /* file_io */, |
| 419 int32_t /* result */) | 410 int32_t /* result */) |
| 420 IPC_MESSAGE_ROUTED3(PpapiMsg_PPBFileIO_QueryComplete, | 411 IPC_MESSAGE_ROUTED3(PpapiMsg_PPBFileIO_QueryComplete, |
| 421 ppapi::HostResource /* file_io */, | 412 ppapi::HostResource /* file_io */, |
| 422 int32_t /* result */, | 413 int32_t /* result */, |
| (...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 813 // PPB_Audio. | 804 // PPB_Audio. |
| 814 IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBAudio_Create, | 805 IPC_SYNC_MESSAGE_ROUTED3_1(PpapiHostMsg_PPBAudio_Create, |
| 815 PP_Instance /* instance_id */, | 806 PP_Instance /* instance_id */, |
| 816 int32_t /* sample_rate */, | 807 int32_t /* sample_rate */, |
| 817 uint32_t /* sample_frame_count */, | 808 uint32_t /* sample_frame_count */, |
| 818 ppapi::HostResource /* result */) | 809 ppapi::HostResource /* result */) |
| 819 IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBAudio_StartOrStop, | 810 IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBAudio_StartOrStop, |
| 820 ppapi::HostResource /* audio_id */, | 811 ppapi::HostResource /* audio_id */, |
| 821 bool /* play */) | 812 bool /* play */) |
| 822 | 813 |
| 823 // PPB_AudioInput. | |
| 824 IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBAudioInput_Create, | |
| 825 PP_Instance /* instance */, | |
| 826 ppapi::HostResource /* result */) | |
| 827 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBAudioInput_EnumerateDevices, | |
| 828 ppapi::HostResource /* audio_input */) | |
| 829 IPC_MESSAGE_ROUTED4(PpapiHostMsg_PPBAudioInput_Open, | |
| 830 ppapi::HostResource /* audio_input */, | |
| 831 std::string /* device_id */, | |
| 832 int32_t /* sample_rate */, | |
| 833 uint32_t /* sample_frame_count */) | |
| 834 IPC_MESSAGE_ROUTED2(PpapiHostMsg_PPBAudioInput_StartOrStop, | |
| 835 ppapi::HostResource /* audio_input */, | |
| 836 bool /* capture */) | |
| 837 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBAudioInput_Close, | |
| 838 ppapi::HostResource /* audio_input */) | |
| 839 | |
| 840 // PPB_Core. | 814 // PPB_Core. |
| 841 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBCore_AddRefResource, | 815 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBCore_AddRefResource, |
| 842 ppapi::HostResource) | 816 ppapi::HostResource) |
| 843 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBCore_ReleaseResource, | 817 IPC_MESSAGE_ROUTED1(PpapiHostMsg_PPBCore_ReleaseResource, |
| 844 ppapi::HostResource) | 818 ppapi::HostResource) |
| 845 | 819 |
| 846 // PPB_FileIO. | 820 // PPB_FileIO. |
| 847 IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBFileIO_Create, | 821 IPC_SYNC_MESSAGE_ROUTED1_1(PpapiHostMsg_PPBFileIO_Create, |
| 848 PP_Instance /* instance */, | 822 PP_Instance /* instance */, |
| 849 ppapi::HostResource /* result */) | 823 ppapi::HostResource /* result */) |
| (...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1608 // actual handle is passed in the ReplyParams struct. | 1582 // actual handle is passed in the ReplyParams struct. |
| 1609 IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Gamepad_SendMemory) | 1583 IPC_MESSAGE_CONTROL0(PpapiPluginMsg_Gamepad_SendMemory) |
| 1610 | 1584 |
| 1611 // Printing. | 1585 // Printing. |
| 1612 IPC_MESSAGE_CONTROL0(PpapiHostMsg_Printing_Create) | 1586 IPC_MESSAGE_CONTROL0(PpapiHostMsg_Printing_Create) |
| 1613 IPC_MESSAGE_CONTROL0(PpapiHostMsg_Printing_GetDefaultPrintSettings) | 1587 IPC_MESSAGE_CONTROL0(PpapiHostMsg_Printing_GetDefaultPrintSettings) |
| 1614 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Printing_GetDefaultPrintSettingsReply, | 1588 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Printing_GetDefaultPrintSettingsReply, |
| 1615 PP_PrintSettings_Dev /* print_settings */) | 1589 PP_PrintSettings_Dev /* print_settings */) |
| 1616 | 1590 |
| 1617 // WebSocket ------------------------------------------------------------------ | 1591 // WebSocket ------------------------------------------------------------------ |
| 1618 | |
| 1619 IPC_MESSAGE_CONTROL0(PpapiHostMsg_WebSocket_Create) | 1592 IPC_MESSAGE_CONTROL0(PpapiHostMsg_WebSocket_Create) |
| 1620 | 1593 |
| 1621 // Establishes the connection to a server. This message requires | 1594 // Establishes the connection to a server. This message requires |
| 1622 // WebSocket_ConnectReply as a reply message. | 1595 // WebSocket_ConnectReply as a reply message. |
| 1623 IPC_MESSAGE_CONTROL2(PpapiHostMsg_WebSocket_Connect, | 1596 IPC_MESSAGE_CONTROL2(PpapiHostMsg_WebSocket_Connect, |
| 1624 std::string /* url */, | 1597 std::string /* url */, |
| 1625 std::vector<std::string> /* protocols */) | 1598 std::vector<std::string> /* protocols */) |
| 1626 | 1599 |
| 1627 // Closes established connection with graceful closing handshake. This message | 1600 // Closes established connection with graceful closing handshake. This message |
| 1628 // requires WebSocket_CloseReply as a reply message. | 1601 // requires WebSocket_CloseReply as a reply message. |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1688 // Unsolicited reply message to notify that the connection is closed without | 1661 // Unsolicited reply message to notify that the connection is closed without |
| 1689 // any WebSocket_Close request. Server initiated closing handshake or | 1662 // any WebSocket_Close request. Server initiated closing handshake or |
| 1690 // unexpected network errors will invoke this message. | 1663 // unexpected network errors will invoke this message. |
| 1691 IPC_MESSAGE_CONTROL4(PpapiPluginMsg_WebSocket_ClosedReply, | 1664 IPC_MESSAGE_CONTROL4(PpapiPluginMsg_WebSocket_ClosedReply, |
| 1692 unsigned long /* buffered_amount */, | 1665 unsigned long /* buffered_amount */, |
| 1693 bool /* was_clean */, | 1666 bool /* was_clean */, |
| 1694 unsigned short /* code */, | 1667 unsigned short /* code */, |
| 1695 std::string /* reason */) | 1668 std::string /* reason */) |
| 1696 | 1669 |
| 1697 #if !defined(OS_NACL) && !defined(NACL_WIN64) | 1670 #if !defined(OS_NACL) && !defined(NACL_WIN64) |
| 1671 // Audio input. |
| 1672 IPC_MESSAGE_CONTROL0(PpapiHostMsg_AudioInput_Create) |
| 1673 IPC_MESSAGE_CONTROL0(PpapiHostMsg_AudioInput_EnumerateDevices) |
| 1674 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_AudioInput_EnumerateDevicesReply, |
| 1675 std::vector<ppapi::DeviceRefData> /* devices */) |
| 1676 IPC_MESSAGE_CONTROL3(PpapiHostMsg_AudioInput_Open, |
| 1677 std::string /* device_id */, |
| 1678 PP_AudioSampleRate /* sample_rate */, |
| 1679 uint32_t /* sample_frame_count */) |
| 1680 // Reply to an Open call. This supplies a socket handle and a shared memory |
| 1681 // handle. Both handles are passed in the ReplyParams struct. |
| 1682 IPC_MESSAGE_CONTROL0(PpapiPluginMsg_AudioInput_OpenReply) |
| 1683 IPC_MESSAGE_CONTROL1(PpapiHostMsg_AudioInput_StartOrStop, bool /* capture */) |
| 1684 IPC_MESSAGE_CONTROL0(PpapiHostMsg_AudioInput_Close) |
| 1685 |
| 1698 // Flash font file. | 1686 // Flash font file. |
| 1699 IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashFontFile_Create, | 1687 IPC_MESSAGE_CONTROL2(PpapiHostMsg_FlashFontFile_Create, |
| 1700 ppapi::proxy::SerializedFontDescription /* description */, | 1688 ppapi::proxy::SerializedFontDescription /* description */, |
| 1701 PP_PrivateFontCharset /* charset */) | 1689 PP_PrivateFontCharset /* charset */) |
| 1702 IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFontFile_GetFontTable, | 1690 IPC_MESSAGE_CONTROL1(PpapiHostMsg_FlashFontFile_GetFontTable, |
| 1703 uint32_t /* table */) | 1691 uint32_t /* table */) |
| 1704 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashFontFile_GetFontTableReply, | 1692 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_FlashFontFile_GetFontTableReply, |
| 1705 std::string /* output */) | 1693 std::string /* output */) |
| 1706 | 1694 |
| 1707 // Flash functions. | 1695 // Flash functions. |
| 1708 IPC_MESSAGE_CONTROL0(PpapiHostMsg_Flash_Create) | 1696 IPC_MESSAGE_CONTROL0(PpapiHostMsg_Flash_Create) |
| 1709 IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_EnumerateVideoCaptureDevices, | 1697 IPC_MESSAGE_CONTROL1(PpapiHostMsg_Flash_EnumerateVideoCaptureDevices, |
| 1710 ppapi::HostResource /* video_capture */) | 1698 ppapi::HostResource /* video_capture */) |
| 1711 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Flash_EnumerateVideoCaptureDevicesReply, | 1699 IPC_MESSAGE_CONTROL1(PpapiPluginMsg_Flash_EnumerateVideoCaptureDevicesReply, |
| 1712 std::vector<ppapi::DeviceRefData> /* devices */) | 1700 std::vector<ppapi::DeviceRefData> /* devices */) |
| 1713 #endif // !defined(OS_NACL) && !defined(NACL_WIN64) | 1701 #endif // !defined(OS_NACL) && !defined(NACL_WIN64) |
| OLD | NEW |