2011-04-23 16:45:50 +00:00
|
|
|
// vim: et:ts=4:sw=4:sts=4:ft=js
|
2011-04-22 22:03:10 +00:00
|
|
|
Ox.LoadingIcon = function(options, self) {
|
|
|
|
var self = self || {},
|
|
|
|
that = new Ox.Element('img', self)
|
|
|
|
.defaults({
|
|
|
|
size: 'medium'
|
|
|
|
})
|
|
|
|
.options(options || {})
|
|
|
|
.attr({
|
|
|
|
src: Ox.UI.getImagePath('symbolLoading.svg')
|
|
|
|
})
|
|
|
|
.addClass(
|
|
|
|
'OxLoadingIcon Ox' + Ox.toTitleCase(self.options.size)
|
|
|
|
);
|
|
|
|
that.start = function() {
|
|
|
|
that.animate({
|
|
|
|
opacity: 1
|
|
|
|
}, 250);
|
|
|
|
return that;
|
|
|
|
};
|
|
|
|
that.stop = function() {
|
|
|
|
that.animate({
|
|
|
|
opacity: 0
|
|
|
|
}, 250);
|
|
|
|
return that;
|
|
|
|
}
|
|
|
|
return that;
|
|
|
|
}
|