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

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

Issue 2118903002: scheduler: Move the Blink scheduler into Blink (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 4 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
deleted file mode 100644
index b66c8208e91008346d8aa67ab91061f01dd3a9cc..0000000000000000000000000000000000000000
--- a/components/scheduler/renderer/throttled_time_domain.cc
+++ /dev/null
@@ -1,39 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "components/scheduler/renderer/throttled_time_domain.h"
-
-namespace scheduler {
-
-ThrottledTimeDomain::ThrottledTimeDomain(TimeDomain::Observer* observer,
- const char* tracing_category)
- : RealTimeDomain(observer, tracing_category) {}
-
-ThrottledTimeDomain::~ThrottledTimeDomain() {}
-
-const char* ThrottledTimeDomain::GetName() const {
- return "ThrottledTimeDomain";
-}
-
-void ThrottledTimeDomain::RequestWakeup(base::TimeTicks now,
- base::TimeDelta delay) {
- // We assume the owner (i.e. ThrottlingHelper) will manage wakeups on our
- // behalf.
-}
-
-bool ThrottledTimeDomain::MaybeAdvanceTime() {
- base::TimeTicks next_run_time;
- if (!NextScheduledRunTime(&next_run_time))
- return false;
-
- base::TimeTicks now = Now();
- if (now >= next_run_time)
- return true; // Causes DoWork to post a continuation.
-
- // Unlike RealTimeDomain::MaybeAdvanceTime we don't request a wake up here, we
- // assume the owner (i.e. ThrottlingHelper) will manage wakeups on our behalf.
- return false;
-}
-
-} // namespace scheduler
« no previous file with comments | « components/scheduler/renderer/throttled_time_domain.h ('k') | components/scheduler/renderer/throttling_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698