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

Unified Diff: third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.cc

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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.cc
diff --git a/third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.cc b/third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.cc
index 36536c6d40370178f54fe69b0c0cd8a57d6a43f3..5109ee59dd6a9ac2fbfe024856298c815968375b 100644
--- a/third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.cc
+++ b/third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.cc
@@ -15,7 +15,7 @@ class FakeWebTaskRunner::Data : public WTF::ThreadSafeRefCounted<Data> {
Data() : time_(0.0) {}
std::unique_ptr<Task> task_;
- base::Closure closure_;
+ base::OnceClosure closure_;
double time_;
private:
@@ -49,9 +49,9 @@ void FakeWebTaskRunner::postDelayedTask(const WebTraceLocation&,
}
void FakeWebTaskRunner::postDelayedTask(const WebTraceLocation&,
- const base::Closure& closure,
+ base::OnceClosure closure,
double) {
- data_->closure_ = closure;
+ data_->closure_ = std::move(closure);
}
bool FakeWebTaskRunner::runsTasksOnCurrentThread() {

Powered by Google App Engine
This is Rietveld 408576698