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

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

Issue 2319053004: [Reland] Make canceling Timers fast. (Closed)
Patch Set: Rebased 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 eb0a7e11f41b30dd8ca9834a9b0baa08d24f9e8e..36536c6d40370178f54fe69b0c0cd8a57d6a43f3 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,6 +15,7 @@ class FakeWebTaskRunner::Data : public WTF::ThreadSafeRefCounted<Data> {
Data() : time_(0.0) {}
std::unique_ptr<Task> task_;
+ base::Closure closure_;
double time_;
private:
@@ -47,6 +48,12 @@ void FakeWebTaskRunner::postDelayedTask(const WebTraceLocation&,
data_->task_.reset(task);
}
+void FakeWebTaskRunner::postDelayedTask(const WebTraceLocation&,
+ const base::Closure& closure,
+ double) {
+ data_->closure_ = closure;
+}
+
bool FakeWebTaskRunner::runsTasksOnCurrentThread() {
return true;
}
« no previous file with comments | « third_party/WebKit/Source/platform/scheduler/test/fake_web_task_runner.h ('k') | third_party/WebKit/Source/web/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698