On Jun 3, 5:16 pm, AngryHank <[email protected]> wrote:
> Hmmm... Anyone there?

Doesn't look like it...

Anyway, the reason for the behaviour you describe is because the
infoWindow "maximise" listener is added every time the marker is
clicked. So when you click the marker a second time, a second listener
is added. Then when you maximise the infoWindow all the listeners are
triggered.

The GEvent.addListener(iw, "maximizeclick", function() {...}) should
be outside the marker click-handler.

One issue with this is that the infoWindow doesn't exist until it's
first opened, so you can't do
  var iw=map.getInfoWindow()
until the infoWindow has been opened. That's why it's inside the
marker click-handler. That can be worked around using Mike's technique
he shows at http://www.econym.org.uk/gmap/modularized.htm -- once
you've done
  map.getInfoWindow().show();
you can use
  var iw=map.getInfoWindow()
in global scope and add a single listener.

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
-~----------~----~----~----~------~----~------~--~---

Reply via email to