-
-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SetItemListener allowing duplicate click on item #150
Comments
Hi @angelocavallet would handle a PR with your fix? |
Yeah, it would be awesome! |
Actually you didn't read the right article. Please read this one instead. |
I think it's done. |
Sorry @angelocavallet I didn't check the fiddle when you posted. I've updated it fixing the icons URL and can't see what you've reported. Can you confirm it? |
No problem @jonataswalker. |
You can notice that it executed twice when you try to remove the marker, because there is two markers, so you remove the first one and you'll see the other behind |
Fixed by #153 |
ol-contextmenu/src/internal.js
Line 222 in 004e1a5
Hello,
I don't know if this is what it's meant to be but when you do more than one click in an item the callback is getting called as many times as you clicked before closeMenu() is called.
You can simulate this on the example given on README
https://jsfiddle.net/jonataswalker/ooxs1w5d/
Just double click on "Add Marker" and you will see that two markers are added instead one.
I wrote a workaround for this (probably not the best and most elegant solution, but it works) as follows:
The text was updated successfully, but these errors were encountered: