Index: ppapi/proxy/ppb_instance_proxy.cc |
=================================================================== |
--- ppapi/proxy/ppb_instance_proxy.cc (revision 120806) |
+++ ppapi/proxy/ppb_instance_proxy.cc (working copy) |
@@ -6,6 +6,7 @@ |
#include "ppapi/c/pp_errors.h" |
#include "ppapi/c/pp_var.h" |
+#include "ppapi/c/ppb_audio_config.h" |
#include "ppapi/c/ppb_instance.h" |
#include "ppapi/c/ppb_messaging.h" |
#include "ppapi/c/ppb_mouse_lock.h" |
@@ -80,6 +81,10 @@ |
OnHostMsgBindGraphics) |
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_IsFullFrame, |
OnHostMsgIsFullFrame) |
+ IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_AudioHardwareOutputSampleRate, |
+ OnHostMsgAudioHardwareOutputSampleRate) |
+ IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_AudioHardwareOutputBufferSize, |
+ OnHostMsgAudioHardwareOutputBufferSize) |
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_ExecuteScript, |
OnHostMsgExecuteScript) |
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_GetDefaultCharSet, |
@@ -183,6 +188,22 @@ |
return result.Return(dispatcher()); |
} |
+uint32_t PPB_Instance_Proxy:: |
brettw
2012/02/10 19:01:33
Style: Don't wrap after the :: if you don't need t
nfullagar
2012/02/14 00:42:37
Done.
|
+ AudioHardwareOutputSampleRate(PP_Instance instance) { |
+ uint32_t result = PP_AUDIOSAMPLERATE_NONE; |
+ dispatcher()->Send(new PpapiHostMsg_PPBInstance_AudioHardwareOutputSampleRate( |
brettw
2012/02/10 19:01:33
Can the messages and handlers be made to match the
nfullagar
2012/02/14 00:42:37
Changed to GetAudio... (as you suggested in a late
|
+ API_ID_PPB_INSTANCE, instance, &result)); |
+ return result; |
+} |
+ |
+uint32_t PPB_Instance_Proxy:: |
+ AudioHardwareOutputBufferSize(PP_Instance instance) { |
+ uint32_t result = 0; |
+ dispatcher()->Send(new PpapiHostMsg_PPBInstance_AudioHardwareOutputBufferSize( |
+ API_ID_PPB_INSTANCE, instance, &result)); |
+ return result; |
+} |
+ |
PP_Var PPB_Instance_Proxy::GetDefaultCharSet(PP_Instance instance) { |
PluginDispatcher* dispatcher = PluginDispatcher::GetForInstance(instance); |
if (!dispatcher) |
@@ -404,6 +425,20 @@ |
} |
} |
+void PPB_Instance_Proxy::OnHostMsgAudioHardwareOutputSampleRate( |
+ PP_Instance instance, uint32_t* result) { |
+ EnterInstanceNoLock enter(instance, false); |
+ if (enter.succeeded()) |
+ *result = enter.functions()->AudioHardwareOutputSampleRate(instance); |
+} |
+ |
+void PPB_Instance_Proxy::OnHostMsgAudioHardwareOutputBufferSize( |
+ PP_Instance instance, uint32_t* result) { |
+ EnterInstanceNoLock enter(instance, false); |
+ if (enter.succeeded()) |
+ *result = enter.functions()->AudioHardwareOutputBufferSize(instance); |
+} |
+ |
void PPB_Instance_Proxy::OnHostMsgIsFullFrame(PP_Instance instance, |
PP_Bool* result) { |
EnterInstanceNoLock enter(instance, false); |