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 <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/containers/hash_tables.h" | 10 #include "base/containers/hash_tables.h" |
(...skipping 16 matching lines...) Expand all Loading... |
27 #include "content/browser/frame_host/frame_tree.h" | 27 #include "content/browser/frame_host/frame_tree.h" |
28 #include "content/browser/frame_host/frame_tree_node.h" | 28 #include "content/browser/frame_host/frame_tree_node.h" |
29 #include "content/browser/frame_host/navigation_handle_impl.h" | 29 #include "content/browser/frame_host/navigation_handle_impl.h" |
30 #include "content/browser/frame_host/navigation_request.h" | 30 #include "content/browser/frame_host/navigation_request.h" |
31 #include "content/browser/frame_host/navigator.h" | 31 #include "content/browser/frame_host/navigator.h" |
32 #include "content/browser/frame_host/navigator_impl.h" | 32 #include "content/browser/frame_host/navigator_impl.h" |
33 #include "content/browser/frame_host/render_frame_host_delegate.h" | 33 #include "content/browser/frame_host/render_frame_host_delegate.h" |
34 #include "content/browser/frame_host/render_frame_proxy_host.h" | 34 #include "content/browser/frame_host/render_frame_proxy_host.h" |
35 #include "content/browser/frame_host/render_widget_host_view_child_frame.h" | 35 #include "content/browser/frame_host/render_widget_host_view_child_frame.h" |
36 #include "content/browser/geolocation/geolocation_service_context.h" | 36 #include "content/browser/geolocation/geolocation_service_context.h" |
| 37 #include "content/browser/loader/resource_dispatcher_host_impl.h" |
37 #include "content/browser/permissions/permission_service_context.h" | 38 #include "content/browser/permissions/permission_service_context.h" |
38 #include "content/browser/permissions/permission_service_impl.h" | 39 #include "content/browser/permissions/permission_service_impl.h" |
39 #include "content/browser/presentation/presentation_service_impl.h" | 40 #include "content/browser/presentation/presentation_service_impl.h" |
40 #include "content/browser/renderer_host/input/input_router.h" | 41 #include "content/browser/renderer_host/input/input_router.h" |
41 #include "content/browser/renderer_host/input/timeout_monitor.h" | 42 #include "content/browser/renderer_host/input/timeout_monitor.h" |
42 #include "content/browser/renderer_host/render_process_host_impl.h" | 43 #include "content/browser/renderer_host/render_process_host_impl.h" |
43 #include "content/browser/renderer_host/render_view_host_delegate.h" | 44 #include "content/browser/renderer_host/render_view_host_delegate.h" |
44 #include "content/browser/renderer_host/render_view_host_delegate_view.h" | 45 #include "content/browser/renderer_host/render_view_host_delegate_view.h" |
45 #include "content/browser/renderer_host/render_view_host_impl.h" | 46 #include "content/browser/renderer_host/render_view_host_impl.h" |
46 #include "content/browser/renderer_host/render_widget_host_delegate.h" | 47 #include "content/browser/renderer_host/render_widget_host_delegate.h" |
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
772 delegate_->RenderFrameCreated(this); | 773 delegate_->RenderFrameCreated(this); |
773 else | 774 else |
774 delegate_->RenderFrameDeleted(this); | 775 delegate_->RenderFrameDeleted(this); |
775 } | 776 } |
776 | 777 |
777 if (created && render_widget_host_) | 778 if (created && render_widget_host_) |
778 render_widget_host_->InitForFrame(); | 779 render_widget_host_->InitForFrame(); |
779 } | 780 } |
780 | 781 |
781 void RenderFrameHostImpl::Init() { | 782 void RenderFrameHostImpl::Init() { |
782 // TODO(csharrison): Call GetProcess()->ResumeRequestsForFrame(routing_id_) | 783 ResourceDispatcherHost::ResumeBlockedRequestsForFrameFromUI(this); |
783 // once ResourceDispatcherHostImpl is keyed on render frame routing ids | |
784 // instead of render view routing ids. | |
785 } | 784 } |
786 | 785 |
787 void RenderFrameHostImpl::OnAddMessageToConsole( | 786 void RenderFrameHostImpl::OnAddMessageToConsole( |
788 int32_t level, | 787 int32_t level, |
789 const base::string16& message, | 788 const base::string16& message, |
790 int32_t line_no, | 789 int32_t line_no, |
791 const base::string16& source_id) { | 790 const base::string16& source_id) { |
792 if (delegate_->AddMessageToConsole(level, message, line_no, source_id)) | 791 if (delegate_->AddMessageToConsole(level, message, line_no, source_id)) |
793 return; | 792 return; |
794 | 793 |
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1070 while (frame) { | 1069 while (frame) { |
1071 if (frame->render_widget_host_) | 1070 if (frame->render_widget_host_) |
1072 return frame->render_widget_host_->GetView(); | 1071 return frame->render_widget_host_->GetView(); |
1073 frame = static_cast<RenderFrameHostImpl*>(frame->GetParent()); | 1072 frame = static_cast<RenderFrameHostImpl*>(frame->GetParent()); |
1074 } | 1073 } |
1075 | 1074 |
1076 NOTREACHED(); | 1075 NOTREACHED(); |
1077 return nullptr; | 1076 return nullptr; |
1078 } | 1077 } |
1079 | 1078 |
| 1079 GlobalFrameRoutingId RenderFrameHostImpl::GetGlobalFrameRoutingId() { |
| 1080 return GlobalFrameRoutingId(GetProcess()->GetID(), GetRoutingID()); |
| 1081 } |
| 1082 |
1080 int RenderFrameHostImpl::GetEnabledBindings() { | 1083 int RenderFrameHostImpl::GetEnabledBindings() { |
1081 return render_view_host_->GetEnabledBindings(); | 1084 return render_view_host_->GetEnabledBindings(); |
1082 } | 1085 } |
1083 | 1086 |
1084 void RenderFrameHostImpl::SetNavigationHandle( | 1087 void RenderFrameHostImpl::SetNavigationHandle( |
1085 scoped_ptr<NavigationHandleImpl> navigation_handle) { | 1088 scoped_ptr<NavigationHandleImpl> navigation_handle) { |
1086 navigation_handle_ = std::move(navigation_handle); | 1089 navigation_handle_ = std::move(navigation_handle); |
1087 if (navigation_handle_) | 1090 if (navigation_handle_) |
1088 navigation_handle_->set_render_frame_host(this); | 1091 navigation_handle_->set_render_frame_host(this); |
1089 } | 1092 } |
(...skipping 1460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2550 *dst = src; | 2553 *dst = src; |
2551 | 2554 |
2552 if (src.routing_id != -1) | 2555 if (src.routing_id != -1) |
2553 dst->tree_id = RoutingIDToAXTreeID(src.routing_id); | 2556 dst->tree_id = RoutingIDToAXTreeID(src.routing_id); |
2554 | 2557 |
2555 if (src.parent_routing_id != -1) | 2558 if (src.parent_routing_id != -1) |
2556 dst->parent_tree_id = RoutingIDToAXTreeID(src.parent_routing_id); | 2559 dst->parent_tree_id = RoutingIDToAXTreeID(src.parent_routing_id); |
2557 } | 2560 } |
2558 | 2561 |
2559 } // namespace content | 2562 } // namespace content |
OLD | NEW |