| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "content/renderer/browser_plugin/browser_plugin.h" | 5 #include "content/renderer/browser_plugin/browser_plugin.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/json/json_string_value_serializer.h" | 8 #include "base/json/json_string_value_serializer.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/strings/string_number_conversions.h" | 10 #include "base/strings/string_number_conversions.h" |
| (...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 430 } | 430 } |
| 431 attached_ = true; | 431 attached_ = true; |
| 432 } | 432 } |
| 433 | 433 |
| 434 void BrowserPlugin::OnBuffersSwapped( | 434 void BrowserPlugin::OnBuffersSwapped( |
| 435 int instance_id, | 435 int instance_id, |
| 436 const FrameMsg_BuffersSwapped_Params& params) { | 436 const FrameMsg_BuffersSwapped_Params& params) { |
| 437 EnableCompositing(true); | 437 EnableCompositing(true); |
| 438 | 438 |
| 439 compositing_helper_->OnBuffersSwapped(params.size, | 439 compositing_helper_->OnBuffersSwapped(params.size, |
| 440 params.mailbox, | 440 params.mailbox_name, |
| 441 params.gpu_route_id, | 441 params.gpu_route_id, |
| 442 params.gpu_host_id, | 442 params.gpu_host_id, |
| 443 GetDeviceScaleFactor()); | 443 GetDeviceScaleFactor()); |
| 444 } | 444 } |
| 445 | 445 |
| 446 void BrowserPlugin::OnCompositorFrameSwapped(const IPC::Message& message) { | 446 void BrowserPlugin::OnCompositorFrameSwapped(const IPC::Message& message) { |
| 447 BrowserPluginMsg_CompositorFrameSwapped::Param param; | 447 BrowserPluginMsg_CompositorFrameSwapped::Param param; |
| 448 if (!BrowserPluginMsg_CompositorFrameSwapped::Read(&message, ¶m)) | 448 if (!BrowserPluginMsg_CompositorFrameSwapped::Read(&message, ¶m)) |
| 449 return; | 449 return; |
| 450 scoped_ptr<cc::CompositorFrame> frame(new cc::CompositorFrame); | 450 scoped_ptr<cc::CompositorFrame> frame(new cc::CompositorFrame); |
| (...skipping 948 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1399 const blink::WebMouseEvent& event) { | 1399 const blink::WebMouseEvent& event) { |
| 1400 browser_plugin_manager()->Send( | 1400 browser_plugin_manager()->Send( |
| 1401 new BrowserPluginHostMsg_HandleInputEvent(render_view_routing_id_, | 1401 new BrowserPluginHostMsg_HandleInputEvent(render_view_routing_id_, |
| 1402 guest_instance_id_, | 1402 guest_instance_id_, |
| 1403 plugin_rect_, | 1403 plugin_rect_, |
| 1404 &event)); | 1404 &event)); |
| 1405 return true; | 1405 return true; |
| 1406 } | 1406 } |
| 1407 | 1407 |
| 1408 } // namespace content | 1408 } // namespace content |
| OLD | NEW |