On Sep 8, 11:01 pm, carlox <[email protected]> wrote:
>
> Basically I want to set a static (non-draggable) marker that centers
> automatically when the user drag the map or do zoom in/out.
>
> Any suugestions?
var map; // global
var marker = new GMarker(map.getCenter()); // global
function setMarker() {
marker.setLatLng(map.getCenter());
}
GEvent.addListener(map,"zoomend",setMarker);
GEvent.addListener(map,"dragend",setMarker);
Andrew
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---