谷歌Android地图:禁用拖动MapFragment [英] Android Google Maps: disable dragging in MapFragment
问题描述
我可以禁用拖动功能,当用户试图拖动用手指在地图上,而不会干扰放大和缩小?
Can I disable drag functionality when the user tries to drag the map with his fingers without disturbing the Zoom in and Zoom out?
中的任何一个,请建议做这个的想法! 感谢您的precious帮助!
Any one please suggest an idea of doing this! Thanks for your Precious help!!
推荐答案
我想这就是你要找的内容:
I think here's what you're looking for:
在<一个href="https://developers.google.com/maps/documentation/android/interactivity#scroll_pan_gestures">Google地图的Android V2
滚动(PAN)的手势
一个用户可以滚动(平移)周围的地图拖动地图与 手指。你可以通过调用禁用滚动 UiSettings.setScrollGesturesEnabled(布尔)。
A user can scroll (pan) around the map by dragging the map with their finger. You can disable scrolling by calling UiSettings.setScrollGesturesEnabled(boolean).
这篇关于谷歌Android地图:禁用拖动MapFragment的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!