Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(117)

Unified Diff: ppapi/proxy/ppp_instance_proxy.cc

Issue 6923001: Pass fullscreen state along with DidChangeView to avoid sync messages (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: copyright Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ppapi/proxy/ppp_instance_proxy.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/ppp_instance_proxy.cc
diff --git a/ppapi/proxy/ppp_instance_proxy.cc b/ppapi/proxy/ppp_instance_proxy.cc
index 98e261532a616d7396775f6b6c441d5ae612f206..1ccc6739711eb8e835fc42672d1e0fa6f19d451d 100644
--- a/ppapi/proxy/ppp_instance_proxy.cc
+++ b/ppapi/proxy/ppp_instance_proxy.cc
@@ -6,6 +6,7 @@
#include <algorithm>
+#include "ppapi/c/dev/ppb_fullscreen_dev.h"
#include "ppapi/c/pp_var.h"
#include "ppapi/c/ppb_core.h"
#include "ppapi/c/ppp_instance.h"
@@ -46,9 +47,16 @@ void DidDestroy(PP_Instance instance) {
void DidChangeView(PP_Instance instance,
const PP_Rect* position,
const PP_Rect* clip) {
- HostDispatcher::GetForInstance(instance)->Send(
+ HostDispatcher* dispatcher = HostDispatcher::GetForInstance(instance);
+ const PPB_Fullscreen_Dev* fullscreen_interface =
+ static_cast<const PPB_Fullscreen_Dev*>(
+ dispatcher->GetLocalInterface(PPB_FULLSCREEN_DEV_INTERFACE));
+ DCHECK(fullscreen_interface);
+ PP_Bool fullscreen = fullscreen_interface->IsFullscreen(instance);
+ dispatcher->Send(
new PpapiMsg_PPPInstance_DidChangeView(INTERFACE_ID_PPP_INSTANCE,
- instance, *position, *clip));
+ instance, *position, *clip,
+ fullscreen));
}
void DidChangeFocus(PP_Instance instance, PP_Bool has_focus) {
@@ -211,7 +219,8 @@ void PPP_Instance_Proxy::OnMsgDidDestroy(PP_Instance instance) {
void PPP_Instance_Proxy::OnMsgDidChangeView(PP_Instance instance,
const PP_Rect& position,
- const PP_Rect& clip) {
+ const PP_Rect& clip,
+ PP_Bool fullscreen) {
PluginDispatcher* dispatcher = PluginDispatcher::GetForInstance(instance);
if (!dispatcher)
return;
@@ -219,6 +228,7 @@ void PPP_Instance_Proxy::OnMsgDidChangeView(PP_Instance instance,
if (!data)
return;
data->position = position;
+ data->fullscreen = fullscreen;
ppp_instance_target()->DidChangeView(instance, &position, &clip);
}
« no previous file with comments | « ppapi/proxy/ppp_instance_proxy.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698