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

Unified Diff: cc/layer_tree_host.cc

Issue 12453010: Allow impl-only animations, and return opacity values via AnimationEvents. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed nits, patch for submission. Created 7 years, 9 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/layer_animation_controller_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layer_tree_host.cc
diff --git a/cc/layer_tree_host.cc b/cc/layer_tree_host.cc
index fa09369e4dd53f2e33f792bcb31c4354088b3b36..4d935dfc09daf0dbddb7d68cf9b4c81260eef378 100644
--- a/cc/layer_tree_host.cc
+++ b/cc/layer_tree_host.cc
@@ -887,10 +887,22 @@ void LayerTreeHost::setAnimationEventsRecursive(const AnimationEventsVector& eve
for (size_t eventIndex = 0; eventIndex < events.size(); ++eventIndex) {
if (layer->id() == events[eventIndex].layerId) {
- if (events[eventIndex].type == AnimationEvent::Started)
+ switch (events[eventIndex].type) {
+ case AnimationEvent::Started:
layer->notifyAnimationStarted(events[eventIndex], wallClockTime.ToDoubleT());
- else
+ break;
+
+ case AnimationEvent::Finished:
layer->notifyAnimationFinished(wallClockTime.ToDoubleT());
+ break;
+
+ case AnimationEvent::PropertyUpdate:
+ layer->notifyAnimationPropertyUpdate(events[eventIndex]);
+ break;
+
+ default:
+ NOTREACHED();
+ }
}
}
« no previous file with comments | « cc/layer_animation_controller_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698