Skip to content

Instantly share code, notes, and snippets.

@tugcearar
Last active September 10, 2020 14:18
Show Gist options
  • Save tugcearar/ec42ff5ee9d7651cc40c904d41aa3147 to your computer and use it in GitHub Desktop.
Save tugcearar/ec42ff5ee9d7651cc40c904d41aa3147 to your computer and use it in GitHub Desktop.
public void DrawCircleOnMap(GeofenceModel geoModel)
{
if (circle != null)
{
circle.Remove();
circle = null;
}
CircleOptions circleOptions = new CircleOptions()
.InvokeCenter(geoModel.LatLng)
.InvokeRadius(geoModel.Radius)
.InvokeFillColor(Color.Argb(50, 0, 14, 84))
.InvokeStrokeColor(Color.Yellow)
.InvokeStrokeWidth(15);
circle = hMap.AddCircle(circleOptions);
}
private void radiusBar_ProgressChanged(object sender, SeekBar.ProgressChangedEventArgs e)
{
selectedCoordinates.Radius = e.Progress;
DrawCircleOnMap(selectedCoordinates);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment