mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
Add a quick test to $.support for native bind.
As per the suggestion by ajpiano: 9f8cd6c499 (commitcomment-218658)
This commit is contained in:
parent
9f8cd6c499
commit
5b1b57850c
@ -751,7 +751,7 @@ jQuery.extend({
|
|||||||
return undefined;
|
return undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( jQuery.isFunction( Function.prototype.bind ) ) {
|
if ( jQuery.support.nativeBind ) {
|
||||||
// Native bind
|
// Native bind
|
||||||
args = slice.call( arguments, 1 );
|
args = slice.call( arguments, 1 );
|
||||||
proxy = Function.prototype.bind.apply( fn, args );
|
proxy = Function.prototype.bind.apply( fn, args );
|
||||||
|
@ -60,6 +60,9 @@
|
|||||||
// (WebKit defaults to false instead of true, IE too, if it's in an optgroup)
|
// (WebKit defaults to false instead of true, IE too, if it's in an optgroup)
|
||||||
optSelected: opt.selected,
|
optSelected: opt.selected,
|
||||||
|
|
||||||
|
// Test for native Function#bind.
|
||||||
|
nativeBind: jQuery.isFunction( Function.prototype.bind ),
|
||||||
|
|
||||||
// Will be defined later
|
// Will be defined later
|
||||||
deleteExpando: true,
|
deleteExpando: true,
|
||||||
optDisabled: false,
|
optDisabled: false,
|
||||||
|
Loading…
Reference in New Issue
Block a user