]> source.dussan.org Git - jquery.git/commitdiff
More reference caching
authorRick Waldron <waldron.rick@gmail.com>
Thu, 22 Sep 2011 15:12:42 +0000 (11:12 -0400)
committerRick Waldron <waldron.rick@gmail.com>
Thu, 22 Sep 2011 15:12:42 +0000 (11:12 -0400)
src/event.js

index a9bf19706b446d532194eefe60d9e264e84c8c36..379dc7906a79119ed8e84806af8bf668a92c23ff 100644 (file)
@@ -413,8 +413,10 @@ jQuery.event = {
                // Make a writable jQuery.Event from the native event object
                event = jQuery.event.fix( event || window.event );
 
-               if ( jQuery.event.propHooks[ event.type ] ) {
-                       event = jQuery.event.propHooks[ event.type ]( event );
+               var propHook = jQuery.event.propHooks[ event.type ];
+
+               if ( propHook ) {
+                       event = propHook( event );
                }
 
                var handlers = ((jQuery._data( this, "events" ) || {})[ event.type ] || []),