Skip to content
Permalink
Browse files
Edited src/event.js via GitHub
  • Loading branch information
cmc3cn committed Apr 29, 2011
1 parent e2bace8 commit 627016acd62c2db5ec9b6660f35f538201db1de9
Showing with 1 addition and 6 deletions.
  1. +1 −6 src/event.js
@@ -1134,14 +1134,9 @@ function liveHandler( event ) {
if ( handleObj.preType === "mouseenter" || handleObj.preType === "mouseleave" ) {
event.type = handleObj.preType;
related = jQuery( event.relatedTarget ).closest( handleObj.selector )[0];

// Make sure not to accidentally match a child element with the same selector
if ( related && jQuery.contains( elem, related ) ) {
related = elem;
}
}

if ( !related || related !== elem ) {
if ( !related || related !== elem && !jQuery.contains( elem, related ) ) {
elems.push({ elem: elem, handleObj: handleObj, level: close.level });
}
}

0 comments on commit 627016a

Please sign in to comment.