| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #include "base/test/test_mock_time_task_runner.h" | 5 #include "base/test/test_mock_time_task_runner.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/macros.h" |
| 8 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 9 #include "base/time/clock.h" | 10 #include "base/time/clock.h" |
| 10 #include "base/time/tick_clock.h" | 11 #include "base/time/tick_clock.h" |
| 11 | 12 |
| 12 namespace base { | 13 namespace base { |
| 13 | 14 |
| 14 namespace { | 15 namespace { |
| 15 | 16 |
| 16 // MockTickClock -------------------------------------------------------------- | 17 // MockTickClock -------------------------------------------------------------- |
| 17 | 18 |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 254 if (!tasks_.empty() && | 255 if (!tasks_.empty() && |
| 255 (tasks_.top().GetTimeToRun() - reference) <= max_delta) { | 256 (tasks_.top().GetTimeToRun() - reference) <= max_delta) { |
| 256 *next_task = tasks_.top(); | 257 *next_task = tasks_.top(); |
| 257 tasks_.pop(); | 258 tasks_.pop(); |
| 258 return true; | 259 return true; |
| 259 } | 260 } |
| 260 return false; | 261 return false; |
| 261 } | 262 } |
| 262 | 263 |
| 263 } // namespace base | 264 } // namespace base |
| OLD | NEW |