KineticJS icon indicating copy to clipboard operation
KineticJS copied to clipboard

Mouse click doesn't work with 4.7 and 4.7.1

Open viesti opened this issue 13 years ago • 4 comments

Was experimenting with the sample code for sprites. Attached 'click' listener to the sprite (clicking on the sprite should display a popup) but it won't fire with 4.7. Works with 4.6 though.

Code that I used:

Not working (4.7.1): https://dl.dropboxusercontent.com/u/6800414/sprite-4.7.html

Working (4.6.0): https://dl.dropboxusercontent.com/u/6800414/sprite-4.6.html

viesti avatar Sep 24 '13 05:09 viesti

Hmm, so this could be related to the item in the roadmap for 4.7.3 https://github.com/ericdrowell/KineticJS/wiki/Release-Schedule

Also, it is currently not possible to detect mouse events on shapes that are animating

But funny thing is that in the above example, event handlers attached to the layer or stage don't also work.

viesti avatar Sep 24 '13 07:09 viesti

Edit: Ok i misunderstood your explanation before. 4.7's click event didn't work properly.

Wazabii avatar Sep 25 '13 12:09 Wazabii

Updated the issue description (mentioned that you should get a popup when clicking on the sprite).

Hmm, my Chrome (30.0.1599.47 beta) and Firefox (23.0.1) both don't show the popup when clicking on the sprite with version 4.7.

viesti avatar Sep 25 '13 12:09 viesti

replaced fill() with fillShape() in the hit draw function for Sprite. This was a regression introduced with the major refactorings done for 4.7.0

ericdrowell avatar Sep 25 '13 14:09 ericdrowell