Leaflet.PixiOverlay icon indicating copy to clipboard operation
Leaflet.PixiOverlay copied to clipboard

Stop propagation

Open luojinzhang opened this issue 2 years ago • 1 comments

Hi guys, I am having a problem with pixi marker. So when I click on the marker, the event is not stopped and keep going through to leaflet layer. I have been looking through in Pixi forum but it doesn't work. Method I have tried:

markerSprite.on('mouseup', (e) => {
              if (moveCount < 2 && onClick) {
                e.stopPropagation();
                onClick(id);
              }
            });

I wonder if anyone know how to solve this. Thank you.

luojinzhang avatar Nov 17 '22 02:11 luojinzhang

Try: markerSprite.on('mouseupoutside', (e) => { if (moveCount < 2 && onClick) { e.stopPropagation(); onClick(id); } });

nebsar avatar Mar 16 '23 01:03 nebsar