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

Unified Diff: cc/test/animation_timelines_test_common.h

Issue 1973083002: Use element id's for animations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 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
« no previous file with comments | « cc/test/animation_test_common.cc ('k') | cc/test/animation_timelines_test_common.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/animation_timelines_test_common.h
diff --git a/cc/test/animation_timelines_test_common.h b/cc/test/animation_timelines_test_common.h
index 914385d248cb2e1c083e1d9eaf3f8c7494797ae1..d020257b2eadbd8a339c2d110852e1ef21b63ab2 100644
--- a/cc/test/animation_timelines_test_common.h
+++ b/cc/test/animation_timelines_test_common.h
@@ -192,10 +192,10 @@ class TestHostClient : public MutatorHostClient {
private:
std::unique_ptr<AnimationHost> host_;
- using LayerIdToTestLayer =
- std::unordered_map<int, std::unique_ptr<TestLayer>>;
- LayerIdToTestLayer layers_in_active_tree_;
- LayerIdToTestLayer layers_in_pending_tree_;
+ using ElementIdToTestLayer =
+ std::unordered_map<ElementId, std::unique_ptr<TestLayer>, ElementIdHash>;
+ ElementIdToTestLayer layers_in_active_tree_;
+ ElementIdToTestLayer layers_in_pending_tree_;
gfx::ScrollOffset scroll_offset_;
bool mutators_need_commit_;
@@ -264,7 +264,7 @@ class AnimationTimelinesTest : public testing::Test {
void AnimateLayersTransferEvents(base::TimeTicks time,
unsigned expect_events);
- AnimationPlayer* GetPlayerForLayerId(ElementId element_id);
+ AnimationPlayer* GetPlayerForElementId(ElementId element_id);
AnimationPlayer* GetImplPlayerForLayerId(ElementId element_id);
int NextTestLayerId();
@@ -277,7 +277,7 @@ class AnimationTimelinesTest : public testing::Test {
const int timeline_id_;
const int player_id_;
- int element_id_;
+ ElementId element_id_;
int next_test_layer_id_;
« no previous file with comments | « cc/test/animation_test_common.cc ('k') | cc/test/animation_timelines_test_common.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698