Skip to content

Commit

Permalink
If an inline handler returns false, call event.preventDefault(). Fixe…
Browse files Browse the repository at this point in the history
…s #6337.
  • Loading branch information
dmethvin authored and jeresig committed Sep 24, 2010
1 parent c4e6532 commit adff8e4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/event.js
Expand Up @@ -331,6 +331,7 @@ jQuery.event = {
if ( !(elem && elem.nodeName && jQuery.noData[elem.nodeName.toLowerCase()]) ) {
if ( elem[ "on" + type ] && elem[ "on" + type ].apply( elem, data ) === false ) {
event.result = false;
event.preventDefault();
}
}

Expand Down

0 comments on commit adff8e4

Please sign in to comment.