Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "base/bind_helpers.h" | 5 #include "base/bind_helpers.h" |
| 6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
| 9 #include "content/browser/browser_plugin/browser_plugin_guest.h" | 9 #include "content/browser/browser_plugin/browser_plugin_guest.h" |
| 10 #include "content/browser/renderer_host/render_view_host_impl.h" | 10 #include "content/browser/renderer_host/render_view_host_impl.h" |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 161 // If accelerated surface buffers are getting swapped then we're not using | 161 // If accelerated surface buffers are getting swapped then we're not using |
| 162 // the software path. | 162 // the software path. |
| 163 guest_->clear_damage_buffer(); | 163 guest_->clear_damage_buffer(); |
| 164 guest_->SendMessageToEmbedder( | 164 guest_->SendMessageToEmbedder( |
| 165 new BrowserPluginMsg_BuffersSwapped( | 165 new BrowserPluginMsg_BuffersSwapped( |
| 166 guest_->instance_id(), | 166 guest_->instance_id(), |
| 167 params.size, | 167 params.size, |
| 168 params.mailbox_name, | 168 params.mailbox_name, |
| 169 params.route_id, | 169 params.route_id, |
| 170 gpu_host_id)); | 170 gpu_host_id)); |
| 171 DidReceiveRendererFrame(); | |
|
piman
2013/07/02 01:49:09
I suspect it's also needed in DidUpdateBackingStor
danakj
2013/07/03 18:05:39
The function is empty except for NOTREACHED() so I
| |
| 171 } | 172 } |
| 172 | 173 |
| 173 void RenderWidgetHostViewGuest::AcceleratedSurfacePostSubBuffer( | 174 void RenderWidgetHostViewGuest::AcceleratedSurfacePostSubBuffer( |
| 174 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, | 175 const GpuHostMsg_AcceleratedSurfacePostSubBuffer_Params& params, |
| 175 int gpu_host_id) { | 176 int gpu_host_id) { |
| 176 NOTREACHED(); | 177 NOTREACHED(); |
| 177 } | 178 } |
| 178 | 179 |
| 179 void RenderWidgetHostViewGuest::OnSwapCompositorFrame( | 180 void RenderWidgetHostViewGuest::OnSwapCompositorFrame( |
| 180 scoped_ptr<cc::CompositorFrame> frame) { | 181 scoped_ptr<cc::CompositorFrame> frame) { |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 195 shared_memory.GiveToProcess(embedder_pid, &frame_data->handle); | 196 shared_memory.GiveToProcess(embedder_pid, &frame_data->handle); |
| 196 } | 197 } |
| 197 | 198 |
| 198 guest_->clear_damage_buffer(); | 199 guest_->clear_damage_buffer(); |
| 199 guest_->SendMessageToEmbedder( | 200 guest_->SendMessageToEmbedder( |
| 200 new BrowserPluginMsg_CompositorFrameSwapped( | 201 new BrowserPluginMsg_CompositorFrameSwapped( |
| 201 guest_->instance_id(), | 202 guest_->instance_id(), |
| 202 *frame, | 203 *frame, |
| 203 host_->GetRoutingID(), | 204 host_->GetRoutingID(), |
| 204 host_->GetProcess()->GetID())); | 205 host_->GetProcess()->GetID())); |
| 206 DidReceiveRendererFrame(); | |
| 205 } | 207 } |
| 206 | 208 |
| 207 void RenderWidgetHostViewGuest::SetBounds(const gfx::Rect& rect) { | 209 void RenderWidgetHostViewGuest::SetBounds(const gfx::Rect& rect) { |
| 208 SetSize(rect.size()); | 210 SetSize(rect.size()); |
| 209 } | 211 } |
| 210 | 212 |
| 211 bool RenderWidgetHostViewGuest::OnMessageReceived(const IPC::Message& msg) { | 213 bool RenderWidgetHostViewGuest::OnMessageReceived(const IPC::Message& msg) { |
| 212 return platform_view_->OnMessageReceived(msg); | 214 return platform_view_->OnMessageReceived(msg); |
| 213 } | 215 } |
| 214 | 216 |
| (...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 534 return; | 536 return; |
| 535 for (ui::GestureRecognizer::Gestures::iterator g_it = gestures->begin(); | 537 for (ui::GestureRecognizer::Gestures::iterator g_it = gestures->begin(); |
| 536 g_it != gestures->end(); | 538 g_it != gestures->end(); |
| 537 ++g_it) { | 539 ++g_it) { |
| 538 ForwardGestureEventToRenderer(*g_it); | 540 ForwardGestureEventToRenderer(*g_it); |
| 539 } | 541 } |
| 540 } | 542 } |
| 541 | 543 |
| 542 | 544 |
| 543 } // namespace content | 545 } // namespace content |
| OLD | NEW |