//>>built
define("dojox/fx/Timeline","dojo/_base/lang dojo/fx/easing dojo/_base/fx dojo/dom ./_base dojo/_base/connect dojo/_base/html dojo/_base/array dojo/_base/Color".split(" "),function(u,m,v,w,p,r,x,y,q){p.animateTimeline=function(e,f){var b=new n(e.keys),c=v.animateProperty({node:w.byId(f||e.node),duration:e.duration||1E3,properties:b._properties,easing:m.linear,onAnimate:function(g){}});r.connect(c,"onEnd",function(g){var d=c.curve.getValue(c.reversed?0:1);x.style(g,d)});r.connect(c,"beforeBegin",function(){c.curve&&
delete c.curve;c.curve=b;b.ani=c});return c};var n=function(e){this.keys=u.isArray(e)?this.flatten(e):e};n.prototype.flatten=function(e){var f={},b={};y.forEach(e,function(c,g){var d=c.step;d="from"==d?0:"to"==d?1:void 0===d?0==g?0:g/(e.length-1):.01*parseInt(d,10);var h=m[c.ease]||m.linear,a;for(a in c)"step"!=a&&"ease"!=a&&"from"!=a&&"to"!=a&&(b[a]||(b[a]={steps:[],values:[],eases:[],ease:h},f[a]={},/#/.test(c[a])?f[a].units=b[a].units="isColor":f[a].units=b[a].units=/\D{1,}/.exec(c[a]).join("")),
b[a].eases.push(m[c.ease||"linear"]),b[a].steps.push(d),"isColor"==f[a].units?b[a].values.push(new q(c[a])):b[a].values.push(parseInt(/\d{1,}/.exec(c[a]).join(""))),void 0===f[a].start?f[a].start=b[a].values[b[a].values.length-1]:f[a].end=b[a].values[b[a].values.length-1])});this._properties=f;return b};n.prototype.getValue=function(e){e=this.ani._reversed?1-e:e;var f={},b=this,c=function(l,t){return"isColor"!=b._properties[l].units?b.keys[l].values[t]+b._properties[l].units:b.keys[l].values[t].toCss()},
g;for(g in this.keys)for(var d=this.keys[g],h=0;h<d.steps.length;h++){var a=d.steps[h],z=d.steps[h+1],k=h<d.steps.length?!0:!1,A=d.eases[h]||function(l){return l};if(e==a){if(f[g]=c(g,h),!k||k&&this.ani._reversed)break}else if(e>a)if(k&&e<d.steps[h+1]){k=d.values[h+1];d=d.values[h];a=1/(z-a)*(e-a);a=A(a);f[g]=d instanceof q?q.blendColors(d,k,a).toCss(!1):d+a*(k-d)+this._properties[g].units;break}else f[g]=c(g,h);else if(k&&!this.ani._reversed||!k&&this.ani._reversed)f[g]=c(g,h)}return f};p._Timeline=
n;return p});