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

Unified Diff: cc/test/scheduler_test_common.cc

Issue 267783004: Refactoring the way begin frame sources inside scheduler work. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Scheduler now uses frame sources, working on scheduler_unittests. Created 6 years, 7 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/test/scheduler_test_common.cc
diff --git a/cc/test/scheduler_test_common.cc b/cc/test/scheduler_test_common.cc
index 3b35a54a9b713423dd91c55b428dc6997937f01c..8f06627829883212e2b1a021a4832bb297ec5840 100644
--- a/cc/test/scheduler_test_common.cc
+++ b/cc/test/scheduler_test_common.cc
@@ -14,4 +14,27 @@ void FakeTimeSourceClient::OnTimerTick() {
base::TimeTicks FakeDelayBasedTimeSource::Now() const { return now_; }
+DrawSwapReadbackResult
+StubSchedulerClient::ScheduledActionDrawAndSwapIfPossible() {
+ return DrawSwapReadbackResult(
+ DrawSwapReadbackResult::DRAW_SUCCESS, false, false);
+}
+DrawSwapReadbackResult StubSchedulerClient::ScheduledActionDrawAndSwapForced() {
+ return DrawSwapReadbackResult(
+ DrawSwapReadbackResult::DRAW_SUCCESS, false, false);
+}
+DrawSwapReadbackResult StubSchedulerClient::ScheduledActionDrawAndReadback() {
+ return DrawSwapReadbackResult(
+ DrawSwapReadbackResult::DRAW_SUCCESS, false, false);
+}
+base::TimeDelta StubSchedulerClient::DrawDurationEstimate() {
+ return base::TimeDelta::FromMilliseconds(4);
+}
+base::TimeDelta StubSchedulerClient::BeginMainFrameToCommitDurationEstimate() {
+ return base::TimeDelta::FromMilliseconds(3);
+}
+base::TimeDelta StubSchedulerClient::CommitToActivateDurationEstimate() {
+ return base::TimeDelta::FromMilliseconds(2);
+}
+
} // namespace cc

Powered by Google App Engine
This is Rietveld 408576698