OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/browser/browser_main_loop.h" | 5 #include "content/browser/browser_main_loop.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 1180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1191 } | 1191 } |
1192 | 1192 |
1193 int BrowserMainLoop::BrowserThreadsStarted() { | 1193 int BrowserMainLoop::BrowserThreadsStarted() { |
1194 TRACE_EVENT0("startup", "BrowserMainLoop::BrowserThreadsStarted"); | 1194 TRACE_EVENT0("startup", "BrowserMainLoop::BrowserThreadsStarted"); |
1195 | 1195 |
1196 #if !defined(OS_IOS) | 1196 #if !defined(OS_IOS) |
1197 // Bring up Mojo IPC and shell as early as possible. | 1197 // Bring up Mojo IPC and shell as early as possible. |
1198 mojo_ipc_support_.reset(new IPC::ScopedIPCSupport( | 1198 mojo_ipc_support_.reset(new IPC::ScopedIPCSupport( |
1199 BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::IO) | 1199 BrowserThread::UnsafeGetMessageLoopForThread(BrowserThread::IO) |
1200 ->task_runner())); | 1200 ->task_runner())); |
1201 mojo_shell_context_.reset(new MojoShellContext); | 1201 mojo_shell_context_.reset(new MojoShellContext(file_thread_->task_runner(), |
| 1202 db_thread_->task_runner())); |
1202 #if defined(OS_MACOSX) | 1203 #if defined(OS_MACOSX) |
1203 mojo::edk::SetMachPortProvider(MachBroker::GetInstance()); | 1204 mojo::edk::SetMachPortProvider(MachBroker::GetInstance()); |
1204 #endif // defined(OS_MACOSX) | 1205 #endif // defined(OS_MACOSX) |
1205 #endif // !defined(OS_IOS) | 1206 #endif // !defined(OS_IOS) |
1206 | 1207 |
1207 #if !defined(OS_IOS) | 1208 #if !defined(OS_IOS) |
1208 indexed_db_thread_.reset(new base::Thread("IndexedDB")); | 1209 indexed_db_thread_.reset(new base::Thread("IndexedDB")); |
1209 indexed_db_thread_->Start(); | 1210 indexed_db_thread_->Start(); |
1210 #endif | 1211 #endif |
1211 | 1212 |
(...skipping 269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1481 DCHECK(is_tracing_startup_for_duration_); | 1482 DCHECK(is_tracing_startup_for_duration_); |
1482 | 1483 |
1483 is_tracing_startup_for_duration_ = false; | 1484 is_tracing_startup_for_duration_ = false; |
1484 TracingController::GetInstance()->StopTracing( | 1485 TracingController::GetInstance()->StopTracing( |
1485 TracingController::CreateFileSink( | 1486 TracingController::CreateFileSink( |
1486 startup_trace_file_, | 1487 startup_trace_file_, |
1487 base::Bind(OnStoppedStartupTracing, startup_trace_file_))); | 1488 base::Bind(OnStoppedStartupTracing, startup_trace_file_))); |
1488 } | 1489 } |
1489 | 1490 |
1490 } // namespace content | 1491 } // namespace content |
OLD | NEW |