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

Unified Diff: components/scheduler/renderer/throttled_time_domain.cc

Issue 2155143002: Fix a bug that could occasionaly cause setInterval to stop (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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: components/scheduler/renderer/throttled_time_domain.cc
diff --git a/components/scheduler/renderer/throttled_time_domain.cc b/components/scheduler/renderer/throttled_time_domain.cc
index 76a94a2a01a0a17de431057ffa03918254806c73..5b6eb1409b4b81c9a305cdc0b309f2c2fb9f8b0b 100644
--- a/components/scheduler/renderer/throttled_time_domain.cc
+++ b/components/scheduler/renderer/throttled_time_domain.cc
@@ -15,13 +15,9 @@ ThrottledTimeDomain::ThrottledTimeDomain(TimeDomain::Observer* observer,
ThrottledTimeDomain::~ThrottledTimeDomain() {}
-base::TimeTicks ThrottledTimeDomain::ComputeDelayedRunTime(
- base::TimeTicks,
- base::TimeDelta delay) const {
- // We ignore the |time_domain_now| parameter since its the virtual time but we
- // need to use the current real time when computing the delayed runtime. If
- // don't do that, throttled timers may fire sooner than expected.
- return tick_clock_->NowTicks() + delay;
+base::TimeTicks ThrottledTimeDomain::BlinkNow() const {
rmcilroy 2016/07/18 13:03:03 As discussed offline, could we see whether it is p
alex clarke (OOO till 29th) 2016/07/18 15:02:01 Done.
+ // Report the real time to Blink.
+ return tick_clock_->NowTicks();
}
const char* ThrottledTimeDomain::GetName() const {
« no previous file with comments | « components/scheduler/renderer/throttled_time_domain.h ('k') | components/scheduler/renderer/throttling_helper_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698