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

Unified Diff: third_party/WebKit/public/platform/WebThread.h

Issue 1646583002: [Reland] Per WebViewScheduler virtual time (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove some unneeded changes Created 4 years, 10 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/public/platform/WebThread.h
diff --git a/third_party/WebKit/public/platform/WebThread.h b/third_party/WebKit/public/platform/WebThread.h
index b84f76ff86ea349268ce91427c0d68baeb3038d6..7056e332fb72cca03f1509216e5720b891595564 100644
--- a/third_party/WebKit/public/platform/WebThread.h
+++ b/third_party/WebKit/public/platform/WebThread.h
@@ -57,6 +57,11 @@ public:
virtual void didProcessTask() = 0;
};
+ // Headless Chrome virtualises time for determinism and performance (fast forwarding
+ // of timers). To make this work some parts of blink (e.g. Timers) need to use virtual
+ // time, however by default new code should use the normal non-virtual time APIs.
+ virtual double virtualTimeSeconds() = 0;
+ virtual double monotonicallyIncreasingVirtualTimeSeconds() = 0;
// Returns a WebTaskRunner bound to the underlying scheduler's default task queue.
virtual WebTaskRunner* taskRunner() { return nullptr; }

Powered by Google App Engine
This is Rietveld 408576698