我该如何在将叠加地图类型添加到地图后更改其不透明度?
我希望能够点击一个名为“25%” 的链接,并将添加的图层的不透明度设置为25%。
var imgTypeOptions = {
getTileUrl: function (coord, zoom) {
return "myTile/" + f + ".png";
},
tileSize: new google.maps.Size(256, 256),
name: "Imagen",
opacity: .5 //This is Ok, the first time set the opacity
//but i want to change the opacity later
};
...
var imgMapType = new google.maps.ImageMapType(imgTypeOptions);
...
map.overlayMapTypes.insertAt(0, imgMapType);
我希望能够点击一个名为“25%” 的链接,并将添加的图层的不透明度设置为25%。