开发者

Google Map Api v3 Clusterer - which markers are groupped?

开发者 https://www.devze.com 2023-01-26 08:19 出处:网络
if i use clustering on my google maps api, how can i get info about which markers are grouped in cluster? is it possible to get?

if i use clustering on my google maps api, how can i get info about which markers are grouped in cluster? is it possible to get?

it's with google map api v3.

thank yo开发者_Python百科u very much in advance!


If you are using the marker clusterer http://google-maps-utility-library-v3.googlecode.com/svn/trunk/markerclusterer/ then you can listen to the 'clusterclick' event listener to the MarkerCluster.

The callback will be passed the cluster that was clicked on and you can call: getCenter, getSize and getMarkers

With that information you should be able to do what you need to

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号