Question

I need to know if user touch the marker.

enter image description here

Any idea? I hope that somebody help me.

Was it helpful?

Solution

Try to implement OnMarkerClickListner and override onMarkerClick method.

Hava a look at this

OTHER TIPS

Put this code below inside onMapReady(GoogleMap googleMap){..}

mMap = googleMap;
mMap.setOnMarkerClickListener(new GoogleMap.OnMarkerClickListener() {
    @Override
    public boolean onMarkerClick(Marker marker) {
        Log.e("Testing",marker.getTitle());
        return false;
    }
});
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top