aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRick Waldron <waldron.rick@gmail.com>2011-10-27 15:31:35 -0400
committerRick Waldron <waldron.rick@gmail.com>2011-10-27 15:31:35 -0400
commitf0cf49fee2201718a56fe09d7a8be641f7775dc3 (patch)
tree903e285149a3704dd33c0885c72dd423e0e74a28
parent0b4ac1d2be17a35edaba2609ae61469714f922e3 (diff)
downloadjquery-f0cf49fee2201718a56fe09d7a8be641f7775dc3.tar.gz
jquery-f0cf49fee2201718a56fe09d7a8be641f7775dc3.zip
Cleanup spacing in events.js. Fixes #10601
-rw-r--r--src/event.js18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/event.js b/src/event.js
index 2171f4be4..3576bffca 100644
--- a/src/event.js
+++ b/src/event.js
@@ -81,7 +81,7 @@ jQuery.event = {
tns = rtypenamespace.exec( types[t] ) || [];
type = tns[1];
- namespaces = (tns[2] || "").split( "." ).sort();
+ namespaces = ( tns[2] || "" ).split( "." ).sort();
// If event changes its type, use the special event handlers for the changed type
special = jQuery.event.special[ type ] || {};
@@ -166,7 +166,7 @@ jQuery.event = {
}
// Once for each type.namespace in types; type may be omitted
- types = (types || "").replace( rhoverHack, "mouseover$1 mouseout$1" ).split(" ");
+ types = ( types || "" ).replace( rhoverHack, "mouseover$1 mouseout$1" ).split(" ");
for ( t = 0; t < types.length; t++ ) {
tns = rtypenamespace.exec( types[t] ) || [];
type = tns[1];
@@ -347,7 +347,7 @@ jQuery.event = {
cur = eventPath[i][0];
event.type = eventPath[i][1];
- handle = (jQuery._data( cur, "events" ) || {})[ event.type ] && jQuery._data( cur, "handle" );
+ handle = ( jQuery._data( cur, "events" ) || {} )[ event.type ] && jQuery._data( cur, "handle" );
if ( handle ) {
handle.apply( cur, data );
}
@@ -401,7 +401,7 @@ jQuery.event = {
// Make a writable jQuery.Event from the native event object
event = jQuery.event.fix( event || window.event );
- var handlers = ((jQuery._data( this, "events" ) || {})[ event.type ] || []),
+ var handlers = ( (jQuery._data( this, "events" ) || {} )[ event.type ] || []),
delegateCount = handlers.delegateCount,
args = [].slice.call( arguments, 0 ),
run_all = !event.exclusive && !event.namespace,
@@ -509,8 +509,8 @@ jQuery.event = {
doc = eventDoc.documentElement;
body = eventDoc.body;
- event.pageX = original.clientX + (doc && doc.scrollLeft || body && body.scrollLeft || 0) - (doc && doc.clientLeft || body && body.clientLeft || 0);
- event.pageY = original.clientY + (doc && doc.scrollTop || body && body.scrollTop || 0) - (doc && doc.clientTop || body && body.clientTop || 0);
+ event.pageX = original.clientX + ( doc && doc.scrollLeft || body && body.scrollLeft || 0 ) - ( doc && doc.clientLeft || body && body.clientLeft || 0 );
+ event.pageY = original.clientY + ( doc && doc.scrollTop || body && body.scrollTop || 0 ) - ( doc && doc.clientTop || body && body.clientTop || 0 );
}
// Add relatedTarget, if necessary
@@ -932,9 +932,9 @@ jQuery.fn.extend({
if ( types && types.preventDefault && types.handleObj ) {
// ( event ) dispatched jQuery.Event
var handleObj = types.handleObj;
- jQuery( types.delegateTarget ).off(
- handleObj.namespace? handleObj.type + "." + handleObj.namespace : handleObj.type,
- handleObj.selector,
+ jQuery( types.delegateTarget ).off(
+ handleObj.namespace? handleObj.type + "." + handleObj.namespace : handleObj.type,
+ handleObj.selector,
handleObj.handler
);
return this;