OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER
_IMPL_H_ | 5 #ifndef THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER
_IMPL_H_ |
6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER
_IMPL_H_ | 6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER
_IMPL_H_ |
7 | 7 |
8 #include "base/atomicops.h" | 8 #include "base/atomicops.h" |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 #include "base/synchronization/lock.h" | 10 #include "base/synchronization/lock.h" |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 | 150 |
151 void AddTaskTimeObserver(TaskTimeObserver* task_time_observer); | 151 void AddTaskTimeObserver(TaskTimeObserver* task_time_observer); |
152 void RemoveTaskTimeObserver(TaskTimeObserver* task_time_observer); | 152 void RemoveTaskTimeObserver(TaskTimeObserver* task_time_observer); |
153 | 153 |
154 // Test helpers. | 154 // Test helpers. |
155 SchedulerHelper* GetSchedulerHelperForTesting(); | 155 SchedulerHelper* GetSchedulerHelperForTesting(); |
156 TaskCostEstimator* GetLoadingTaskCostEstimatorForTesting(); | 156 TaskCostEstimator* GetLoadingTaskCostEstimatorForTesting(); |
157 TaskCostEstimator* GetTimerTaskCostEstimatorForTesting(); | 157 TaskCostEstimator* GetTimerTaskCostEstimatorForTesting(); |
158 IdleTimeEstimator* GetIdleTimeEstimatorForTesting(); | 158 IdleTimeEstimator* GetIdleTimeEstimatorForTesting(); |
159 base::TimeTicks CurrentIdleTaskDeadlineForTesting() const; | 159 base::TimeTicks CurrentIdleTaskDeadlineForTesting() const; |
160 void RunIdleTasksForTesting(const base::Closure& callback); | 160 void RunIdleTasksForTesting(base::OnceClosure callback); |
161 void EndIdlePeriodForTesting(const base::Closure& callback, | 161 void EndIdlePeriodForTesting(base::OnceClosure callback, |
162 base::TimeTicks time_remaining); | 162 base::TimeTicks time_remaining); |
163 bool PolicyNeedsUpdateForTesting(); | 163 bool PolicyNeedsUpdateForTesting(); |
164 | 164 |
165 base::TickClock* tick_clock() const; | 165 base::TickClock* tick_clock() const; |
166 | 166 |
167 RealTimeDomain* real_time_domain() const { | 167 RealTimeDomain* real_time_domain() const { |
168 return helper_.real_time_domain(); | 168 return helper_.real_time_domain(); |
169 } | 169 } |
170 | 170 |
171 AutoAdvancingVirtualTimeDomain* GetVirtualTimeDomain(); | 171 AutoAdvancingVirtualTimeDomain* GetVirtualTimeDomain(); |
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
469 PollableThreadSafeFlag policy_may_need_update_; | 469 PollableThreadSafeFlag policy_may_need_update_; |
470 base::WeakPtrFactory<RendererSchedulerImpl> weak_factory_; | 470 base::WeakPtrFactory<RendererSchedulerImpl> weak_factory_; |
471 | 471 |
472 DISALLOW_COPY_AND_ASSIGN(RendererSchedulerImpl); | 472 DISALLOW_COPY_AND_ASSIGN(RendererSchedulerImpl); |
473 }; | 473 }; |
474 | 474 |
475 } // namespace scheduler | 475 } // namespace scheduler |
476 } // namespace blink | 476 } // namespace blink |
477 | 477 |
478 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDU
LER_IMPL_H_ | 478 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDU
LER_IMPL_H_ |
OLD | NEW |