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

Unified Diff: third_party/WebKit/Source/platform/scheduler/child/idle_helper.cc

Issue 2808843003: [scheduler] Change TaskQueue observer call mechanism. (Closed)
Patch Set: Fix compilation Created 3 years, 7 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/Source/platform/scheduler/child/idle_helper.cc
diff --git a/third_party/WebKit/Source/platform/scheduler/child/idle_helper.cc b/third_party/WebKit/Source/platform/scheduler/child/idle_helper.cc
index 0ce84fae25ed66dcbba5b419fcc111498026b648..b61f37383b48db7293abd4c6b6c830e115be5980 100644
--- a/third_party/WebKit/Source/platform/scheduler/child/idle_helper.cc
+++ b/third_party/WebKit/Source/platform/scheduler/child/idle_helper.cc
@@ -96,7 +96,7 @@ IdleHelper::IdlePeriodState IdleHelper::ComputeNewLongIdlePeriodState(
if (long_idle_period_duration >=
base::TimeDelta::FromMilliseconds(kMinimumIdlePeriodDurationMillis)) {
*next_long_idle_period_delay_out = long_idle_period_duration;
- if (!idle_queue_->HasPendingImmediateWork()) {
+ if (!idle_queue_->HasTaskToRunImmediately()) {
return IdlePeriodState::IN_LONG_IDLE_PERIOD_PAUSED;
} else if (long_idle_period_duration == max_long_idle_period_duration) {
return IdlePeriodState::IN_LONG_IDLE_PERIOD_WITH_MAX_DEADLINE;
@@ -248,7 +248,7 @@ void IdleHelper::UpdateLongIdlePeriodStateAfterIdleTask() {
TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("renderer.scheduler"),
"UpdateLongIdlePeriodStateAfterIdleTask");
- if (!idle_queue_->HasPendingImmediateWork()) {
+ if (!idle_queue_->HasTaskToRunImmediately()) {
// If there are no more idle tasks then pause long idle period ticks until a
// new idle task is posted.
state_.UpdateState(IdlePeriodState::IN_LONG_IDLE_PERIOD_PAUSED,

Powered by Google App Engine
This is Rietveld 408576698