Skip to content
Permalink
Browse files

No need to set returnValue if preventDefault exists. Thanks kangax fo…

…r the catch.
  • Loading branch information...
jeresig committed Sep 20, 2010
1 parent 7350e2e commit be59693037c4230e1b395e51a42c6fc55b577455
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/event.js
@@ -583,9 +583,11 @@ jQuery.Event.prototype = {
// if preventDefault exists run it on the original event
if ( e.preventDefault ) {
e.preventDefault();
}

// otherwise set the returnValue property of the original event to false (IE)
e.returnValue = false;
} else {
e.returnValue = false;
}
},
stopPropagation: function() {
this.isPropagationStopped = returnTrue;

0 comments on commit be59693

Please sign in to comment.
You can’t perform that action at this time.