Index: ppapi/proxy/ppb_instance_proxy.cc |
=================================================================== |
--- ppapi/proxy/ppb_instance_proxy.cc (revision 102885) |
+++ ppapi/proxy/ppb_instance_proxy.cc (working copy) |
@@ -87,6 +87,10 @@ |
OnMsgFlashSetFullscreen) |
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_FlashGetScreenSize, |
OnMsgFlashGetScreenSize) |
+ IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_SetFullscreen, |
+ OnMsgSetFullscreen) |
+ IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_GetScreenSize, |
+ OnMsgGetScreenSize) |
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_RequestInputEvents, |
OnMsgRequestInputEvents) |
IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBInstance_ClearInputEvents, |
@@ -181,7 +185,7 @@ |
NOTIMPLEMENTED(); // Not proxied yet. |
} |
-PP_Bool PPB_Instance_Proxy::FlashIsFullscreen(PP_Instance instance) { |
+PP_Bool PPB_Instance_Proxy::IsFullscreen(PP_Instance instance) { |
InstanceData* data = static_cast<PluginDispatcher*>(dispatcher())-> |
GetInstanceData(instance); |
if (!data) |
@@ -189,6 +193,22 @@ |
return data->fullscreen; |
} |
+PP_Bool PPB_Instance_Proxy::FlashIsFullscreen(PP_Instance instance) { |
+ InstanceData* data = static_cast<PluginDispatcher*>(dispatcher())-> |
+ GetInstanceData(instance); |
+ if (!data) |
+ return PP_FALSE; |
+ return data->flash_fullscreen; |
+} |
+ |
+PP_Bool PPB_Instance_Proxy::SetFullscreen(PP_Instance instance, |
+ PP_Bool fullscreen) { |
+ PP_Bool result = PP_FALSE; |
+ dispatcher()->Send(new PpapiHostMsg_PPBInstance_SetFullscreen( |
+ INTERFACE_ID_PPB_INSTANCE, instance, fullscreen, &result)); |
+ return result; |
+} |
+ |
PP_Bool PPB_Instance_Proxy::FlashSetFullscreen(PP_Instance instance, |
PP_Bool fullscreen) { |
PP_Bool result = PP_FALSE; |
@@ -197,6 +217,14 @@ |
return result; |
} |
+PP_Bool PPB_Instance_Proxy::GetScreenSize(PP_Instance instance, |
+ PP_Size* size) { |
+ PP_Bool result = PP_FALSE; |
+ dispatcher()->Send(new PpapiHostMsg_PPBInstance_GetScreenSize( |
+ INTERFACE_ID_PPB_INSTANCE, instance, &result, size)); |
+ return result; |
+} |
+ |
PP_Bool PPB_Instance_Proxy::FlashGetScreenSize(PP_Instance instance, |
PP_Size* size) { |
PP_Bool result = PP_FALSE; |
@@ -349,18 +377,35 @@ |
} |
} |
+void PPB_Instance_Proxy::OnMsgSetFullscreen(PP_Instance instance, |
+ PP_Bool fullscreen, |
+ PP_Bool* result) { |
+ EnterInstanceNoLock enter(instance, false); |
+ if (enter.succeeded()) |
+ *result = enter.functions()->SetFullscreen(instance, fullscreen); |
+} |
+ |
+ |
void PPB_Instance_Proxy::OnMsgFlashSetFullscreen(PP_Instance instance, |
PP_Bool fullscreen, |
PP_Bool* result) { |
- EnterInstanceNoLock enter(instance, false); |
+ EnterFunctionNoLock<PPB_Instance_FunctionAPI> enter(instance, false); |
if (enter.succeeded()) |
*result = enter.functions()->FlashSetFullscreen(instance, fullscreen); |
} |
+void PPB_Instance_Proxy::OnMsgGetScreenSize(PP_Instance instance, |
+ PP_Bool* result, |
+ PP_Size* size) { |
+ EnterInstanceNoLock enter(instance, false); |
+ if (enter.succeeded()) |
+ *result = enter.functions()->GetScreenSize(instance, size); |
+} |
+ |
void PPB_Instance_Proxy::OnMsgFlashGetScreenSize(PP_Instance instance, |
PP_Bool* result, |
PP_Size* size) { |
- EnterInstanceNoLock enter(instance, false); |
+ EnterFunctionNoLock<PPB_Instance_FunctionAPI> enter(instance, false); |
if (enter.succeeded()) |
*result = enter.functions()->FlashGetScreenSize(instance, size); |
} |