If you have no polygons, polylines or ground overlays, you can set the
opacity of map.getPane(G_MAP_OVERLAY_LAYER_PANE).
All the children of that pane (tile layers, polys and ground overlays)
will be affected, unless the browser is MSIE and the API thinks that the
images are transparent PNGs. (MSIE doesn't support partial opacity when
using AlphaImageLoader).
var pane = map.getPane(G_MAP_OVERLAY_LAYER_PANE);
var percentopacity = 50;
if(typeof(pane.style.filter)=='string'){
pane.style.filter='alpha(opacity:'+this.percentOpacity+')';}
if(typeof(pane.style.KHTMLOpacity)=='string'){
pane.style.KHTMLOpacity=this.percentOpacity/100;}
if(typeof(pane.style.MozOpacity)=='string'){
pane.style.MozOpacity=this.percentOpacity/100;}
if(typeof(pane.style.opacity)=='string'){
pane.style.opacity=this.percentOpacity/100;}
Four different syntaxes for different browsers.
--
Mike Williams
http://econym.org.uk/gmap
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---