aboutsummaryrefslogtreecommitdiffstats
path: root/src/event.js
diff options
context:
space:
mode:
authorDave Methvin <dave.methvin@gmail.com>2013-11-14 16:33:12 -0500
committerDave Methvin <dave.methvin@gmail.com>2013-11-14 16:33:12 -0500
commitc2aca17d457d302cb1683f925b9e5ee93f0984ea (patch)
tree63c6f6d9daf39e98cb66a387342ccc35819436cf /src/event.js
parent498e0e6c9bf486a0b1f16b455d65fcbc6c43867e (diff)
downloadjquery-c2aca17d457d302cb1683f925b9e5ee93f0984ea.tar.gz
jquery-c2aca17d457d302cb1683f925b9e5ee93f0984ea.zip
Ref #14180, let focusin/out work on non-element targets.
Diffstat (limited to 'src/event.js')
-rw-r--r--src/event.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/event.js b/src/event.js
index 5ca6d2e96..8d4031211 100644
--- a/src/event.js
+++ b/src/event.js
@@ -728,7 +728,7 @@ if ( !support.focusinBubbles ) {
jQuery.event.special[ fix ] = {
setup: function() {
- var doc = this.ownerDocument,
+ var doc = this.ownerDocument || this,
attaches = data_priv.access( doc, fix );
if ( !attaches ) {
@@ -737,7 +737,7 @@ if ( !support.focusinBubbles ) {
data_priv.access( doc, fix, ( attaches || 0 ) + 1 );
},
teardown: function() {
- var doc = this.ownerDocument,
+ var doc = this.ownerDocument || this,
attaches = data_priv.access( doc, fix ) - 1;
if ( !attaches ) {