Multi-level markers using Google Maps for Flash

You are using the MarkerManager for Google Maps for Flash to set different amounts of markers depending on the selected zoom level? You don’t want to specify the zoom level for each marker?
Setting the zoom level makes sense if you have aggregated markers that relate to a couple of markers in a higher zoom level. But it does not if you have a huge list of unordered markers with no one of them being more special than the other.
For the later case I was missing a method that let me just add a marker and the MarkerManager would take care of at which zoom level to display the marker (so that at higher zoom levels more markers are displayed than in lower ones).
The solution I thought of is to take care of that there are not too many markers in one grid cell, so I wrote a calcMinZoomLevel method that just returns the minimum zoom level so that adding the marker to that level it would be the only marker in the grid cell.

Here it is:

And here’s a nice example including the full source under the BSD license:

Start Flash

Try changing the zoom level and watch markers be added and removed.

Adding custom info windows to Google Maps in Flex

I just tried to create a custom info window for a Google Map using the Google Maps API For Flash. Unfortunately it does not seem to work as expected by setting the customContent property in an object of type InfoWindowOptions. Therefore I wrote this little workaround that creates a popup window: