summaryrefslogtreecommitdiffstats
path: root/content/browser/browser_plugin/browser_plugin_guest.cc
diff options
context:
space:
mode:
authorkenrb@chromium.org <kenrb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-01-03 22:21:55 +0000
committerkenrb@chromium.org <kenrb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-01-03 22:21:55 +0000
commit95d3182359968c2ede57e70e05b80d93ccdf2bf5 (patch)
tree896a720387bb30a39756d151575049a13a8e652a /content/browser/browser_plugin/browser_plugin_guest.cc
parent9e9ae7296cfed7bfc612b0e3eeef7ad0c936b1ba (diff)
downloadchromium_src-95d3182359968c2ede57e70e05b80d93ccdf2bf5.zip
chromium_src-95d3182359968c2ede57e70e05b80d93ccdf2bf5.tar.gz
chromium_src-95d3182359968c2ede57e70e05b80d93ccdf2bf5.tar.bz2
Adding RenderWidgetHostViewChildFrame for OOPIF view.
RenderWidgetHostViewChildFrame becomes the view class for child frames being rendered in a different process from their parent. CrossProcessFrameConnector is a supporting class for that, encapsulating state specific to the parent/child frame relationship. RenderWidgetHostViewGuest is made a subclass of RenderWidgetHostViewChildFrame in order to keep them synchronized. Gradually we will move all functionality from RWHVGuest to RWHVChildFrame and then get rid of RWHVGuest altogether. TBR=sadrul BUG=325803 Review URL: https://codereview.chromium.org/100473010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242942 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/browser_plugin/browser_plugin_guest.cc')
-rw-r--r--content/browser/browser_plugin/browser_plugin_guest.cc32
1 files changed, 14 insertions, 18 deletions
diff --git a/content/browser/browser_plugin/browser_plugin_guest.cc b/content/browser/browser_plugin/browser_plugin_guest.cc
index 0e6ba06..716c2b7 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.cc
+++ b/content/browser/browser_plugin/browser_plugin_guest.cc
@@ -507,8 +507,8 @@ bool BrowserPluginGuest::OnMessageReceivedFromEmbedder(
IPC_BEGIN_MESSAGE_MAP(BrowserPluginGuest, message)
IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_BuffersSwappedACK,
OnSwapBuffersACK)
- IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_CompositorFrameACK,
- OnCompositorFrameACK)
+ IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_CompositorFrameSwappedACK,
+ OnCompositorFrameSwappedACK)
IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_CopyFromCompositingSurfaceAck,
OnCopyFromCompositingSurfaceAck)
IPC_MESSAGE_HANDLER(BrowserPluginHostMsg_DragStatusUpdate,
@@ -1142,7 +1142,7 @@ bool BrowserPluginGuest::ShouldForwardToBrowserPluginGuest(
const IPC::Message& message) {
switch (message.type()) {
case BrowserPluginHostMsg_BuffersSwappedACK::ID:
- case BrowserPluginHostMsg_CompositorFrameACK::ID:
+ case BrowserPluginHostMsg_CompositorFrameSwappedACK::ID:
case BrowserPluginHostMsg_CopyFromCompositingSurfaceAck::ID:
case BrowserPluginHostMsg_DragStatusUpdate::ID:
case BrowserPluginHostMsg_ExecuteEditCommand::ID:
@@ -1256,16 +1256,13 @@ void BrowserPluginGuest::Attach(
RecordAction(UserMetricsAction("BrowserPlugin.Guest.Attached"));
}
-void BrowserPluginGuest::OnCompositorFrameACK(
+void BrowserPluginGuest::OnCompositorFrameSwappedACK(
int instance_id,
- int route_id,
- uint32 output_surface_id,
- int renderer_host_id,
- const cc::CompositorFrameAck& ack) {
- RenderWidgetHostImpl::SendSwapCompositorFrameAck(route_id,
- output_surface_id,
- renderer_host_id,
- ack);
+ const FrameHostMsg_CompositorFrameSwappedACK_Params& params) {
+ RenderWidgetHostImpl::SendSwapCompositorFrameAck(params.producing_route_id,
+ params.output_surface_id,
+ params.producing_host_id,
+ params.ack);
}
void BrowserPluginGuest::OnDragStatusUpdate(int instance_id,
@@ -1575,12 +1572,11 @@ void BrowserPluginGuest::OnSetVisibility(int instance_id, bool visible) {
GetWebContents()->WasHidden();
}
-void BrowserPluginGuest::OnSwapBuffersACK(int instance_id,
- int route_id,
- int gpu_host_id,
- const std::string& mailbox_name,
- uint32 sync_point) {
- AcknowledgeBufferPresent(route_id, gpu_host_id, mailbox_name, sync_point);
+void BrowserPluginGuest::OnSwapBuffersACK(
+ int instance_id,
+ const FrameHostMsg_BuffersSwappedACK_Params& params) {
+ AcknowledgeBufferPresent(params.gpu_route_id, params.gpu_host_id,
+ params.mailbox_name, params.sync_point);
// This is only relevant on MACOSX and WIN when threaded compositing
// is not enabled. In threaded mode, above ACK is sufficient.