mirror of
https://github.com/konvajs/konva.git
synced 2025-12-17 09:54:56 +08:00
draw cache hit only when the shape was listening and visible
This commit is contained in:
@@ -594,9 +594,10 @@
|
||||
* @memberof Kinetic.Node.prototype
|
||||
* @returns {Boolean}
|
||||
*/
|
||||
shouldDrawHit: function() {
|
||||
shouldDrawHit: function(canvas) {
|
||||
var layer = this.getLayer();
|
||||
return layer && layer.hitGraphEnabled() && this.isListening() && this.isVisible() && !Kinetic.isDragging();
|
||||
return ((canvas && canvas.isCache) || (layer && layer.hitGraphEnabled()))
|
||||
&& this.isListening() && this.isVisible() && !Kinetic.isDragging();
|
||||
},
|
||||
/**
|
||||
* show node
|
||||
|
||||
Reference in New Issue
Block a user