I've written my custom location listener which checks the user's location in every 10 minutes and updates a marker on the map which denotes the user's location. The problem is that the marker is clickable i.e. it shows a button to get directions to the marker. I want to disable that, how can I do that?
Here's the function which creates/updates the marker
public void updateUserMarker() {
Double temp_latitude = ((MainActivity)mContext).mLatitude;
Double temp_longitude = ((MainActivity)mContext).mLongitude;
if(mMap!=null) {
if (user_marker == null) {
MarkerOptions markerOptions = new MarkerOptions().position(new LatLng(temp_latitude, temp_longitude));
markerOptions.icon(BitmapDescriptorFactory.fromResource(R.drawable.my_marker_icon));
user_marker = mMap.addMarker(markerOptions);
} else {
user_marker.setPosition(new LatLng(temp_latitude, temp_longitude));
}
}
}