2

我正在使用google_maps_flutter: ^0.5.24+1插件。即使draggable设置了属性,我也无法在地图内拖动标记true。这里有什么问题?我的代码:

                return GoogleMap(
                  initialCameraPosition: CameraPosition(
                    target: LatLng(placemark.position.latitude,
                        placemark.position.longitude),
                    zoom: 18,
                  ),
                  markers: Set<Marker>.of(
                    <Marker> [
                      Marker(
                        markerId: MarkerId("home"),
                        position: LatLng(placemark.position.latitude, placemark.position.longitude),
                        icon: BitmapDescriptor.defaultMarker,
                        infoWindow: InfoWindow(
                          title: placemark.name
                        ),
                        draggable: true,
                      ),
                    ]
                  ),
                  onMapCreated: (mapController) {
                    googleMapController = mapController;
                  },
                );
4

0 回答 0