How to inflate a custom view inside a google map fragment?
To add images/points on map we can use Markers or GroundOverlay, but if we need a custom view (for example, a list or an image with buttons), both classes receive a BitmapDescriptor on their attributes .icon
and .image
, respectively, which turns a given layout into a plain image, losing its versatility, for example unable to add onClickListeners on buttons.
So is there a way to add a custom view inside google map fragment without it being transformed into an image?