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

Unified Diff: cc/test/animation_timelines_test_common.cc

Issue 1539233002: CC Animations: Fix the case when main-thread player changes layer_id. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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/animation_timelines_test_common.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/animation_timelines_test_common.cc
diff --git a/cc/test/animation_timelines_test_common.cc b/cc/test/animation_timelines_test_common.cc
index 9212da6169b60db6a3390949d23133bdbac22247..6df5bd18ea56bc5e1e6f1dc0c1d91585e33835b9 100644
--- a/cc/test/animation_timelines_test_common.cc
+++ b/cc/test/animation_timelines_test_common.cc
@@ -197,9 +197,11 @@ AnimationTimelinesTest::AnimationTimelinesTest()
host_impl_(nullptr),
timeline_id_(AnimationIdProvider::NextTimelineId()),
player_id_(AnimationIdProvider::NextPlayerId()),
- layer_id_(1) {
+ next_test_layer_id_(0) {
host_ = client_.host();
host_impl_ = client_impl_.host();
+
+ layer_id_ = NextTestLayerId();
}
AnimationTimelinesTest::~AnimationTimelinesTest() {
@@ -258,4 +260,9 @@ AnimationPlayer* AnimationTimelinesTest::GetImplPlayerForLayerId(int layer_id) {
: nullptr;
}
+int AnimationTimelinesTest::NextTestLayerId() {
+ next_test_layer_id_++;
+ return next_test_layer_id_;
+}
+
} // namespace cc
« no previous file with comments | « cc/test/animation_timelines_test_common.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698