OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/browser/frame_host/render_frame_host_impl.h" | 5 #include "content/browser/frame_host/render_frame_host_impl.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/containers/hash_tables.h" | 9 #include "base/containers/hash_tables.h" |
10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
(...skipping 22 matching lines...) Expand all Loading... |
33 #include "content/browser/renderer_host/render_widget_host_impl.h" | 33 #include "content/browser/renderer_host/render_widget_host_impl.h" |
34 #include "content/browser/renderer_host/render_widget_host_view_base.h" | 34 #include "content/browser/renderer_host/render_widget_host_view_base.h" |
35 #include "content/browser/transition_request_manager.h" | 35 #include "content/browser/transition_request_manager.h" |
36 #include "content/common/accessibility_messages.h" | 36 #include "content/common/accessibility_messages.h" |
37 #include "content/common/desktop_notification_messages.h" | 37 #include "content/common/desktop_notification_messages.h" |
38 #include "content/common/frame_messages.h" | 38 #include "content/common/frame_messages.h" |
39 #include "content/common/input_messages.h" | 39 #include "content/common/input_messages.h" |
40 #include "content/common/inter_process_time_ticks_converter.h" | 40 #include "content/common/inter_process_time_ticks_converter.h" |
41 #include "content/common/navigation_params.h" | 41 #include "content/common/navigation_params.h" |
42 #include "content/common/platform_notification_messages.h" | 42 #include "content/common/platform_notification_messages.h" |
43 #include "content/common/render_frame_setup.mojom.h" | |
44 #include "content/common/swapped_out_messages.h" | 43 #include "content/common/swapped_out_messages.h" |
45 #include "content/public/browser/ax_event_notification_details.h" | 44 #include "content/public/browser/ax_event_notification_details.h" |
46 #include "content/public/browser/browser_accessibility_state.h" | 45 #include "content/public/browser/browser_accessibility_state.h" |
47 #include "content/public/browser/browser_context.h" | 46 #include "content/public/browser/browser_context.h" |
48 #include "content/public/browser/browser_plugin_guest_manager.h" | 47 #include "content/public/browser/browser_plugin_guest_manager.h" |
49 #include "content/public/browser/browser_thread.h" | 48 #include "content/public/browser/browser_thread.h" |
50 #include "content/public/browser/content_browser_client.h" | 49 #include "content/public/browser/content_browser_client.h" |
51 #include "content/public/browser/desktop_notification_delegate.h" | 50 #include "content/public/browser/desktop_notification_delegate.h" |
52 #include "content/public/browser/render_process_host.h" | 51 #include "content/public/browser/render_process_host.h" |
53 #include "content/public/browser/render_widget_host_view.h" | 52 #include "content/public/browser/render_widget_host_view.h" |
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
197 this)); | 196 this)); |
198 | 197 |
199 if (is_swapped_out) { | 198 if (is_swapped_out) { |
200 rfh_state_ = STATE_SWAPPED_OUT; | 199 rfh_state_ = STATE_SWAPPED_OUT; |
201 } else { | 200 } else { |
202 rfh_state_ = STATE_DEFAULT; | 201 rfh_state_ = STATE_DEFAULT; |
203 GetSiteInstance()->increment_active_frame_count(); | 202 GetSiteInstance()->increment_active_frame_count(); |
204 } | 203 } |
205 | 204 |
206 if (GetProcess()->GetServiceRegistry()) { | 205 if (GetProcess()->GetServiceRegistry()) { |
207 RenderFrameSetupPtr setup; | 206 GetProcess()->GetServiceRegistry()->ConnectToRemoteService( |
208 GetProcess()->GetServiceRegistry()->ConnectToRemoteService(&setup); | 207 &render_frame_setup_); |
209 mojo::ServiceProviderPtr service_provider; | 208 mojo::ServiceProviderPtr service_provider; |
210 setup->GetServiceProviderForFrame(routing_id_, | 209 render_frame_setup_->GetServiceProviderForFrame( |
211 mojo::GetProxy(&service_provider)); | 210 routing_id_, mojo::GetProxy(&service_provider)); |
212 service_registry_.BindRemoteServiceProvider( | 211 service_registry_.BindRemoteServiceProvider( |
213 service_provider.PassMessagePipe()); | 212 service_provider.PassMessagePipe()); |
214 | 213 |
215 #if defined(OS_ANDROID) | 214 #if defined(OS_ANDROID) |
216 service_registry_android_.reset( | 215 service_registry_android_.reset( |
217 new ServiceRegistryAndroid(&service_registry_)); | 216 new ServiceRegistryAndroid(&service_registry_)); |
218 #endif | 217 #endif |
219 } | 218 } |
220 | 219 |
221 swapout_event_monitor_timeout_.reset(new TimeoutMonitor(base::Bind( | 220 swapout_event_monitor_timeout_.reset(new TimeoutMonitor(base::Bind( |
(...skipping 1342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1564 // Clear any state if a pending navigation is canceled or preempted. | 1563 // Clear any state if a pending navigation is canceled or preempted. |
1565 if (suspended_nav_params_) | 1564 if (suspended_nav_params_) |
1566 suspended_nav_params_.reset(); | 1565 suspended_nav_params_.reset(); |
1567 | 1566 |
1568 TRACE_EVENT_ASYNC_END0("navigation", | 1567 TRACE_EVENT_ASYNC_END0("navigation", |
1569 "RenderFrameHostImpl navigation suspended", this); | 1568 "RenderFrameHostImpl navigation suspended", this); |
1570 navigations_suspended_ = false; | 1569 navigations_suspended_ = false; |
1571 } | 1570 } |
1572 | 1571 |
1573 } // namespace content | 1572 } // namespace content |
OLD | NEW |