mirror of
https://github.com/konvajs/konva.git
synced 2025-07-16 01:22:35 +08:00
Fixing issue #543 - mouseout should fire before mouseover
A mouseout event for the current node should be fired before another node fires its mouseover event.
This commit is contained in:
parent
992be5dd2e
commit
3f2e7b88be
@ -370,12 +370,12 @@
|
|||||||
shape = obj.shape;
|
shape = obj.shape;
|
||||||
if(shape) {
|
if(shape) {
|
||||||
if(!go.isDragging() && obj.pixel[3] === 255 && (!this.targetShape || this.targetShape._id !== shape._id)) {
|
if(!go.isDragging() && obj.pixel[3] === 255 && (!this.targetShape || this.targetShape._id !== shape._id)) {
|
||||||
shape._fireAndBubble(MOUSEOVER, evt, this.targetShape);
|
|
||||||
shape._fireAndBubble(MOUSEENTER, evt, this.targetShape);
|
|
||||||
if(this.targetShape) {
|
if(this.targetShape) {
|
||||||
this.targetShape._fireAndBubble(MOUSEOUT, evt, shape);
|
this.targetShape._fireAndBubble(MOUSEOUT, evt, shape);
|
||||||
this.targetShape._fireAndBubble(MOUSELEAVE, evt, shape);
|
this.targetShape._fireAndBubble(MOUSELEAVE, evt, shape);
|
||||||
}
|
}
|
||||||
|
shape._fireAndBubble(MOUSEOVER, evt, this.targetShape);
|
||||||
|
shape._fireAndBubble(MOUSEENTER, evt, this.targetShape);
|
||||||
this.targetShape = shape;
|
this.targetShape = shape;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
Loading…
Reference in New Issue
Block a user