user4152
user4152

Reputation: 241

Google Maps Location - Hide Blue dot (Current Location Marker) and Show My Location Button

I have an app with Google Maps with custom marker in my location. I'm trying my map showing the location button but not the blue dot. I've tried this but it not works:

mapa.setMyLocationEnabled(false);

mapa.getUiSettings().setMyLocationButtonEnabled(true);

This code not shows button and blue dot. How I do?

Upvotes: 0

Views: 2372

Answers (1)

todd
todd

Reputation: 1286

The location button is only visible when the My Location layer is enabled with the setMyLocationEnabled method. You can simulate this behavior by adding a similar button of your own that will center on the user's location when it is pressed.

Upvotes: 1

Related Questions