Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3680)

Unified Diff: cc/scheduler/frame_rate_controller.h

Issue 17362002: cc: Remove FakeThread, use SingleThreadTaskRunner in scheduling classes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rm-fakethread: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: cc/scheduler/frame_rate_controller.h
diff --git a/cc/scheduler/frame_rate_controller.h b/cc/scheduler/frame_rate_controller.h
index 070c26a3a09c5afac4d8d46530a4daedd016615a..c3d9e658d8ac25c405f0fd1423c64ebffd24c872 100644
--- a/cc/scheduler/frame_rate_controller.h
+++ b/cc/scheduler/frame_rate_controller.h
@@ -11,9 +11,10 @@
#include "base/time.h"
#include "cc/base/cc_export.h"
+namespace base { class SingleThreadTaskRunner; }
+
namespace cc {
-class Thread;
class TimeSource;
class CC_EXPORT FrameRateControllerClient {
@@ -35,7 +36,7 @@ class CC_EXPORT FrameRateController {
explicit FrameRateController(scoped_refptr<TimeSource> timer);
// Alternate form of FrameRateController with unthrottled frame-rate.
- explicit FrameRateController(Thread* thread);
+ explicit FrameRateController(base::SingleThreadTaskRunner* task_runner);
virtual ~FrameRateController();
void SetClient(FrameRateControllerClient* client) { client_ = client; }
@@ -81,8 +82,9 @@ class CC_EXPORT FrameRateController {
// Members for unthrottled frame-rate.
bool is_time_source_throttling_;
base::WeakPtrFactory<FrameRateController> weak_factory_;
- Thread* thread_;
+ base::SingleThreadTaskRunner* task_runner_;
+ private:
DISALLOW_COPY_AND_ASSIGN(FrameRateController);
};

Powered by Google App Engine
This is Rietveld 408576698