diff options
author | karan-96 <karanbatra96@gmail.com> | 2017-01-17 22:22:50 +0530 |
---|---|---|
committer | Michał Gołębiowski <m.goleb@gmail.com> | 2017-03-01 11:48:11 +0100 |
commit | ac9e3016645078e1e42120822cfb2076151c8cbe (patch) | |
tree | 51eecd51ad23004e68a20a448fc34fbde9d474b6 /src/event.js | |
parent | bd984f0ee2cf40107a669d80d92566b8625b1e6b (diff) | |
download | jquery-ac9e3016645078e1e42120822cfb2076151c8cbe.tar.gz jquery-ac9e3016645078e1e42120822cfb2076151c8cbe.zip |
Core: Deprecate jQuery.nodeName
Fixes gh-3475
Closes gh-3505
Diffstat (limited to 'src/event.js')
-rw-r--r-- | src/event.js | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/event.js b/src/event.js index 97431773c..6a07fba8e 100644 --- a/src/event.js +++ b/src/event.js @@ -7,8 +7,10 @@ define( [ "./var/slice", "./data/var/dataPriv", "./core/init", + "./core/nodeName", "./selector" -], function( jQuery, document, documentElement, rnothtmlwhite, rcheckableType, slice, dataPriv ) { +], function( jQuery, document, documentElement, rnothtmlwhite, rcheckableType, slice, dataPriv, + nodeName ) { "use strict"; @@ -477,7 +479,7 @@ jQuery.event = { // For checkable types, fire native event so checked state will be right trigger: function() { if ( rcheckableType.test( this.type ) && - this.click && jQuery.nodeName( this, "input" ) ) { + this.click && nodeName( this, "input" ) ) { this.click(); return false; @@ -486,7 +488,7 @@ jQuery.event = { // For cross-browser consistency, don't fire native .click() on links _default: function( event ) { - return jQuery.nodeName( event.target, "a" ); + return nodeName( event.target, "a" ); } }, |