Skip to content Skip to sidebar Skip to footer

How To Get Default Google Map Marker To Represent User's Current Location

i am using a mapview in my android application and to represent user's current location i have used a custom image. But now i want to replace that custom image by google default ma

Solution 1:

use enableMyLocation() in MyLocationOverlay class:

MyLocationOverlay mMyLocationOverlay = new MyLocationOverlay(this,mapView); 
mMyLocationOverlay.enableMyLocation(); 
mapView.getOverlays().add(mMyLocationOverlay); 

Solution 2:

Just use MyLocationOverlay class.

mMyLocationOverlay = new MyLocationOverlay(this,mapView); 
mMyLocationOverlay.enableCompass(); 
mapView.getOverlays().add(mMyLocationOverlay); 

Solution 3:

You will have to download these Icons using the static url's.

You can use these code bases as examples.

Post a Comment for "How To Get Default Google Map Marker To Represent User's Current Location"