| Index: services/tracing/tracing_app.cc
|
| diff --git a/services/tracing/tracing_app.cc b/services/tracing/tracing_app.cc
|
| index 915ed03e1f9aa84ef95e8aeb524b584fd8713ab5..0413158526617ad8e859ff9fa3248c70b522fd52 100644
|
| --- a/services/tracing/tracing_app.cc
|
| +++ b/services/tracing/tracing_app.cc
|
| @@ -17,25 +17,26 @@ TracingApp::~TracingApp() {}
|
|
|
| bool TracingApp::ConfigureIncomingConnection(
|
| mojo::ApplicationConnection* connection) {
|
| - connection->AddService<TraceCollector>(this);
|
| + connection->GetServiceProviderImpl().AddService<TraceCollector>(
|
| + [this](const mojo::ConnectionContext& connection_context,
|
| + mojo::InterfaceRequest<TraceCollector> trace_collector_request) {
|
| + if (collector_binding_.is_bound()) {
|
| + LOG(ERROR) << "Another application is already connected to tracing.";
|
| + return;
|
| + }
|
| +
|
| + collector_binding_.Bind(trace_collector_request.Pass());
|
| + });
|
| + connection->GetServiceProviderImpl().AddService<TraceProviderRegistry>(
|
| + [this](const mojo::ConnectionContext& connection_context,
|
| + mojo::InterfaceRequest<TraceProviderRegistry>
|
| + trace_provider_registry_request) {
|
| + provider_registry_bindings_.AddBinding(
|
| + this, trace_provider_registry_request.Pass());
|
| + });
|
| return true;
|
| }
|
|
|
| -void TracingApp::Create(const mojo::ConnectionContext& connection_context,
|
| - mojo::InterfaceRequest<TraceCollector> request) {
|
| - if (collector_binding_.is_bound()) {
|
| - LOG(ERROR) << "Another application is already connected to tracing.";
|
| - return;
|
| - }
|
| -
|
| - collector_binding_.Bind(request.Pass());
|
| -}
|
| -
|
| -void TracingApp::Create(const mojo::ConnectionContext& connection_context,
|
| - mojo::InterfaceRequest<TraceProviderRegistry> request) {
|
| - provider_registry_bindings_.AddBinding(this, request.Pass());
|
| -}
|
| -
|
| void TracingApp::Start(mojo::ScopedDataPipeProducerHandle stream,
|
| const mojo::String& categories) {
|
| tracing_categories_ = categories;
|
|
|