Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable on click highlight of InfoWindows?

Is there any way to disable the highlight effect that comes when user clicks on a InfoWindow in the new Mapsv2 Api for Android?

This is an issue with both the getIfoContent() and the getInfoWindow() methods. With the getInfoWindow() its the text which highlights.

like image 800
Warpzit Avatar asked Feb 08 '13 12:02

Warpzit


1 Answers

In simple words "YOU CANT" .

because as per documentation "An info window is not a live View, rather the view is rendered as an image onto the map. As a result, any listeners you set on the view are disregarded and you cannot distinguish between click events on various parts of the view. You are advised not to place interactive components — such as buttons, checkboxes, or text inputs — within your custom info window."

So, in short u can't handle any events on infowindow other than "OnInfoWindowClickListener"

For more check "https://developers.google.com/maps/documentation/android/marker".

like image 145
Akash Moradiya Avatar answered Oct 16 '22 16:10

Akash Moradiya