Hello,
my Question is as follows: What does GEvent.addListener(map, "click" function(){...}) return into the callback function? I don't find any information in the GMaps reference at all, can you show me some? The only thing I found out was that there are two parameters, "overlay" and "latLng" that are passed. The name of these parameters should not be of interest right? I could also name them "foo" and "bar" as far as I know. But the parameter "overlay" seems to be empty anyway?
Also I have problems passing these two parameters directly into a callback function I created myself which looks like that...
GEvent.addListener(gmap, "click", generateMarker(overlay, latLng));
... instead of writing the following, which actually works fine.
GEvent.addListener(gmap, "click", function(overlay, latLng) {
generateMarker(overlay, latLng);
});