我想在谷歌地图 v3 ex 中为复杂多边形中的每个多边形制作点击事件:
var path1 = [new google.maps.LatLng(31.246599, 29.999199),
new google.maps.LatLng(29.999199, 31.246599),
new google.maps.LatLng(30.246599,28.999199)];
var path2 = [new google.maps.LatLng(31, 30),
new google.maps.LatLng(29.999199, 31.246599),
new google.maps.LatLng(30.246599,28.999199)];
poly = new google.maps.Polygon({
paths: [path1, path2],
strokeColor: "#FF0000",
strokeOpacity: 0.8,
strokeWeight: 3,
fillColor: "#FF0000",
fillOpacity: 0.35,
map: map });
// i want to make click event for a polygon that represents by path1
// and the other that represents by path2
谢谢