1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-08-07 06:06:47 +02:00

Remove event aliases from JavaScript

Makes life for people with custom jQuery builds excluding event aliases much easier.
This commit is contained in:
Heinrich Fenkart
2014-02-16 20:06:31 +01:00
parent accc95ccd6
commit 8a78bc065f
3 changed files with 16 additions and 16 deletions

View File

@@ -44,7 +44,7 @@
.toggleClass('open')
.trigger('shown.bs.dropdown', relatedTarget)
$this.focus()
$this.trigger('focus')
}
return false
@@ -64,8 +64,8 @@
var isActive = $parent.hasClass('open')
if (!isActive || (isActive && e.keyCode == 27)) {
if (e.which == 27) $parent.find(toggle).focus()
return $this.click()
if (e.which == 27) $parent.find(toggle).trigger('focus')
return $this.trigger('click')
}
var desc = ' li:not(.divider):visible a'
@@ -79,7 +79,7 @@
if (e.keyCode == 40 && index < $items.length - 1) index++ // down
if (!~index) index = 0
$items.eq(index).focus()
$items.eq(index).trigger('focus')
}
function clearMenus(e) {