diff options
author | nfullagar@google.com <nfullagar@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-09-20 23:38:29 +0000 |
---|---|---|
committer | nfullagar@google.com <nfullagar@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-09-20 23:38:29 +0000 |
commit | 4310fd886526c35cc3a471b838087d871703c656 (patch) | |
tree | 4ff20e148c2e38c37f72382c9b056f80716762e8 | |
parent | 7bc56fa9dbcbae3476312045db95b170ab3f1d77 (diff) | |
download | chromium_src-4310fd886526c35cc3a471b838087d871703c656.zip chromium_src-4310fd886526c35cc3a471b838087d871703c656.tar.gz chromium_src-4310fd886526c35cc3a471b838087d871703c656.tar.bz2 |
Changes to allow testing interface for new NaCl Proxy
BUG=none
TEST=ppapi/tests
Review URL: https://chromiumcodereview.appspot.com/10918083
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@157871 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | ppapi/ppapi_proxy.gypi | 1 | ||||
-rw-r--r-- | ppapi/proxy/interface_list.cc | 2 | ||||
-rw-r--r-- | ppapi/proxy/ppb_audio_proxy.cc | 7 | ||||
-rw-r--r-- | ppapi/proxy/ppb_testing_proxy.cc | 6 |
4 files changed, 14 insertions, 2 deletions
diff --git a/ppapi/ppapi_proxy.gypi b/ppapi/ppapi_proxy.gypi index 9f7ef25..56dbb8c 100644 --- a/ppapi/ppapi_proxy.gypi +++ b/ppapi/ppapi_proxy.gypi @@ -177,7 +177,6 @@ 'proxy/ppb_flash_message_loop_proxy.cc', 'proxy/ppb_pdf_proxy.cc', 'proxy/ppb_talk_private_proxy.cc', - 'proxy/ppb_testing_proxy.cc', 'proxy/ppb_video_capture_proxy.cc', 'proxy/ppb_video_decoder_proxy.cc', 'proxy/ppp_content_decryptor_private_proxy.cc', diff --git a/ppapi/proxy/interface_list.cc b/ppapi/proxy/interface_list.cc index d77c1cb..99b846f 100644 --- a/ppapi/proxy/interface_list.cc +++ b/ppapi/proxy/interface_list.cc @@ -229,7 +229,6 @@ InterfaceList::InterfaceList() { // TODO(brettw) remove these. AddPPB(PPB_Instance_Proxy::GetInfoPrivate()); AddPPB(PPB_PDF_Proxy::GetInfo()); - AddPPB(PPB_Testing_Proxy::GetInfo()); AddPPB(PPB_URLLoader_Proxy::GetTrustedInfo()); AddPPB(PPB_Var_Deprecated_Proxy::GetInfo()); @@ -241,6 +240,7 @@ InterfaceList::InterfaceList() { API_ID_PPP_CONTENT_DECRYPTOR_PRIVATE, PPP_ContentDecryptor_Private_Proxy::GetProxyInterface()); #endif + AddPPB(PPB_Testing_Proxy::GetInfo()); // PPP (plugin) interfaces. // TODO(brettw) move these to interface_list*.h diff --git a/ppapi/proxy/ppb_audio_proxy.cc b/ppapi/proxy/ppb_audio_proxy.cc index 2f91fc7..5a6b43a 100644 --- a/ppapi/proxy/ppb_audio_proxy.cc +++ b/ppapi/proxy/ppb_audio_proxy.cc @@ -74,6 +74,13 @@ Audio::Audio(const HostResource& audio_id, } Audio::~Audio() { +#if defined(OS_NACL) + // Invoke StopPlayback() to ensure audio back-end has a chance to send the + // escape value over the sync socket, which will terminate the client side + // audio callback loop. This is required for NaCl Plugins that can't escape + // by shutting down the sync_socket. + StopPlayback(); +#endif PpapiGlobals::Get()->GetResourceTracker()->ReleaseResource(config_); } diff --git a/ppapi/proxy/ppb_testing_proxy.cc b/ppapi/proxy/ppb_testing_proxy.cc index b8c9ce0..da2475a 100644 --- a/ppapi/proxy/ppb_testing_proxy.cc +++ b/ppapi/proxy/ppb_testing_proxy.cc @@ -93,10 +93,16 @@ void SimulateInputEvent(PP_Instance instance_id, PP_Resource input_event) { } PP_Var GetDocumentURL(PP_Instance instance, PP_URLComponents_Dev* components) { +#if !defined(OS_NACL) EnterInstance enter(instance); if (enter.failed()) return PP_MakeUndefined(); return enter.functions()->GetDocumentURL(instance, components); +#else + // TODO(nfullagar): Implement something better for the new NaCl IPC plugin. + // For now, this will at least allow some of the PPAPI tests to work. + return PP_MakeUndefined(); +#endif } // TODO(dmichael): Ideally we could get a way to check the number of vars in the |