How to show blue pin with dot (circle) in MKMapView in IPhone

后端 未结 4 2259
礼貌的吻别
礼貌的吻别 2020-12-31 21:04

my question may seem a bit complicated but let me clarify. i am using mkmapview , in this i want to show current user location with blue dot and circle , but this isn\'t rea

4条回答
  •  余生分开走
    2020-12-31 21:51

    For SWIFT 3

    if (annotation.isKind(of: MKUserLocation.self)){
            return nil
        }
    

    This will allow you to show a blue dot for your user's location in swift 3.

    Put this code in the mapView viewFor annotation func

提交回复
热议问题