fix mouseenter bug. close #119

This commit is contained in:
Anton Lavrenov
2016-04-26 14:12:04 +07:00
parent 2ea86d99c7
commit 0f77dc4f8b
4 changed files with 116 additions and 5 deletions

View File

@@ -1811,7 +1811,7 @@
this._fire(eventType, evt);
// simulate event bubbling
var stopBubble = (eventType === MOUSEENTER || eventType === MOUSELEAVE) && ((compareShape && compareShape.isAncestorOf && compareShape.isAncestorOf(this)) || !!(compareShape && compareShape.isAncestorOf));
var stopBubble = (eventType === MOUSEENTER || eventType === MOUSELEAVE) && ((compareShape && compareShape.isAncestorOf && compareShape.isAncestorOf(this)));
if((evt && !evt.cancelBubble || !evt) && this.parent && this.parent.isListening() && (!stopBubble)) {
if(compareShape && compareShape.parent) {
this._fireAndBubble.call(this.parent, eventType, evt, compareShape.parent);