]> source.dussan.org Git - jquery.git/commitdiff
If an inline handler returns false, call event.preventDefault(). Fixes #6337.
authorDave Methvin <dave.methvin@gmail.com>
Fri, 24 Sep 2010 22:02:31 +0000 (18:02 -0400)
committerjeresig <jeresig@gmail.com>
Fri, 24 Sep 2010 22:02:31 +0000 (18:02 -0400)
src/event.js

index fb78bfeedfa9218f2eae431b2571c678f7fc4334..65b59523e9179355568f8d6525f52d1f374d703f 100644 (file)
@@ -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();
                                }
                        }