Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Side by Side Diff: content/renderer/render_frame_impl.cc

Issue 2420253002: Rename shell namespace to service_manager (Closed)
Patch Set: . Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « content/renderer/render_frame_impl.h ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/renderer/render_frame_impl.h" 5 #include "content/renderer/render_frame_impl.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 1101 matching lines...) Expand 10 before | Expand all | Expand 10 after
1112 is_pasting_(false), 1112 is_pasting_(false),
1113 suppress_further_dialogs_(false), 1113 suppress_further_dialogs_(false),
1114 blame_context_(nullptr), 1114 blame_context_(nullptr),
1115 #if defined(ENABLE_PLUGINS) 1115 #if defined(ENABLE_PLUGINS)
1116 focused_pepper_plugin_(nullptr), 1116 focused_pepper_plugin_(nullptr),
1117 pepper_last_mouse_event_target_(nullptr), 1117 pepper_last_mouse_event_target_(nullptr),
1118 #endif 1118 #endif
1119 frame_binding_(this), 1119 frame_binding_(this),
1120 has_accessed_initial_document_(false), 1120 has_accessed_initial_document_(false),
1121 weak_factory_(this) { 1121 weak_factory_(this) {
1122 // We don't have a shell::Connection at this point, so use nullptr. 1122 // We don't have a service_manager::Connection at this point, so use nullptr.
1123 // TODO(beng): We should fix this, so we can apply policy about which 1123 // TODO(beng): We should fix this, so we can apply policy about which
1124 // interfaces get exposed. 1124 // interfaces get exposed.
1125 interface_registry_.reset(new shell::InterfaceRegistry); 1125 interface_registry_.reset(new service_manager::InterfaceRegistry);
1126 shell::mojom::InterfaceProviderPtr remote_interfaces; 1126 service_manager::mojom::InterfaceProviderPtr remote_interfaces;
1127 pending_remote_interface_provider_request_ = GetProxy(&remote_interfaces); 1127 pending_remote_interface_provider_request_ = GetProxy(&remote_interfaces);
1128 remote_interfaces_.reset(new shell::InterfaceProvider); 1128 remote_interfaces_.reset(new service_manager::InterfaceProvider);
1129 remote_interfaces_->Bind(std::move(remote_interfaces)); 1129 remote_interfaces_->Bind(std::move(remote_interfaces));
1130 blink_interface_provider_.reset(new BlinkInterfaceProviderImpl( 1130 blink_interface_provider_.reset(new BlinkInterfaceProviderImpl(
1131 remote_interfaces_->GetWeakPtr())); 1131 remote_interfaces_->GetWeakPtr()));
1132 blink_interface_registry_.reset( 1132 blink_interface_registry_.reset(
1133 new BlinkInterfaceRegistryImpl(interface_registry_->GetWeakPtr())); 1133 new BlinkInterfaceRegistryImpl(interface_registry_->GetWeakPtr()));
1134 1134
1135 std::pair<RoutingIDFrameMap::iterator, bool> result = 1135 std::pair<RoutingIDFrameMap::iterator, bool> result =
1136 g_routing_id_frame_map.Get().insert(std::make_pair(routing_id_, this)); 1136 g_routing_id_frame_map.Get().insert(std::make_pair(routing_id_, this));
1137 CHECK(result.second) << "Inserting a duplicate item."; 1137 CHECK(result.second) << "Inserting a duplicate item.";
1138 1138
(...skipping 1337 matching lines...) Expand 10 before | Expand all | Expand 10 after
2476 2476
2477 void RenderFrameImpl::LoadURLExternally(const blink::WebURLRequest& request, 2477 void RenderFrameImpl::LoadURLExternally(const blink::WebURLRequest& request,
2478 blink::WebNavigationPolicy policy) { 2478 blink::WebNavigationPolicy policy) {
2479 loadURLExternally(request, policy, WebString(), false); 2479 loadURLExternally(request, policy, WebString(), false);
2480 } 2480 }
2481 2481
2482 void RenderFrameImpl::ExecuteJavaScript(const base::string16& javascript) { 2482 void RenderFrameImpl::ExecuteJavaScript(const base::string16& javascript) {
2483 OnJavaScriptExecuteRequest(javascript, 0, false); 2483 OnJavaScriptExecuteRequest(javascript, 0, false);
2484 } 2484 }
2485 2485
2486 shell::InterfaceRegistry* RenderFrameImpl::GetInterfaceRegistry() { 2486 service_manager::InterfaceRegistry* RenderFrameImpl::GetInterfaceRegistry() {
2487 return interface_registry_.get(); 2487 return interface_registry_.get();
2488 } 2488 }
2489 2489
2490 shell::InterfaceProvider* RenderFrameImpl::GetRemoteInterfaces() { 2490 service_manager::InterfaceProvider* RenderFrameImpl::GetRemoteInterfaces() {
2491 return remote_interfaces_.get(); 2491 return remote_interfaces_.get();
2492 } 2492 }
2493 2493
2494 AssociatedInterfaceRegistry* 2494 AssociatedInterfaceRegistry*
2495 RenderFrameImpl::GetAssociatedInterfaceRegistry() { 2495 RenderFrameImpl::GetAssociatedInterfaceRegistry() {
2496 return &associated_interfaces_; 2496 return &associated_interfaces_;
2497 } 2497 }
2498 2498
2499 AssociatedInterfaceProvider* 2499 AssociatedInterfaceProvider*
2500 RenderFrameImpl::GetRemoteAssociatedInterfaces() { 2500 RenderFrameImpl::GetRemoteAssociatedInterfaces() {
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
2624 return is_using_lofi_; 2624 return is_using_lofi_;
2625 } 2625 }
2626 2626
2627 bool RenderFrameImpl::IsPasting() const { 2627 bool RenderFrameImpl::IsPasting() const {
2628 return is_pasting_; 2628 return is_pasting_;
2629 } 2629 }
2630 2630
2631 // mojom::Frame implementation ------------------------------------------------- 2631 // mojom::Frame implementation -------------------------------------------------
2632 2632
2633 void RenderFrameImpl::GetInterfaceProvider( 2633 void RenderFrameImpl::GetInterfaceProvider(
2634 shell::mojom::InterfaceProviderRequest request) { 2634 service_manager::mojom::InterfaceProviderRequest request) {
2635 interface_registry_->Bind(std::move(request)); 2635 interface_registry_->Bind(std::move(request));
2636 } 2636 }
2637 2637
2638 // blink::WebFrameClient implementation ---------------------------------------- 2638 // blink::WebFrameClient implementation ----------------------------------------
2639 2639
2640 blink::WebPlugin* RenderFrameImpl::createPlugin( 2640 blink::WebPlugin* RenderFrameImpl::createPlugin(
2641 blink::WebLocalFrame* frame, 2641 blink::WebLocalFrame* frame,
2642 const blink::WebPluginParams& params) { 2642 const blink::WebPluginParams& params) {
2643 DCHECK_EQ(frame_, frame); 2643 DCHECK_EQ(frame_, frame);
2644 blink::WebPlugin* plugin = NULL; 2644 blink::WebPlugin* plugin = NULL;
(...skipping 3668 matching lines...) Expand 10 before | Expand all | Expand 10 after
6313 media::MediaPermission* RenderFrameImpl::GetMediaPermission() { 6313 media::MediaPermission* RenderFrameImpl::GetMediaPermission() {
6314 if (!media_permission_dispatcher_) { 6314 if (!media_permission_dispatcher_) {
6315 media_permission_dispatcher_.reset(new MediaPermissionDispatcher(base::Bind( 6315 media_permission_dispatcher_.reset(new MediaPermissionDispatcher(base::Bind(
6316 &RenderFrameImpl::GetInterface<blink::mojom::PermissionService>, 6316 &RenderFrameImpl::GetInterface<blink::mojom::PermissionService>,
6317 base::Unretained(this)))); 6317 base::Unretained(this))));
6318 } 6318 }
6319 return media_permission_dispatcher_.get(); 6319 return media_permission_dispatcher_.get();
6320 } 6320 }
6321 6321
6322 #if defined(ENABLE_MOJO_MEDIA) 6322 #if defined(ENABLE_MOJO_MEDIA)
6323 shell::mojom::InterfaceProvider* RenderFrameImpl::GetMediaInterfaceProvider() { 6323 service_manager::mojom::InterfaceProvider*
6324 RenderFrameImpl::GetMediaInterfaceProvider() {
6324 if (!media_interface_provider_) { 6325 if (!media_interface_provider_) {
6325 media_interface_provider_.reset( 6326 media_interface_provider_.reset(
6326 new MediaInterfaceProvider(GetRemoteInterfaces())); 6327 new MediaInterfaceProvider(GetRemoteInterfaces()));
6327 } 6328 }
6328 6329
6329 return media_interface_provider_.get(); 6330 return media_interface_provider_.get();
6330 } 6331 }
6331 #endif // defined(ENABLE_MOJO_MEDIA) 6332 #endif // defined(ENABLE_MOJO_MEDIA)
6332 6333
6333 bool RenderFrameImpl::AreSecureCodecsSupported() { 6334 bool RenderFrameImpl::AreSecureCodecsSupported() {
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
6548 // event target. Potentially a Pepper plugin will receive the event. 6549 // event target. Potentially a Pepper plugin will receive the event.
6549 // In order to tell whether a plugin gets the last mouse event and which it 6550 // In order to tell whether a plugin gets the last mouse event and which it
6550 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets 6551 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets
6551 // the event, it will notify us via DidReceiveMouseEvent() and set itself as 6552 // the event, it will notify us via DidReceiveMouseEvent() and set itself as
6552 // |pepper_last_mouse_event_target_|. 6553 // |pepper_last_mouse_event_target_|.
6553 pepper_last_mouse_event_target_ = nullptr; 6554 pepper_last_mouse_event_target_ = nullptr;
6554 #endif 6555 #endif
6555 } 6556 }
6556 6557
6557 } // namespace content 6558 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_frame_impl.h ('k') | content/renderer/render_thread_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698