开发者

Google Maps v3 - Overriding Default SmoothZoom Behavior

开发者 https://www.devze.com 2023-02-19 23:11 出处:网络
Is there a w开发者_如何学编程ay to prevent a Google Map from automatically doing the Smooth Zoom transition when zooming in or out? I would like it to just snap to the desired zoom level.

Is there a w开发者_如何学编程ay to prevent a Google Map from automatically doing the Smooth Zoom transition when zooming in or out? I would like it to just snap to the desired zoom level.

In the ModestMaps Library for Flash, for example, I can set zoomDuration to 0 to force all transitions to be instant rather than animated.


You can do this by calling setCenter

map.setCenter(latlng, zoomLevel);

Should work in Maps API V3.

0

精彩评论

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