tags:

views:

265

answers:

1

I've found that after changing the overlays on a MapView, the changes aren't seen until the user moves the Map, causing a redraw. Is there a way to force this redraw?

+1  A: 

In your Overlay, keep a reference to the MapView. Then when you want to force a redraw, call:

mMapView.invalidate();

Alternatively, if you're not in the UI thread, you can call this:

mMapView.postInvalidate();
Daniel Lew