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/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 | 44 |
45 BrowserPlugin::BrowserPlugin(RenderViewImpl* render_view, | 45 BrowserPlugin::BrowserPlugin(RenderViewImpl* render_view, |
46 blink::WebFrame* frame, | 46 blink::WebFrame* frame, |
47 bool auto_navigate) | 47 bool auto_navigate) |
48 : guest_instance_id_(browser_plugin::kInstanceIDNone), | 48 : guest_instance_id_(browser_plugin::kInstanceIDNone), |
49 attached_(false), | 49 attached_(false), |
50 render_view_(render_view->AsWeakPtr()), | 50 render_view_(render_view->AsWeakPtr()), |
51 render_view_routing_id_(render_view->GetRoutingID()), | 51 render_view_routing_id_(render_view->GetRoutingID()), |
52 container_(NULL), | 52 container_(NULL), |
53 paint_ack_received_(true), | 53 paint_ack_received_(true), |
54 last_device_scale_factor_(1.0f), | 54 last_device_scale_factor_(GetDeviceScaleFactor()), |
55 sad_guest_(NULL), | 55 sad_guest_(NULL), |
56 guest_crashed_(false), | 56 guest_crashed_(false), |
57 is_auto_size_state_dirty_(false), | 57 is_auto_size_state_dirty_(false), |
58 content_window_routing_id_(MSG_ROUTING_NONE), | 58 content_window_routing_id_(MSG_ROUTING_NONE), |
59 plugin_focused_(false), | 59 plugin_focused_(false), |
60 visible_(true), | 60 visible_(true), |
61 auto_navigate_(auto_navigate), | 61 auto_navigate_(auto_navigate), |
62 mouse_locked_(false), | 62 mouse_locked_(false), |
63 browser_plugin_manager_(render_view->GetBrowserPluginManager()), | 63 browser_plugin_manager_(render_view->GetBrowserPluginManager()), |
64 embedder_frame_url_(frame->document().url()), | 64 embedder_frame_url_(frame->document().url()), |
(...skipping 888 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
953 const blink::WebMouseEvent& event) { | 953 const blink::WebMouseEvent& event) { |
954 browser_plugin_manager()->Send( | 954 browser_plugin_manager()->Send( |
955 new BrowserPluginHostMsg_HandleInputEvent(render_view_routing_id_, | 955 new BrowserPluginHostMsg_HandleInputEvent(render_view_routing_id_, |
956 guest_instance_id_, | 956 guest_instance_id_, |
957 plugin_rect_, | 957 plugin_rect_, |
958 &event)); | 958 &event)); |
959 return true; | 959 return true; |
960 } | 960 } |
961 | 961 |
962 } // namespace content | 962 } // namespace content |
OLD | NEW |