| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/browser/browser_thread.h" | 5 #include "chrome/browser/browser_thread.h" |
| 6 | 6 |
| 7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
| 8 #include "base/message_loop_proxy.h" | 8 #include "base/message_loop_proxy.h" |
| 9 #include "base/thread_restrictions.h" | 9 #include "base/threading/thread_restrictions.h" |
| 10 | 10 |
| 11 // Friendly names for the well-known threads. | 11 // Friendly names for the well-known threads. |
| 12 static const char* browser_thread_names[BrowserThread::ID_COUNT] = { | 12 static const char* browser_thread_names[BrowserThread::ID_COUNT] = { |
| 13 "", // UI (name assembled in browser_main.cc). | 13 "", // UI (name assembled in browser_main.cc). |
| 14 "Chrome_DBThread", // DB | 14 "Chrome_DBThread", // DB |
| 15 "Chrome_WebKitThread", // WEBKIT | 15 "Chrome_WebKitThread", // WEBKIT |
| 16 "Chrome_FileThread", // FILE | 16 "Chrome_FileThread", // FILE |
| 17 "Chrome_ProcessLauncherThread", // PROCESS_LAUNCHER | 17 "Chrome_ProcessLauncherThread", // PROCESS_LAUNCHER |
| 18 "Chrome_CacheThread", // CACHE | 18 "Chrome_CacheThread", // CACHE |
| 19 "Chrome_IOThread", // IO | 19 "Chrome_IOThread", // IO |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 224 } | 224 } |
| 225 } else { | 225 } else { |
| 226 delete task; | 226 delete task; |
| 227 } | 227 } |
| 228 | 228 |
| 229 if (!guaranteed_to_outlive_target_thread) | 229 if (!guaranteed_to_outlive_target_thread) |
| 230 lock_.Release(); | 230 lock_.Release(); |
| 231 | 231 |
| 232 return !!message_loop; | 232 return !!message_loop; |
| 233 } | 233 } |
| OLD | NEW |