jjwtay / leaflet.sector

Leaflet Sector support
Apache License 2.0
7 stars 4 forks source link

Sector does not redraw after running setters #2

Open artuska opened 3 years ago

artuska commented 3 years ago

After i change all of the sector's properties:

shape.setCenter(center);
shape.setNumberOfPoints(numberOfPoints);
shape.setInnerRadius(innerRadius);
shape.setOuterRadius(outerRadius);
shape.setStartBearing(startBearing);
shape.setEndBearing(endBearing);

shape.redraw();

nothing actually changes, shape stays in its initial state, nothing redraws.

donhurickerby commented 2 years ago

Recently ran into this issue and noticed that if you call

shape.setLatLngs()

the underlying lat lngs will update thus updating the sector.