Disable on click highlight of InfoWindows?
Asked Answered
O

1

15

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.

Oversubtle answered 8/2, 2013 at 12:33 Comment(0)
Q
3

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".

Quechua answered 16/5, 2014 at 6:35 Comment(1)
I recently had to revisit this issue and came to the same conclusion. The only workaround would be to use a Custom implementation of some sort.Oversubtle

© 2022 - 2024 — McMap. All rights reserved.