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

Unified Diff: components/scheduler/child/virtual_time_tqm_delegate.cc

Issue 1411843008: Make blink platform time consistent with the timer virtual time (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix CachingCorrectnessTest Created 5 years, 1 month 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: components/scheduler/child/virtual_time_tqm_delegate.cc
diff --git a/components/scheduler/child/virtual_time_tqm_delegate.cc b/components/scheduler/child/virtual_time_tqm_delegate.cc
index 2d7399ffce5cb46153004c55508d9a72a27bf90f..a5aebf1bdbd76306a6be91a9c67b939e2fe357d7 100644
--- a/components/scheduler/child/virtual_time_tqm_delegate.cc
+++ b/components/scheduler/child/virtual_time_tqm_delegate.cc
@@ -65,6 +65,10 @@ base::TimeTicks VirtualTimeTqmDelegate::NowTicks() {
return now_;
}
+double VirtualTimeTqmDelegate::CurrentTimeSeconds() const {
+ return (now_ - base::TimeTicks::UnixEpoch()).InSecondsF();
+}
+
void VirtualTimeTqmDelegate::AdvancedTimeTo(base::TimeTicks now) {
now_ = now;
DCHECK_GE(now, now_);
« no previous file with comments | « components/scheduler/child/virtual_time_tqm_delegate.h ('k') | components/scheduler/renderer/renderer_scheduler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698