| 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 #include "cc/test/ordered_simple_task_runner.h" | 5 #include "cc/test/ordered_simple_task_runner.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <sstream> | 9 #include <sstream> |
| 10 #include <string> | 10 #include <string> |
| 11 #include <vector> | 11 #include <vector> |
| 12 | 12 |
| 13 #include "base/auto_reset.h" | 13 #include "base/auto_reset.h" |
| 14 #include "base/debug/trace_event.h" | |
| 15 #include "base/debug/trace_event_argument.h" | |
| 16 #include "base/strings/string_number_conversions.h" | 14 #include "base/strings/string_number_conversions.h" |
| 15 #include "base/trace_event/trace_event.h" |
| 16 #include "base/trace_event/trace_event_argument.h" |
| 17 | 17 |
| 18 #define TRACE_TASK(function, task) \ | 18 #define TRACE_TASK(function, task) \ |
| 19 TRACE_EVENT_INSTANT1( \ | 19 TRACE_EVENT_INSTANT1( \ |
| 20 "cc", function, TRACE_EVENT_SCOPE_THREAD, "task", task.AsValue()); | 20 "cc", function, TRACE_EVENT_SCOPE_THREAD, "task", task.AsValue()); |
| 21 | 21 |
| 22 #define TRACE_TASK_RUN(function, tag, task) | 22 #define TRACE_TASK_RUN(function, tag, task) |
| 23 | 23 |
| 24 namespace cc { | 24 namespace cc { |
| 25 | 25 |
| 26 // TestOrderablePendingTask implementation | 26 // TestOrderablePendingTask implementation |
| (...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 325 | 325 |
| 326 bool OrderedSimpleTaskRunner::AdvanceNowCallback() { | 326 bool OrderedSimpleTaskRunner::AdvanceNowCallback() { |
| 327 base::TimeTicks next_task_time = NextTaskTime(); | 327 base::TimeTicks next_task_time = NextTaskTime(); |
| 328 if (now_src_->Now() < next_task_time) { | 328 if (now_src_->Now() < next_task_time) { |
| 329 now_src_->SetNow(next_task_time); | 329 now_src_->SetNow(next_task_time); |
| 330 } | 330 } |
| 331 return true; | 331 return true; |
| 332 } | 332 } |
| 333 | 333 |
| 334 } // namespace cc | 334 } // namespace cc |
| OLD | NEW |