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

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

Issue 1646583002: [Reland] Per WebViewScheduler virtual time (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: WebViewSchedulerImpl to unregister the virtual_time_domain_ in the destructor Created 4 years, 11 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/Platform.h
diff --git a/third_party/WebKit/public/platform/Platform.h b/third_party/WebKit/public/platform/Platform.h
index 885a348626efa382279fe6fb63afd55484c1ea4e..3eee9c5aef250152571b2b2f179ca0b89489d592 100644
--- a/third_party/WebKit/public/platform/Platform.h
+++ b/third_party/WebKit/public/platform/Platform.h
@@ -426,6 +426,12 @@ public:
// it is recommended that the fixed point be no further in the past than the epoch.
virtual double monotonicallyIncreasingTimeSeconds() { return 0; }
+ // Virtual time is used by Headless Chrome for determinism and performance (fast forwarding
+ // of timers). New code should typically use |currentTimeSeconds| and
+ // |monotonicallyIncreasingTimeSeconds| as normal.
+ virtual double virtualTimeSeconds() { return 0; }
+ virtual double monotonicallyIncreasingVirtualTimeSeconds() { return 0; }
+
// Returns an interface to the main thread. Can be null if blink was initialized on a thread without a message loop.
BLINK_PLATFORM_EXPORT WebThread* mainThread() const;

Powered by Google App Engine
This is Rietveld 408576698