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

Side by Side Diff: components/web_view/frame_connection.cc

Issue 1679573002: Move shell interfaces into the shell.mojom namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@delegate
Patch Set: . Created 4 years, 10 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 | « components/pdf_viewer/pdf_viewer.cc ('k') | components/web_view/frame_utils.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "components/web_view/frame_connection.h" 5 #include "components/web_view/frame_connection.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 connection->Init(app, std::move(request), 67 connection->Init(app, std::move(request),
68 base::Bind(&OnGotContentHandlerForFrame, frame->app_id(), 68 base::Bind(&OnGotContentHandlerForFrame, frame->app_id(),
69 callback, base::Passed(&frame_connection))); 69 callback, base::Passed(&frame_connection)));
70 } 70 }
71 71
72 void FrameConnection::Init(mojo::ApplicationImpl* app, 72 void FrameConnection::Init(mojo::ApplicationImpl* app,
73 mojo::URLRequestPtr request, 73 mojo::URLRequestPtr request,
74 const base::Closure& on_got_id_callback) { 74 const base::Closure& on_got_id_callback) {
75 DCHECK(!application_connection_); 75 DCHECK(!application_connection_);
76 76
77 mojo::CapabilityFilterPtr filter(mojo::CapabilityFilter::New()); 77 mojo::shell::mojom::CapabilityFilterPtr filter(
78 mojo::shell::mojom::CapabilityFilter::New());
78 mojo::Array<mojo::String> resource_provider_interfaces; 79 mojo::Array<mojo::String> resource_provider_interfaces;
79 resource_provider_interfaces.push_back( 80 resource_provider_interfaces.push_back(
80 resource_provider::ResourceProvider::Name_); 81 resource_provider::ResourceProvider::Name_);
81 filter->filter.insert("mojo:resource_provider", 82 filter->filter.insert("mojo:resource_provider",
82 std::move(resource_provider_interfaces)); 83 std::move(resource_provider_interfaces));
83 84
84 mojo::Array<mojo::String> network_service_interfaces; 85 mojo::Array<mojo::String> network_service_interfaces;
85 network_service_interfaces.push_back(mojo::CookieStore::Name_); 86 network_service_interfaces.push_back(mojo::CookieStore::Name_);
86 network_service_interfaces.push_back(mojo::NetworkService::Name_); 87 network_service_interfaces.push_back(mojo::NetworkService::Name_);
87 network_service_interfaces.push_back(mojo::URLLoaderFactory::Name_); 88 network_service_interfaces.push_back(mojo::URLLoaderFactory::Name_);
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 } 125 }
125 126
126 mus::mojom::WindowTreeClientPtr FrameConnection::GetWindowTreeClient() { 127 mus::mojom::WindowTreeClientPtr FrameConnection::GetWindowTreeClient() {
127 DCHECK(application_connection_); 128 DCHECK(application_connection_);
128 mus::mojom::WindowTreeClientPtr window_tree_client; 129 mus::mojom::WindowTreeClientPtr window_tree_client;
129 application_connection_->ConnectToService(&window_tree_client); 130 application_connection_->ConnectToService(&window_tree_client);
130 return window_tree_client; 131 return window_tree_client;
131 } 132 }
132 133
133 uint32_t FrameConnection::GetContentHandlerID() const { 134 uint32_t FrameConnection::GetContentHandlerID() const {
134 uint32_t content_handler_id = mojo::Shell::kInvalidApplicationID; 135 uint32_t content_handler_id =
136 mojo::shell::mojom::Shell::kInvalidApplicationID;
135 if (!application_connection_->GetRemoteContentHandlerID(&content_handler_id)) 137 if (!application_connection_->GetRemoteContentHandlerID(&content_handler_id))
136 NOTREACHED(); 138 NOTREACHED();
137 return content_handler_id; 139 return content_handler_id;
138 } 140 }
139 141
140 } // namespace web_view 142 } // namespace web_view
OLDNEW
« no previous file with comments | « components/pdf_viewer/pdf_viewer.cc ('k') | components/web_view/frame_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698