小编Kri*_*nda的帖子

Swift Error - 使用未解析的标识符'kGMSMarkerAnimationPop'

我收到了这个错误

使用未解析的标识符'kGMSMarkerAnimationPop'

当我在Swift 3中使用以下代码时:

let camera = GMSCameraPosition.camera(withLatitude: location.coordinate.latitude, longitude: location.coordinate.longitude, zoom: 14)
mapView = GMSMapView.map(withFrame: CGRect.zero, camera: camera)
mapView?.isMyLocationEnabled = true
mapView?.settings.myLocationButton = true
view = mapView
let marker = GMSMarker()
marker.position = CLLocationCoordinate2D(latitude: location.coordinate.latitude, longitude: location.coordinate.longitude)
marker.title = "Sydney"
marker.snippet = "Australia"
marker.appearAnimation = kGMSMarkerAnimationPop // the error is occurring in this line
marker.map = mapView
locationManager.stopUpdatingLocation()
Run Code Online (Sandbox Code Playgroud)

我该如何解决?

google-maps ios gmsmapview swift3 xcode8

6
推荐指数
1
解决办法
2187
查看次数

标签 统计

gmsmapview ×1

google-maps ×1

ios ×1

swift3 ×1

xcode8 ×1