| 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 "services/shell/standalone/context.h" | 5 #include "services/shell/standalone/context.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 command_line.GetSwitchValueASCII(::switches::kTraceStartup), | 131 command_line.GetSwitchValueASCII(::switches::kTraceStartup), |
| 132 command_line.GetSwitchValueASCII(::switches::kTraceStartupDuration), | 132 command_line.GetSwitchValueASCII(::switches::kTraceStartupDuration), |
| 133 "mojo_runner.trace"); | 133 "mojo_runner.trace"); |
| 134 } | 134 } |
| 135 | 135 |
| 136 if (!init_params || init_params->init_edk) | 136 if (!init_params || init_params->init_edk) |
| 137 EnsureEmbedderIsInitialized(); | 137 EnsureEmbedderIsInitialized(); |
| 138 | 138 |
| 139 service_manager_runner_ = base::ThreadTaskRunnerHandle::Get(); | 139 service_manager_runner_ = base::ThreadTaskRunnerHandle::Get(); |
| 140 blocking_pool_ = | 140 blocking_pool_ = |
| 141 new base::SequencedWorkerPool(kMaxBlockingPoolThreads, "blocking_pool"); | 141 new base::SequencedWorkerPool(kMaxBlockingPoolThreads, "blocking_pool", |
| 142 base::TaskPriority::USER_VISIBLE); |
| 142 | 143 |
| 143 init_edk_ = !init_params || init_params->init_edk; | 144 init_edk_ = !init_params || init_params->init_edk; |
| 144 if (init_edk_) { | 145 if (init_edk_) { |
| 145 mojo::edk::InitIPCSupport(this, io_thread_->task_runner().get()); | 146 mojo::edk::InitIPCSupport(this, io_thread_->task_runner().get()); |
| 146 #if defined(OS_MACOSX) | 147 #if defined(OS_MACOSX) |
| 147 mojo::edk::SetMachPortProvider(MachBroker::GetInstance()->port_provider()); | 148 mojo::edk::SetMachPortProvider(MachBroker::GetInstance()->port_provider()); |
| 148 #endif | 149 #endif |
| 149 } | 150 } |
| 150 | 151 |
| 151 std::unique_ptr<NativeRunnerFactory> runner_factory; | 152 std::unique_ptr<NativeRunnerFactory> runner_factory; |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 255 | 256 |
| 256 std::unique_ptr<ConnectParams> params(new ConnectParams); | 257 std::unique_ptr<ConnectParams> params(new ConnectParams); |
| 257 params->set_source(CreateServiceManagerIdentity()); | 258 params->set_source(CreateServiceManagerIdentity()); |
| 258 params->set_target(Identity(name, mojom::kRootUserID)); | 259 params->set_target(Identity(name, mojom::kRootUserID)); |
| 259 params->set_remote_interfaces(mojo::GetProxy(&remote_interfaces)); | 260 params->set_remote_interfaces(mojo::GetProxy(&remote_interfaces)); |
| 260 params->set_local_interfaces(std::move(local_interfaces)); | 261 params->set_local_interfaces(std::move(local_interfaces)); |
| 261 service_manager_->Connect(std::move(params)); | 262 service_manager_->Connect(std::move(params)); |
| 262 } | 263 } |
| 263 | 264 |
| 264 } // namespace shell | 265 } // namespace shell |
| OLD | NEW |