|
@@ -27,7 +27,7 @@
|
|
|
pause: function () {},
|
|
|
walk: function () {},
|
|
|
slides: [
|
|
|
- // {
|
|
|
+ // {
|
|
|
// src: null,
|
|
|
// color: null,
|
|
|
// delay: null,
|
|
@@ -92,7 +92,7 @@
|
|
|
if (this.settings.animationRegister instanceof Array === false) {
|
|
|
this.settings.animationRegister = [ this.settings.animationRegister ];
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
this.transitions = this.transitions.concat(this.settings.transitionRegister);
|
|
|
this.animations = this.animations.concat(this.settings.animationRegister);
|
|
|
|
|
@@ -125,7 +125,7 @@
|
|
|
// Wrapper with content
|
|
|
if (!isBody) {
|
|
|
this.$elmt.css('height', this.$elmt.css('height'));
|
|
|
-
|
|
|
+
|
|
|
$wrapper = $('<div class="vegas-wrapper">')
|
|
|
.css('overflow', this.$elmt.css('overflow'))
|
|
|
.css('padding', this.$elmt.css('padding'));
|
|
@@ -180,7 +180,7 @@
|
|
|
},
|
|
|
|
|
|
_preload: function () {
|
|
|
- var video, img, i;
|
|
|
+ var img, i;
|
|
|
|
|
|
for (i = 0; i < this.settings.slides.length; i++) {
|
|
|
if (this.settings.preload || this.settings.preloadImages) {
|
|
@@ -193,9 +193,9 @@
|
|
|
if (this.settings.preload || this.settings.preloadVideos) {
|
|
|
if (this.support.video && this.settings.slides[i].video) {
|
|
|
if (this.settings.slides[i].video instanceof Array) {
|
|
|
- video = this._video(this.settings.slides[i].video);
|
|
|
+ this._video(this.settings.slides[i].video);
|
|
|
} else {
|
|
|
- video = this._video(this.settings.slides[i].video.src);
|
|
|
+ this._video(this.settings.slides[i].video.src);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -212,7 +212,7 @@
|
|
|
if (this.total > 1 && !this.paused && !this.noshow) {
|
|
|
this.timeout = setTimeout(function () {
|
|
|
self.next();
|
|
|
- }, this._options('delay'));
|
|
|
+ }, this._options('delay'));
|
|
|
}
|
|
|
},
|
|
|
|
|
@@ -245,7 +245,7 @@
|
|
|
},
|
|
|
|
|
|
_video: function (srcs) {
|
|
|
- var video,
|
|
|
+ var video,
|
|
|
source,
|
|
|
cacheKey = srcs.toString();
|
|
|
|
|
@@ -291,7 +291,7 @@
|
|
|
var self = this,
|
|
|
delay = duration / 10,
|
|
|
volume = video.volume + 0.09;
|
|
|
-
|
|
|
+
|
|
|
if (volume < 1) {
|
|
|
video.volume = volume;
|
|
|
|
|
@@ -366,7 +366,7 @@
|
|
|
}
|
|
|
|
|
|
$slide = $('<div class="vegas-slide"></div>');
|
|
|
-
|
|
|
+
|
|
|
if (this.support.transition && transition) {
|
|
|
$slide.addClass('vegas-transition-' + transition);
|
|
|
}
|
|
@@ -479,7 +479,7 @@
|
|
|
if (video.readyState === 4) {
|
|
|
video.currentTime = 0;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
video.play();
|
|
|
go();
|
|
|
} else {
|
|
@@ -572,8 +572,8 @@
|
|
|
if (fn === 'init') {
|
|
|
params = [ this.settings ];
|
|
|
} else {
|
|
|
- params = [
|
|
|
- this.slide,
|
|
|
+ params = [
|
|
|
+ this.slide,
|
|
|
this.settings.slides[this.slide]
|
|
|
];
|
|
|
}
|
|
@@ -594,7 +594,7 @@
|
|
|
if (value === undefined) {
|
|
|
return this.settings[key];
|
|
|
}
|
|
|
- this.settings[key] = value;
|
|
|
+ this.settings[key] = value;
|
|
|
} else {
|
|
|
return this.settings;
|
|
|
}
|
|
@@ -603,12 +603,12 @@
|
|
|
if (this.settings.slides !== oldSlides) {
|
|
|
this.total = this.settings.slides.length;
|
|
|
this.noshow = this.total < 2;
|
|
|
- this._preload();
|
|
|
+ this._preload();
|
|
|
}
|
|
|
},
|
|
|
|
|
|
destroy: function () {
|
|
|
- clearTimeout(this.timeout);
|
|
|
+ clearTimeout(this.timeout);
|
|
|
|
|
|
this.$elmt.removeClass('vegas-container');
|
|
|
this.$elmt.find('> .vegas-slide').remove();
|
|
@@ -622,7 +622,7 @@
|
|
|
if (this.settings.overlay) {
|
|
|
this.$overlay.remove();
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
this.elmt._vegas = null;
|
|
|
}
|
|
|
};
|