OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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/frame_rate_controller.h" | 5 #include "cc/frame_rate_controller.h" |
6 | 6 |
7 #include "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "cc/base/thread.h" |
9 #include "cc/delay_based_time_source.h" | 10 #include "cc/delay_based_time_source.h" |
10 #include "cc/time_source.h" | 11 #include "cc/time_source.h" |
11 #include "cc/thread.h" | |
12 | 12 |
13 namespace cc { | 13 namespace cc { |
14 | 14 |
15 class FrameRateControllerTimeSourceAdapter : public TimeSourceClient { | 15 class FrameRateControllerTimeSourceAdapter : public TimeSourceClient { |
16 public: | 16 public: |
17 static scoped_ptr<FrameRateControllerTimeSourceAdapter> Create(FrameRateCont
roller* frameRateController) { | 17 static scoped_ptr<FrameRateControllerTimeSourceAdapter> Create(FrameRateCont
roller* frameRateController) { |
18 return make_scoped_ptr(new FrameRateControllerTimeSourceAdapter(frameRat
eController)); | 18 return make_scoped_ptr(new FrameRateControllerTimeSourceAdapter(frameRat
eController)); |
19 } | 19 } |
20 virtual ~FrameRateControllerTimeSourceAdapter() {} | 20 virtual ~FrameRateControllerTimeSourceAdapter() {} |
21 | 21 |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
147 | 147 |
148 base::TimeTicks FrameRateController::nextTickTime() | 148 base::TimeTicks FrameRateController::nextTickTime() |
149 { | 149 { |
150 if (m_isTimeSourceThrottling) | 150 if (m_isTimeSourceThrottling) |
151 return m_timeSource->nextTickTime(); | 151 return m_timeSource->nextTickTime(); |
152 | 152 |
153 return base::TimeTicks(); | 153 return base::TimeTicks(); |
154 } | 154 } |
155 | 155 |
156 } // namespace cc | 156 } // namespace cc |
OLD | NEW |