]> source.dussan.org Git - jquery.git/commitdiff
Fix in logic for handling exclusive namespace testing. Fixes #6048.
authorjeresig <jeresig@gmail.com>
Mon, 8 Feb 2010 16:31:01 +0000 (11:31 -0500)
committerjeresig <jeresig@gmail.com>
Mon, 8 Feb 2010 16:31:01 +0000 (11:31 -0500)
src/event.js

index 821ea0e48f267182b76ebb673e960a9c65d68cd3..2fda802545f1e73f683a515ecc6814c9c285c149 100644 (file)
@@ -362,7 +362,7 @@ jQuery.event = {
                event.currentTarget = this;
 
                // Namespaced event handlers
-               all = event.type.indexOf(".") < 0;
+               all = event.type.indexOf(".") < 0 && !event.exclusive;
 
                if ( !all ) {
                        namespaces = event.type.split(".");
@@ -380,7 +380,7 @@ jQuery.event = {
                                var handleObj = handlers[ j ];
 
                                // Filter the functions by class
-                               if ( (all && !event.exclusive) || namespace.test( handleObj.namespace ) ) {
+                               if ( all || namespace.test( handleObj.namespace ) ) {
                                        // Pass in a reference to the handler function itself
                                        // So that we can later remove it
                                        event.handler = handleObj.handler;