transition-debug.js revision 27bed85eaf07b4dfce81e45d3938b2af93486fe0
/**
* The Transition Utility provides an API for creating advanced transitions.
* @module node
*/
/**
* Provides the base Transition class, for animating numeric properties.
*
* @module node
* @submodule transition
*/
/**
* A class for constructing animation instances.
* @class Transition
* @for Transition
* @constructor
* @extends Base
*/
var START = 'transitionstart',
END = 'transitionend',
NUM = Number;
var _running = {},
Transition = function() {
};
_start: function() {
this._startTime = new Date();
},
if (finish) { // jump to last frame
}
this._running = false;
this._startTime = null;
},
_runFrame: function() {
var t = new Date() - this._startTime,
done = (t >= this._totalDuration),
this._runAttrs(t);
if (done) {
this._end();
}
},
var attr = this._runtimeAttr,
done = false,
d,
t,
i;
for (i in attr) {
t = time;
done = (t >= d);
if (d === 0) { // set instantly
d = 1; // avoid dividing by zero in easings
t = 1;
} else if (t > d) {
t = d;
}
if (!this._skip[i]) {
if (done) {
this._skip[i] = true;
elapsedTime: d,
propertyName: i
});
}
}
}
}
},
_initEasing: function(easing) {
},
_initAttrs: function() {
var from = {},
to = {},
//easing = (typeof this._easing === 'string') ?
// Y.Easing[this._easing] : this._easing,
attr = {},
this._totalDuration = 0;
if (typeof val === 'function') {
} else if (typeof val === 'object') {
//easing = (typeof val.easing === 'string') ?
// Y.Easing[val.easing] : val.easing || easing;
}
}
return;
}
if (typeof easing === 'string') {
}
}
};
if (duration > this._totalDuration) {
this._totalDuration = duration;
}
}
}
this._skip = {};
this._runtimeAttr = attr;
},
// TODO: move to computedStyle? (browsers dont agree on default computed offsets)
_getOffset: function(attr) {
if (val === 'auto') {
} else {
val = 0;
}
}
return val;
},
destroy: function() {
this.detachAll();
this._node = null;
}
},
{
NAME: 'transition',
/**
* Regex of properties that should use the default unit.
*
* @property RE_DEFAULT_UNIT
* @static
*/
/**
* The default unit to use with properties that pass the RE_DEFAULT_UNIT test.
*
* @property DEFAULT_UNIT
* @static
*/
DEFAULT_UNIT: 'px',
/*
DEFAULT_EASING: function (t, b, c, d) {
// easeBoth
if ((t/=d/2) < 1) {
return c/2*t*t + b;
}
return -c/2 * ((--t)*(t-2) - 1) + b;
},
*/
DEFAULT_EASING: 'ease-both',
DEFAULT_DURATION: 0.5,
/**
* Time in milliseconds passed to setInterval for frame processing
*
* @property intervalTime
* @default 20
* @static
*/
intervalTime: 20,
/**
* Bucket for custom getters and setters
*
* @property behaviors
* @static
*/
behaviors: {
left: {
}
}
},
/**
* The default setter to use when setting object properties.
*
* @property DEFAULT_SETTER
* @static
*/
//val = fn(elapsed, NUM(from), NUM(to) - NUM(from), duration);
} else {
}
},
/**
* The default getter to use when getting object properties.
*
* @property DEFAULT_GETTER
* @static
*/
val = '';
} else {
}
return val;
},
_startTimer: function() {
if (!_timer) {
}
},
_stopTimer: function() {
_timer = 0;
},
/**
* Called per Interval to handle each animation frame.
* @method _runFrame
* @private
* @static
*/
_runFrame: function() {
var done = true;
done = false;
}
}
if (done) {
}
},
var tmp = [];
for (var i = 0; i < n; ++i){
}
for (var j = 1; j < n; ++j) {
for (i = 0; i < n - j; ++i) {
}
}
},
cubicBezier: function(p, t) {
return val;
},
easings: {
'ease-in': [0.42, 0, 1, 1],
'ease-out': [0, 0, 0.58, 1],
'ease-in-out': [0.42, 0, 0.58, 1]
},
}, true);
Y.Transition = Transition;
return this;
};