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

Unified Diff: cc/test/fake_layer_tree_host_impl.cc

Issue 429743003: Rename Animate as Begin(Main)Frame (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Build fix. Created 6 years, 4 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
« no previous file with comments | « cc/test/fake_layer_tree_host_impl.h ('k') | cc/test/layer_tree_test.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_layer_tree_host_impl.cc
diff --git a/cc/test/fake_layer_tree_host_impl.cc b/cc/test/fake_layer_tree_host_impl.cc
index 0505bbd9b9e79e8675971f30c93731a9d4e22713..3c4e12531f81777828ec648ab93cda3001cf248d 100644
--- a/cc/test/fake_layer_tree_host_impl.cc
+++ b/cc/test/fake_layer_tree_host_impl.cc
@@ -2,6 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "cc/test/begin_frame_args_test.h"
#include "cc/test/fake_layer_tree_host_impl.h"
#include "cc/test/test_shared_bitmap_manager.h"
#include "cc/trees/layer_tree_impl.h"
@@ -22,7 +23,7 @@ FakeLayerTreeHostImpl::FakeLayerTreeHostImpl(Proxy* proxy,
// Avoid using Now() as the frame time in unit tests.
base::TimeTicks time_ticks = base::TimeTicks::FromInternalValue(1);
- SetCurrentFrameTimeTicks(time_ticks);
+ SetCurrentBeginFrameArgs(CreateBeginFrameArgsForTesting(time_ticks));
}
FakeLayerTreeHostImpl::FakeLayerTreeHostImpl(const LayerTreeSettings& settings,
@@ -39,7 +40,7 @@ FakeLayerTreeHostImpl::FakeLayerTreeHostImpl(const LayerTreeSettings& settings,
// Avoid using Now() as the frame time in unit tests.
base::TimeTicks time_ticks = base::TimeTicks::FromInternalValue(1);
- SetCurrentFrameTimeTicks(time_ticks);
+ SetCurrentBeginFrameArgs(CreateBeginFrameArgsForTesting(time_ticks));
}
FakeLayerTreeHostImpl::~FakeLayerTreeHostImpl() {}
@@ -51,15 +52,15 @@ void FakeLayerTreeHostImpl::CreatePendingTree() {
1.f, 1.f / arbitrary_large_page_scale, arbitrary_large_page_scale);
}
-base::TimeTicks FakeLayerTreeHostImpl::CurrentFrameTimeTicks() {
- if (current_frame_time_ticks_.is_null())
- return LayerTreeHostImpl::CurrentFrameTimeTicks();
- return current_frame_time_ticks_;
+BeginFrameArgs FakeLayerTreeHostImpl::CurrentBeginFrameArgs() const {
+ if (!current_begin_frame_args_.IsValid())
+ return LayerTreeHostImpl::CurrentBeginFrameArgs();
+ return current_begin_frame_args_;
}
-void FakeLayerTreeHostImpl::SetCurrentFrameTimeTicks(
- base::TimeTicks current_frame_time_ticks) {
- current_frame_time_ticks_ = current_frame_time_ticks;
+void FakeLayerTreeHostImpl::SetCurrentBeginFrameArgs(
+ const BeginFrameArgs& args) {
+ current_begin_frame_args_ = args;
}
int FakeLayerTreeHostImpl::RecursiveUpdateNumChildren(LayerImpl* layer) {
« no previous file with comments | « cc/test/fake_layer_tree_host_impl.h ('k') | cc/test/layer_tree_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698