我目前正在使用 gmaps4ails 并返回了交互式地图。有没有办法获得更静态的图像?
我尝试修改以下代码,但由于某种原因在手机上捏和缩放不起作用
if MODETECT.device.phone
@map_options =
disableDefaultUI: true #false has the street view capability
disableDoubleClickZoom: false
type: "ROADMAP" # HYBRID, ROADMAP, SATELLITE, TERRAIN
draggable: false # don't allow to drag map
scrollwheel: true
zoomControl: true
else
@map_options =
disableDefaultUI: true #false has the street view capability
disableDoubleClickZoom: false
type: "ROADMAP" # HYBRID, ROADMAP, SATELLITE, TERRAIN
draggable: true # don't allow to drag map
scrollwheel: false #can't use the scroll whell to zoom
zoomControl: true #widget that allows control zoom without pinch
...
createMap : ->
defaultOptions =
maxZoom: @map_options.maxZoom
minZoom: @map_options.minZoom
zoom: @map_options.zoom
center: @createLatLng(@map_options.center_latitude, @map_options.center_longitude)
mapTypeId: google.maps.MapTypeId[@map_options.type]
mapTypeControl: @map_options.mapTypeControl
disableDefaultUI: @map_options.disableDefaultUI
disableDoubleClickZoom: @map_options.disableDoubleClickZoom
draggable: @map_options.draggable
scrollwheel: @map_options.scrollwheel
zoomControl: @map_options.zoomControl
它似乎在可拖动的意义上起作用,但手机上的滚轮和 zoomControl 不起作用。