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

Unified Diff: third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html

Issue 1221923003: Update bower.json for Polymer elements and add PRESUBMIT.py (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 5 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: third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html
diff --git a/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html b/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html
index 9e089e99b5940f51b1c116cc8235e047e9a60780..303735c0f0ea9d6f588d284fac276aaeca84a6f5 100644
--- a/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html
+++ b/third_party/polymer/v1_0/components/neon-animation/animations/cascaded-animation.html
@@ -40,6 +40,7 @@ Configuration:
properties: {
+ /** @type {!Polymer.IronMeta} */
_animationMeta: {
type: Object,
value: function() {
@@ -49,13 +50,23 @@ Configuration:
},
+ /**
+ * @param {{
+ * animation: string,
+ * nodes: !Array<!Element>,
+ * nodeDelay: (number|undefined),
+ * timing: (Object|undefined)
+ * }} config
+ */
configure: function(config) {
- var animationConstructor = this._animationMeta.byKey(config.animation);
+ var animationConstructor = /** @type {Function} */ (
+ this._animationMeta.byKey(config.animation));
if (!animationConstructor) {
console.warn(this.is + ':', 'constructor for', config.animation, 'not found!');
return;
}
+ this._animations = [];
var nodes = config.nodes;
var effects = [];
var nodeDelay = config.nodeDelay || 50;
@@ -71,12 +82,19 @@ Configuration:
var animation = new animationConstructor();
var effect = animation.configure(config);
+ this._animations.push(animation);
effects.push(effect);
}
config.timing.delay = oldDelay;
this._effect = new GroupEffect(effects);
return this._effect;
+ },
+
+ complete: function() {
+ for (var animation, index = 0; animation = this._animations[index]; index++) {
+ animation.complete(animation.config);
+ }
}
});

Powered by Google App Engine
This is Rietveld 408576698