1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-10-02 16:28:26 +02:00

revert collapse change + add emulateTransitionEvent to catch dead css transitions

This commit is contained in:
Jacob Thornton
2013-07-23 18:44:08 -07:00
parent 43e5e90a6d
commit f1009c19b3
10 changed files with 91 additions and 85 deletions

View File

@@ -238,19 +238,10 @@
$tip.removeClass('in')
function removeWithAnimation() {
var timeout = setTimeout(function () {
$tip.off($.support.transition.end).detach()
}, 500)
$tip.one($.support.transition.end, function () {
clearTimeout(timeout)
$tip.detach()
})
}
$.support.transition && this.$tip.hasClass('fade') ?
removeWithAnimation() :
$tip
.one($.support.transition.end, $tip.detach)
.emulateTransitionEnd(150) :
$tip.detach()
this.$element.trigger('hidden.bs.' + this.type)