mirror of
https://github.com/konvajs/konva.git
synced 2025-09-19 10:47:59 +08:00
mousemove should fire before mouseout
This commit is contained in:
@@ -370,12 +370,12 @@
|
||||
shape = obj.shape;
|
||||
if(shape) {
|
||||
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) {
|
||||
this.targetShape._fireAndBubble(MOUSEOUT, evt, shape);
|
||||
this.targetShape._fireAndBubble(MOUSELEAVE, evt, shape);
|
||||
}
|
||||
shape._fireAndBubble(MOUSEOVER, evt, this.targetShape);
|
||||
shape._fireAndBubble(MOUSEENTER, evt, this.targetShape);
|
||||
this.targetShape = shape;
|
||||
}
|
||||
else {
|
||||
@@ -388,12 +388,12 @@
|
||||
* to run mouseout from previous target shape
|
||||
*/
|
||||
else {
|
||||
this._fire(MOUSEMOVE, evt);
|
||||
if(this.targetShape && !go.isDragging()) {
|
||||
this.targetShape._fireAndBubble(MOUSEOUT, evt);
|
||||
this.targetShape._fireAndBubble(MOUSELEAVE, evt);
|
||||
this.targetShape = null;
|
||||
}
|
||||
this._fire(MOUSEMOVE, evt);
|
||||
}
|
||||
|
||||
if(dd) {
|
||||
|
Reference in New Issue
Block a user