diff options
author | Dave Methvin <dave.methvin@gmail.com> | 2011-04-04 10:27:31 -0400 |
---|---|---|
committer | Dave Methvin <dave.methvin@gmail.com> | 2011-04-06 23:06:52 -0400 |
commit | bbd9c776ea22296a6807d5b760bd4e82ee5f4414 (patch) | |
tree | 9f4fc07a5ad6d0d7c9a0cd98f438a674fb061f2e | |
parent | b7dd8404c52518bc4d71b0e715c506252d651a3f (diff) | |
download | jquery-bbd9c776ea22296a6807d5b760bd4e82ee5f4414.tar.gz jquery-bbd9c776ea22296a6807d5b760bd4e82ee5f4414.zip |
Fix #8732. Change feature detect for focusin event support, so IE9 won't have duplicate events.
-rw-r--r-- | src/event.js | 2 | ||||
-rw-r--r-- | src/support.js | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/src/event.js b/src/event.js index 0323ffb75..9a63b5f93 100644 --- a/src/event.js +++ b/src/event.js @@ -850,7 +850,7 @@ function trigger( type, elem, args ) { } // Create "bubbling" focus and blur events -if ( document.addEventListener ) { +if ( !jQuery.support.focusinBubbles ) { jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) { // Attach a single capturing handler while someone wants focusin/focusout diff --git a/src/support.js b/src/support.js index 4c309562f..8b950e25f 100644 --- a/src/support.js +++ b/src/support.js @@ -226,6 +226,7 @@ jQuery.support.submitBubbles = eventSupported("submit"); jQuery.support.changeBubbles = eventSupported("change"); + jQuery.support.focusinBubbles = document.attachEvent && eventSupported("focusin"); // release memory in IE div = all = a = null; |