fixes #5336: reorder focus() call to avoid scrolling

This commit is contained in:
mfansler 2012-10-16 12:27:43 -04:00
parent fa778792c5
commit e24b46b7f3
4 changed files with 12 additions and 18 deletions

View File

@ -70,13 +70,12 @@
that.$element
.addClass('in')
.attr('aria-hidden', false)
.focus()
that.enforceFocus()
transition ?
that.$element.one($.support.transition.end, function () { that.$element.trigger('shown') }) :
that.$element.trigger('shown')
that.$element.one($.support.transition.end, function () { that.$element.focus().trigger('shown') }) :
that.$element.focus().trigger('shown')
})
}
@ -232,4 +231,4 @@
})
})
}(window.jQuery);
}(window.jQuery);

View File

@ -794,13 +794,12 @@
that.$element
.addClass('in')
.attr('aria-hidden', false)
.focus()
that.enforceFocus()
transition ?
that.$element.one($.support.transition.end, function () { that.$element.trigger('shown') }) :
that.$element.trigger('shown')
that.$element.one($.support.transition.end, function () { that.$element.focus().trigger('shown') }) :
that.$element.focus().trigger('shown')
})
}
@ -956,7 +955,8 @@
})
})
}(window.jQuery);/* ===========================================================
}(window.jQuery);
/* ===========================================================
* bootstrap-tooltip.js v2.1.2
* http://twitter.github.com/bootstrap/javascript.html#tooltips
* Inspired by the original jQuery.tipsy by Jason Frame

File diff suppressed because one or more lines are too long

View File

@ -70,13 +70,12 @@
that.$element
.addClass('in')
.attr('aria-hidden', false)
.focus()
that.enforceFocus()
transition ?
that.$element.one($.support.transition.end, function () { that.$element.trigger('shown') }) :
that.$element.trigger('shown')
that.$element.one($.support.transition.end, function () { that.$element.focus().trigger('shown') }) :
that.$element.focus().trigger('shown')
})
}
@ -232,4 +231,4 @@
})
})
}(window.jQuery);
}(window.jQuery);