smithmicro / mapbox-gl-circle

A *google.maps.Circle* replacement for Mapbox GL JS
https://smithmicro.github.io/mapbox-gl-circle/
ISC License
55 stars 26 forks source link

Prevent overlapping mouse down events #80

Closed eddydg closed 1 year ago

eddydg commented 5 years ago

Currently, when the circle is small enough, radius and center edit handlers will overlap. Dragging one of those handlers will trigger both events _onCenterHandleMouseDown and _onRadiusHandlesMouseDown which provoke weird behaviours after mouseup/mouseout: the circle sticks to the cursor and you have to refresh the page to reset it:

v1.6.5 pre

I would expect only one of the events to be triggered: the one corresponding to the cursor style.

bugfix/overlapping-events post

Pull request: https://github.com/smithmicro/mapbox-gl-circle/pull/79