Pamela,
thanks a lot for your reply. I already read this article. With this
InitOptions, the background is set in a second step. One the frame is
created, its background is gray.
After that, the bgcolor change to the color in the backgroundFillStyle. Then
the map is loaded on this new bg. The problem persist. Probably the color is
set in a non accessible previous state.

This is the code I use:

<maps:Map id="map" mapevent_mappreinitialize="onMapPreinitialize(event)"
mapevent_mapready="{onMapReady(event)}">

private function onMapReady(event:Event):void {
                map.addControl(new ZoomControl());
                map.addControl(new PositionControl());
                map.openInfoWindow(new LatLng(42.528156,-9.759271), new
InfoWindowOptions({contentHTML: "<font face='Verdana' size='12'><b>Ron -
Italia<br/></font>", hasCloseButton:true}));
            }

private function onMapPreinitialize(event:Event):void {

                var opts:MapOptions = new MapOptions();
                opts.mapType = MapType.NORMAL_MAP_TYPE;
                opts.center = new LatLng(42.528156,-9.759271);
                opts.zoom = 8;
                opts.backgroundFillStyle = new FillStyle();
                opts.backgroundFillStyle.color = 0xFFFFFF;
                this.map.setInitOptions(opts);

            }

Cheers
-- Marco

On Thu, Jan 8, 2009 at 3:14 AM, pamela (Google Employee) <
pamela...@gmail.com> wrote:

>
> Hi Marco-
>
> Yes, use the preinit event with setInitOptions. See:
>
> http://code.google.com/apis/maps/documentation/flash/reference.html#MapOptions.backgroundFillStyle
>
> The sky demo in the gallery uses a black background.
>
> - pamela
>
> On Thu, Jan 8, 2009 at 2:23 AM, mplebani <marco.pleb...@gmail.com> wrote:
> >
> > Hi!
> > I am integrating GMaps inside a flex site. This site is not available
> > yet.
> > When the Map component is loaded in my application it has a gray
> > default background. There is a way to change this color?
> >
> > -- Marco
> > >
> >
>
> >
>


-- 

Marco Plebani

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API For Flash" group.
To post to this group, send email to google-maps-api-for-flash@googlegroups.com
To unsubscribe from this group, send email to 
google-maps-api-for-flash+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-maps-api-for-flash?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to