Logicify / jquery-locationpicker-plugin

JQuery Location Picker plugin
MIT License
389 stars 260 forks source link

Changing the radius causes the radius circle to flicker #147

Open jayfrostjay opened 5 years ago

jayfrostjay commented 5 years ago

let _pickerContext = mapsElement.data("locationpicker");
_pickerContext.radius = {MarkerNewRadius}; _pickerContext.map.radius = {MarkerNewRadius}; _pickerContext.settings.radius = {MarkerNewRadius};

The above code is the way i change the radius of the marker.

ljluestc commented 8 months ago
let _pickerContext = mapsElement.data("locationpicker");

// Assuming MarkerNewRadius is the new radius value you want to set
let newRadius = MarkerNewRadius;

// Set the radius for the marker
_pickerContext.radius = newRadius;

// Update the map to reflect the new radius
_pickerContext.updateMap();

// Update the settings with the new radius
_pickerContext.settings.radius = newRadius;