If you want to kill all info windows, you can do this:
GEvent.addListener(map,"infowindowopen",function() {
map.closeInfoWindow();
});
Because opening the info window is asynchronous, that kills it before it
gets displayed.
If you have other info windows that you do want to display, then you can
set a global flag to control the behaviour:
var killInfoWindow = true; // global
GEvent.addListener(map,"infowindowopen",function() {
if (killInfoWindow) {
map.closeInfoWindow();
}
killInfoWindow = true;
});
...
killInfoWindow = false; // allow this info window to open
marker.openInfoWindowHtml(...);
--
http://econym.org.uk/gmap
The Blackpool Community Church Javascript Team
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Maps-API?hl=en
-~----------~----~----~----~------~----~------~--~---