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

Side by Side Diff: content/browser/browser_thread_impl.h

Issue 2122543002: Replace Closure in TaskRunner::PostTask with OneShotCallback (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@07_oneshot
Patch Set: fix Created 4 years, 3 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 unified diff | Download patch
« no previous file with comments | « components/user_manager/fake_user_manager.cc ('k') | content/browser/browser_thread_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ 5 #ifndef CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_
6 #define CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ 6 #define CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_
7 7
8 #include "base/threading/platform_thread.h" 8 #include "base/threading/platform_thread.h"
9 #include "base/threading/thread.h" 9 #include "base/threading/thread.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 // The following are unique function names that makes it possible to tell 46 // The following are unique function names that makes it possible to tell
47 // the thread id from the callstack alone in crash dumps. 47 // the thread id from the callstack alone in crash dumps.
48 void UIThreadRun(base::RunLoop* run_loop); 48 void UIThreadRun(base::RunLoop* run_loop);
49 void DBThreadRun(base::RunLoop* run_loop); 49 void DBThreadRun(base::RunLoop* run_loop);
50 void FileThreadRun(base::RunLoop* run_loop); 50 void FileThreadRun(base::RunLoop* run_loop);
51 void FileUserBlockingThreadRun(base::RunLoop* run_loop); 51 void FileUserBlockingThreadRun(base::RunLoop* run_loop);
52 void ProcessLauncherThreadRun(base::RunLoop* run_loop); 52 void ProcessLauncherThreadRun(base::RunLoop* run_loop);
53 void CacheThreadRun(base::RunLoop* run_loop); 53 void CacheThreadRun(base::RunLoop* run_loop);
54 void IOThreadRun(base::RunLoop* run_loop); 54 void IOThreadRun(base::RunLoop* run_loop);
55 55
56 static bool PostTaskHelper( 56 static bool PostTaskHelper(BrowserThread::ID identifier,
57 BrowserThread::ID identifier, 57 const tracked_objects::Location& from_here,
58 const tracked_objects::Location& from_here, 58 base::OnceClosure task,
59 const base::Closure& task, 59 base::TimeDelta delay,
60 base::TimeDelta delay, 60 bool nestable);
61 bool nestable);
62 61
63 // Common initialization code for the constructors. 62 // Common initialization code for the constructors.
64 void Initialize(); 63 void Initialize();
65 64
66 // For testing. 65 // For testing.
67 friend class ContentTestSuiteBaseListener; 66 friend class ContentTestSuiteBaseListener;
68 friend class TestBrowserThreadBundle; 67 friend class TestBrowserThreadBundle;
69 static void FlushThreadPoolHelperForTesting(); 68 static void FlushThreadPoolHelperForTesting();
70 69
71 // The identifier of this thread. Only one thread can exist with a given 70 // The identifier of this thread. Only one thread can exist with a given
72 // identifier at a given time. 71 // identifier at a given time.
73 ID identifier_; 72 ID identifier_;
74 }; 73 };
75 74
76 } // namespace content 75 } // namespace content
77 76
78 #endif // CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_ 77 #endif // CONTENT_BROWSER_BROWSER_THREAD_IMPL_H_
OLDNEW
« no previous file with comments | « components/user_manager/fake_user_manager.cc ('k') | content/browser/browser_thread_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698