Index: third_party/WebKit/Source/core/dom/ScriptedIdleTaskController.h |
diff --git a/third_party/WebKit/Source/core/dom/ScriptedIdleTaskController.h b/third_party/WebKit/Source/core/dom/ScriptedIdleTaskController.h |
index 27d9878a90ed4678d58bcd82d16f478e1c85d0e1..f86a6db13afe79b1e39b211257432255f5796467 100644 |
--- a/third_party/WebKit/Source/core/dom/ScriptedIdleTaskController.h |
+++ b/third_party/WebKit/Source/core/dom/ScriptedIdleTaskController.h |
@@ -43,6 +43,14 @@ public: |
private: |
explicit ScriptedIdleTaskController(ExecutionContext*); |
+ int nextCallbackId(); |
+ |
+ bool isValidCallbackId(int id) |
+ { |
+ using Traits = HashTraits<CallbackId>; |
+ return !Traits::isDeletedValue(id) && !WTF::isHashTraitsEmptyValue<Traits, CallbackId>(id); |
+ } |
+ |
void runCallback(CallbackId, double deadlineSeconds, IdleDeadline::CallbackType); |
WebScheduler* m_scheduler; // Not owned. |