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

Unified Diff: services/shell/public/cpp/lib/service_context.cc

Issue 2209943002: Eliminate outgoing InterfaceProvider (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@tracing
Patch Set: . Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « services/shell/public/cpp/lib/interface_registry.cc ('k') | services/shell/public/cpp/service_context.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/shell/public/cpp/lib/service_context.cc
diff --git a/services/shell/public/cpp/lib/service_context.cc b/services/shell/public/cpp/lib/service_context.cc
index ed05b644a03d144fab6dfe551b0af06746229166..0fc56f856ac27dd50185a36e15bcdad4ba85e97b 100644
--- a/services/shell/public/cpp/lib/service_context.cc
+++ b/services/shell/public/cpp/lib/service_context.cc
@@ -66,30 +66,25 @@ void ServiceContext::OnStart(mojom::IdentityPtr identity,
void ServiceContext::OnConnect(
mojom::IdentityPtr source,
uint32_t source_id,
- mojom::InterfaceProviderRequest local_interfaces,
- mojom::InterfaceProviderPtr remote_interfaces,
+ mojom::InterfaceProviderRequest interfaces,
mojom::CapabilityRequestPtr allowed_capabilities,
const mojo::String& name) {
- std::unique_ptr<internal::ConnectionImpl> registry(
+ std::unique_ptr<internal::ConnectionImpl> connection(
new internal::ConnectionImpl(name, source.To<Identity>(), source_id,
allowed_capabilities.To<CapabilityRequest>(),
Connection::State::CONNECTED));
std::unique_ptr<InterfaceRegistry> exposed_interfaces(
- new InterfaceRegistry(registry.get()));
- exposed_interfaces->Bind(std::move(local_interfaces));
- registry->SetExposedInterfaces(std::move(exposed_interfaces));
+ new InterfaceRegistry(connection.get()));
+ exposed_interfaces->Bind(std::move(interfaces));
+ connection->SetExposedInterfaces(std::move(exposed_interfaces));
- std::unique_ptr<InterfaceProvider> interfaces(new InterfaceProvider);
- interfaces->Bind(std::move(remote_interfaces));
- registry->SetRemoteInterfaces(std::move(interfaces));
-
- if (!service_->OnConnect(registry.get()))
+ if (!service_->OnConnect(connection.get()))
return;
// TODO(beng): it appears we never prune this list. We should, when the
// connection's remote service provider pipe breaks.
- incoming_connections_.push_back(std::move(registry));
+ incoming_connections_.push_back(std::move(connection));
}
////////////////////////////////////////////////////////////////////////////////
« no previous file with comments | « services/shell/public/cpp/lib/interface_registry.cc ('k') | services/shell/public/cpp/service_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698