You simply define a marker and during the definition define a
'mouseover' event handler that is triggered whenever the mouse is
'hovered' over the marker. It works exactly the same as a 'click'
handler except that you don't have to click ;-)
function createMarker(point) {
var marker = new GMarker(point);
GEvent.addListener(marker, "mouseover", function() {
marker.openInfoWindowHtml("eek!");
});
GEvent.addListener(marker, "mouseout", function() {
marker.closeInfoWindow();
});
return marker;
}
You may want to add some flags to keep the info window open if the
mouse wanders away from the marker.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---