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

Unified Diff: content/public/browser/browser_thread.h

Issue 2815463003: More code-like comment in browser_thread.h for TaskScheduler migration. (Closed)
Patch Set: Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/browser/browser_thread.h
diff --git a/content/public/browser/browser_thread.h b/content/public/browser/browser_thread.h
index ad2db9118ded8de7523c85f0fc823a03755cc031..fe82220c1e58fd5c0ed6c5c3f234efe46c276afe 100644
--- a/content/public/browser/browser_thread.h
+++ b/content/public/browser/browser_thread.h
@@ -74,8 +74,11 @@ class CONTENT_EXPORT BrowserThread {
// DEPRECATED: prefer base/task_scheduler/post_task.h for new classes
// requiring a background file I/O task runner, i.e.:
// base::CreateSequencedTaskRunnerWithTraits(
- // TaskTraits().MayBlock()
- // .WithPriority(TaskPriority::BACKGROUND|USER_VISIBLE)...)
+ // base::TaskTraits().MayBlock()
+ // .WithPriority(base::TaskPriority::BACKGROUND))
+ // Note: You can use base::TaskPriority::USER_VISIBLE instead of
+ // base::TaskPriority::BACKGROUND if the latency of this operation
+ // is visible but non-blocking to the user.
FILE,
// Used for file system operations that block user interactions.
@@ -83,8 +86,8 @@ class CONTENT_EXPORT BrowserThread {
// DEPRECATED: prefer base/task_scheduler/post_task.h for new classes
// requiring a user-blocking file I/O task runner, i.e.:
// base::CreateSequencedTaskRunnerWithTraits(
- // TaskTraits().MayBlock()
- // .WithPriority(TaskPriority::USER_BLOCKING)...)
+ // base::TaskTraits().MayBlock()
+ // .WithPriority(base::TaskPriority::USER_BLOCKING))
FILE_USER_BLOCKING,
// Used to launch and terminate Chrome processes.
@@ -167,7 +170,7 @@ class CONTENT_EXPORT BrowserThread {
// DEPRECATED: use base/task_scheduler/post_task.h instead.
// * BrowserThread::PostBlockingPoolTask(AndReply)(...) =>
// base::PostTaskWithTraits(AndReply)(
- // FROM_HERE, TaskTraits().MayBlock()...)
+ // FROM_HERE, base::TaskTraits().MayBlock()...)
// * BrowserThread::PostBlockingPoolSequencedTask =>
// Share a single SequencedTaskRunner created via
// base::CreateSequencedTaskRunnerWithTraits() instead of sharing a
@@ -223,7 +226,8 @@ class CONTENT_EXPORT BrowserThread {
// BrowserThread::GetBlockingPool()->GetSequencedTaskRunner(
// base::SequencedWorkerPool::GetSequenceToken())
// =>
- // base::CreateSequencedTaskRunnerWithTraits(TaskTraits().MayBlock()...).
+ // base::CreateSequencedTaskRunnerWithTraits(
+ // base::TaskTraits().MayBlock()...).
static base::SequencedWorkerPool* GetBlockingPool() WARN_UNUSED_RESULT;
// Callable on any thread. Returns whether the given well-known thread is
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698