| Index: cc/test/ordered_simple_task_runner.h
|
| diff --git a/cc/test/ordered_simple_task_runner.h b/cc/test/ordered_simple_task_runner.h
|
| index 8850a760bf88de7fb7f7df663324271809d3e8c2..409560c5f381fe1d7a276a085a456553a802695c 100644
|
| --- a/cc/test/ordered_simple_task_runner.h
|
| +++ b/cc/test/ordered_simple_task_runner.h
|
| @@ -5,9 +5,14 @@
|
| #ifndef CC_TEST_ORDERED_SIMPLE_TASK_RUNNER_H_
|
| #define CC_TEST_ORDERED_SIMPLE_TASK_RUNNER_H_
|
|
|
| +#include <deque>
|
| +
|
| #include "base/basictypes.h"
|
| #include "base/compiler_specific.h"
|
| +#include "base/debug/trace_event.h"
|
| +#include "base/logging.h"
|
| #include "base/test/test_simple_task_runner.h"
|
| +#include "cc/test/test_now_source.h"
|
|
|
| namespace cc {
|
|
|
| @@ -17,13 +22,36 @@ namespace cc {
|
| class OrderedSimpleTaskRunner : public base::TestSimpleTaskRunner {
|
| public:
|
| OrderedSimpleTaskRunner();
|
| -
|
| + OrderedSimpleTaskRunner(scoped_refptr<TestNowSource> now_src,
|
| + bool advance_now);
|
| +
|
| + // base::TestSimpleTaskRunner implementation:
|
| + virtual bool PostDelayedTask(const tracked_objects::Location& from_here,
|
| + const base::Closure& task,
|
| + base::TimeDelta delay) OVERRIDE;
|
| + virtual bool PostNonNestableDelayedTask(
|
| + const tracked_objects::Location& from_here,
|
| + const base::Closure& task,
|
| + base::TimeDelta delay) OVERRIDE;
|
| virtual void RunPendingTasks() OVERRIDE;
|
|
|
| + void SetAutoAdvanceNowToPendingTasks(bool advance_now);
|
| + base::TimeDelta DelayToNextPendingTask();
|
| +
|
| + // base::debug tracing functionality
|
| + scoped_refptr<base::debug::ConvertableToTraceFormat> AsValue() const;
|
| + virtual void AsValueInto(base::debug::TracedValue* state) const;
|
| +
|
| protected:
|
| virtual ~OrderedSimpleTaskRunner();
|
|
|
| + static void SortTasks(std::deque<base::TestPendingTask>* tasks);
|
| +
|
| private:
|
| + bool advance_now_;
|
| + scoped_refptr<TestNowSource> now_src_;
|
| + bool inside_run_pending_tasks_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(OrderedSimpleTaskRunner);
|
| };
|
|
|
|
|