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

Unified Diff: chrome/browser/ui/webui/settings/about_handler.cc

Issue 2858073002: Use constexpr TaskTraits constructor in chrome. (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
Index: chrome/browser/ui/webui/settings/about_handler.cc
diff --git a/chrome/browser/ui/webui/settings/about_handler.cc b/chrome/browser/ui/webui/settings/about_handler.cc
index e91c9225ce0022963a50aadf13ce06a9e7231345..660d07d2810ee9326643d8727a97b7397b0a0c6f 100644
--- a/chrome/browser/ui/webui/settings/about_handler.cc
+++ b/chrome/browser/ui/webui/settings/about_handler.cc
@@ -485,8 +485,7 @@ void AboutHandler::HandleGetVersionInfo(const base::ListValue* args) {
CHECK(args->GetString(0, &callback_id));
base::PostTaskWithTraitsAndReplyWithResult(
- FROM_HERE, base::TaskTraits().MayBlock().WithPriority(
- base::TaskPriority::USER_VISIBLE),
+ FROM_HERE, {base::MayBlock(), base::TaskPriority::USER_VISIBLE},
base::Bind(&GetVersionInfo),
base::Bind(&AboutHandler::OnGetVersionInfoReady,
weak_factory_.GetWeakPtr(), callback_id));
@@ -504,8 +503,7 @@ void AboutHandler::HandleGetRegulatoryInfo(const base::ListValue* args) {
CHECK(args->GetString(0, &callback_id));
base::PostTaskWithTraitsAndReplyWithResult(
- FROM_HERE, base::TaskTraits().MayBlock().WithPriority(
- base::TaskPriority::USER_VISIBLE),
+ FROM_HERE, {base::MayBlock(), base::TaskPriority::USER_VISIBLE},
base::Bind(&FindRegulatoryLabelDir),
base::Bind(&AboutHandler::OnRegulatoryLabelDirFound,
weak_factory_.GetWeakPtr(), callback_id));
@@ -625,8 +623,7 @@ void AboutHandler::OnRegulatoryLabelDirFound(
}
base::PostTaskWithTraitsAndReplyWithResult(
- FROM_HERE, base::TaskTraits().MayBlock().WithPriority(
- base::TaskPriority::USER_VISIBLE),
+ FROM_HERE, {base::MayBlock(), base::TaskPriority::USER_VISIBLE},
base::Bind(&ReadRegulatoryLabelText, label_dir_path),
base::Bind(&AboutHandler::OnRegulatoryLabelTextRead,
weak_factory_.GetWeakPtr(), callback_id, label_dir_path));

Powered by Google App Engine
This is Rietveld 408576698