Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorJacob Thornton <jacobthornton@gmail.com>2012-10-18 09:26:44 +0400
committerJacob Thornton <jacobthornton@gmail.com>2012-10-18 09:26:44 +0400
commitedc3eee5eaae52384de1486639585c0b41318cf8 (patch)
tree7c82af98402716dbbdd70d6ff2ff7a16648726b1 /js
parent8e6697f2b20da705377d2a7a2eb6957a4df59d77 (diff)
fix carousel event
Diffstat (limited to 'js')
-rw-r--r--js/bootstrap-carousel.js8
1 files changed, 5 insertions, 3 deletions
diff --git a/js/bootstrap-carousel.js b/js/bootstrap-carousel.js
index 0852cf3f43..b533156526 100644
--- a/js/bootstrap-carousel.js
+++ b/js/bootstrap-carousel.js
@@ -94,9 +94,7 @@
, direction = type == 'next' ? 'left' : 'right'
, fallback = type == 'next' ? 'first' : 'last'
, that = this
- , e = $.Event('slide', {
- relatedTarget: $next[0]
- })
+ , e
this.sliding = true
@@ -104,6 +102,10 @@
$next = $next.length ? $next : this.$element.find('.item')[fallback]()
+ e = $.Event('slide', {
+ relatedTarget: $next[0]
+ })
+
if ($next.hasClass('active')) return
if ($.support.transition && this.$element.hasClass('slide')) {