What would be the best way to implement a mouseenter/mouseleave like event in Javascript without jQuery? What\'s the best strategy for cross browser use? I\'m thinking some
another option is to distinguish true mouseout
events from fake (child-generated) events using hit-testing. Like so:
elt['onmouseout']=function(evt){
if (!mouse_inside_bounding_box(evt,elt)) console.debug('synthetic mouseleave');
}
I've used something like this on chrome and, caveat emptor, it seemed to do the trick. Once you have a reliable mouseleave event mouseenter is trivial.