yi_17328214 发表于 2013-1-29 08:49:53

google map 根据marker的多少设置中心点和缩放比例

function changePan(){ var latlngbounds = new GLatLngBounds( );latlngbounds.extend(new GLatLng(39.907,116.387));latlngbounds.extend(new GLatLng(39.935,116.407));latlngbounds.extend(new GLatLng(39.944,116.432));latlngbounds.extend(new GLatLng(39.924,116.427));map.setCenter( latlngbounds.getCenter( ), map.getBoundsZoomLevel( latlngbounds ) );}
页: [1]
查看完整版本: google map 根据marker的多少设置中心点和缩放比例