Perf. improvement based on fearphage's suggestion (direct vs call vs apply).
This commit is contained in:
parent
1ebb5ab3e1
commit
6bc9fc7c10
|
@ -754,7 +754,11 @@ jQuery.extend({
|
|||
if ( jQuery.support.nativeBind ) {
|
||||
// Native bind
|
||||
args = slice.call( arguments, 1 );
|
||||
if ( args.length ) {
|
||||
proxy = Function.prototype.bind.apply( fn, args );
|
||||
} else {
|
||||
proxy = fn.bind( context );
|
||||
}
|
||||
} else {
|
||||
// Simulated bind
|
||||
args = slice.call( arguments, 2 );
|
||||
|
|
Loading…
Reference in a new issue