app-transitions-native-min.js revision 8f15bcb59d69c9b296f081d67f18ee384295d321
YUI.add("app-transitions-native",function(c){var a=c.App.Transitions;function b(){}b.prototype={initializer:function(){c.Do.before(this._uiTransitionActiveView,this,"_uiSetActiveView");},_getFx:function(h,d,g){var e=a.FX,f=this.get("transitions");if(g===false||!f){return null;}if(g){return e[g];}if(this._isChildView(h,d)){return e[f.toChild];}if(this._isParentView(h,d)){return e[f.toParent];}return e[f.navigate];},_uiTransitionActiveView:function(g,k,n){n||(n={});var h=this._getFx(g,k,n.transition),d,l,e,i,m,f,j;if(!h||g===k){return;}d=this.get("container");l=a.CLASS_NAMES.transitioning;d.addClass(l);e=this._isChildView(g,k);i=!e&&this._isParentView(g,k);m=!!n.prepend||i;this._attachView(g,m);j=new c.Parallel({context:this});f={crossView:!!k&&!!g,};if(g&&h.viewIn){g.get("container").transition(h.viewIn,{crossView:!!k&&!!g,isNewView:true,prepended:m},j.add());}if(k&&h.viewOut){k.get("container").transition(h.viewOut,{crossView:!!k&&!!g,isOldView:true,prepended:m},j.add());}j.done(function(){var o=n.callback;this._detachView(k);d.removeClass(l);o&&o.call(this,g);});return new c.Do.Prevent();}};c.mix(c.Transition.fx,{"app:fadeIn":{opacity:1,duration:0.35,on:{start:function(f){var e={opacity:0},d=f.config;if(d.crossView&&!d.prepended){e.transform="translateX(-100%)";}this.setStyles(e);},end:function(){this.setStyle("transform","translateX(0)");}}},"app:fadeOut":{opacity:0,duration:0.35,on:{start:function(f){var e={opacity:1},d=f.config;if(d.crossView&&d.prepended){e.transform="translateX(-100%)";}this.setStyles(e);},end:function(){this.setStyle("transform","translateX(0)");}}},"app:slideLeft":{duration:0.35,transform:"translateX(-100%)",on:{end:function(){this.setStyle("transform","translateX(0)");}}},"app:slideRight":{duration:0.35,transform:"translateX(0)",on:{start:function(){this.setStyle("transform","translateX(-100%)");},end:function(){this.setStyle("transform","translateX(0)");}}}});c.App.TransitionsNative=b;c.Base.mix(c.App,[b]);},"@VERSION@",{requires:["app-transitions","app-transitions-css","parallel","transition"]});