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

Unified Diff: ios/web/public/web_thread.h

Issue 2637843002: Migrate base::TaskRunner from Closure to OnceClosure (Closed)
Patch Set: rebase 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 | « ios/chrome/app/application_delegate/app_state.mm ('k') | ios/web/web_thread_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/public/web_thread.h
diff --git a/ios/web/public/web_thread.h b/ios/web/public/web_thread.h
index 6a7930b4758ced81224da393c81a3d85fd0a4e11..be41b3080b58b14866953e8ab4464abf0c93c1da 100644
--- a/ios/web/public/web_thread.h
+++ b/ios/web/public/web_thread.h
@@ -101,31 +101,31 @@ class WebThread {
// They return true iff the thread existed and the task was posted.
static bool PostTask(ID identifier,
const tracked_objects::Location& from_here,
- base::Closure task);
+ base::OnceClosure task);
static bool PostDelayedTask(ID identifier,
const tracked_objects::Location& from_here,
- base::Closure task,
+ base::OnceClosure task,
base::TimeDelta delay);
static bool PostNonNestableTask(ID identifier,
const tracked_objects::Location& from_here,
- base::Closure task);
+ base::OnceClosure task);
static bool PostNonNestableDelayedTask(
ID identifier,
const tracked_objects::Location& from_here,
- base::Closure task,
+ base::OnceClosure task,
base::TimeDelta delay);
static bool PostTaskAndReply(ID identifier,
const tracked_objects::Location& from_here,
- base::Closure task,
- base::Closure reply);
+ base::OnceClosure task,
+ base::OnceClosure reply);
template <typename ReturnType, typename ReplyArgType>
static bool PostTaskAndReplyWithResult(
ID identifier,
const tracked_objects::Location& from_here,
- base::Callback<ReturnType()> task,
- base::Callback<void(ReplyArgType)> reply) {
+ base::OnceCallback<ReturnType()> task,
+ base::OnceCallback<void(ReplyArgType)> reply) {
scoped_refptr<base::SingleThreadTaskRunner> task_runner =
GetTaskRunnerForThread(identifier);
return base::PostTaskAndReplyWithResult(task_runner.get(), from_here,
@@ -161,15 +161,15 @@ class WebThread {
// base::PostTaskAndReplyWithResult() with GetBlockingPool() as the task
// runner.
static bool PostBlockingPoolTask(const tracked_objects::Location& from_here,
- base::Closure task);
+ base::OnceClosure task);
static bool PostBlockingPoolTaskAndReply(
const tracked_objects::Location& from_here,
- base::Closure task,
- base::Closure reply);
+ base::OnceClosure task,
+ base::OnceClosure reply);
static bool PostBlockingPoolSequencedTask(
const std::string& sequence_token_name,
const tracked_objects::Location& from_here,
- base::Closure task);
+ base::OnceClosure task);
// Returns the thread pool used for blocking file I/O. Use this object to
// perform random blocking operations such as file writes.
« no previous file with comments | « ios/chrome/app/application_delegate/app_state.mm ('k') | ios/web/web_thread_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698