Documentation Archive Developer
Search

MapKit Changes

MapKit

Removed MKAnnotation.setCoordinate(CLLocationCoordinate2D)
Added MKCoordinateRegion.init()
Added MKCoordinateRegion.init(center: CLLocationCoordinate2D, span: MKCoordinateSpan)
Added MKCoordinateSpan.init()
Added MKCoordinateSpan.init(latitudeDelta: CLLocationDegrees, longitudeDelta: CLLocationDegrees)
Added MKMapPoint.init()
Added MKMapPoint.init(x: Double, y: Double)
Added MKMapRect.init()
Added MKMapRect.init(origin: MKMapPoint, size: MKMapSize)
Added MKMapSize.init()
Added MKMapSize.init(width: Double, height: Double)
Added MKTileOverlayPath.init()
Added MKTileOverlayPath.init(x: Int, y: Int, z: Int, contentScaleFactor: CGFloat)
Modified MKCoordinateRegion [struct]
Declaration
From
struct MKCoordinateRegion {
    var center: CLLocationCoordinate2D
    var span: MKCoordinateSpan
}
To
struct MKCoordinateRegion {
    var center: CLLocationCoordinate2D
    var span: MKCoordinateSpan
    init()
    init(center center: CLLocationCoordinate2D, span span: MKCoordinateSpan)
}

Modified MKCoordinateSpan [struct]
Declaration
From
struct MKCoordinateSpan {
    var latitudeDelta: CLLocationDegrees
    var longitudeDelta: CLLocationDegrees
}
To
struct MKCoordinateSpan {
    var latitudeDelta: CLLocationDegrees
    var longitudeDelta: CLLocationDegrees
    init()
    init(latitudeDelta latitudeDelta: CLLocationDegrees, longitudeDelta longitudeDelta: CLLocationDegrees)
}

Modified MKErrorCode.DirectionsNotFound
Introduction
FromiOS 8.0
ToiOS 7.0

Modified MKMapPoint [struct]
Declaration
From
struct MKMapPoint {
    var x: Double
    var y: Double
}
To
struct MKMapPoint {
    var x: Double
    var y: Double
    init()
    init(x x: Double, y y: Double)
}

Modified MKMapRect [struct]
Declaration
From
struct MKMapRect {
    var origin: MKMapPoint
    var size: MKMapSize
}
To
struct MKMapRect {
    var origin: MKMapPoint
    var size: MKMapSize
    init()
    init(origin origin: MKMapPoint, size size: MKMapSize)
}

Modified MKMapSize [struct]
Declaration
From
struct MKMapSize {
    var width: Double
    var height: Double
}
To
struct MKMapSize {
    var width: Double
    var height: Double
    init()
    init(width width: Double, height height: Double)
}

Modified MKMapView.annotationsInMapRect(MKMapRect) -> Set<NSObject>!
Declaration
From
func annotationsInMapRect(_ mapRect: MKMapRect) -> NSSet!
To
func annotationsInMapRect(_ mapRect: MKMapRect) -> Set<NSObject>!

Modified MKTileOverlayPath [struct]
Declaration
From
struct MKTileOverlayPath {
    var x: Int
    var y: Int
    var z: Int
    var contentScaleFactor: CGFloat
}
To
struct MKTileOverlayPath {
    var x: Int
    var y: Int
    var z: Int
    var contentScaleFactor: CGFloat
    init()
    init(x x: Int, y y: Int, z z: Int, contentScaleFactor contentScaleFactor: CGFloat)
}

Modified MKAnnotationCalloutInfoDidChangeNotification
Declaration
From
let MKAnnotationCalloutInfoDidChangeNotification: NSString!
To
let MKAnnotationCalloutInfoDidChangeNotification: String

Modified MKErrorDomain
Declaration
From
var MKErrorDomain: NSString!
To
let MKErrorDomain: String

Modified MKLaunchOptionsCameraKey
Declaration
From
let MKLaunchOptionsCameraKey: NSString!
To
let MKLaunchOptionsCameraKey: String

Modified MKLaunchOptionsDirectionsModeDriving
Declaration
From
let MKLaunchOptionsDirectionsModeDriving: NSString!
To
let MKLaunchOptionsDirectionsModeDriving: String

Modified MKLaunchOptionsDirectionsModeKey
Declaration
From
let MKLaunchOptionsDirectionsModeKey: NSString!
To
let MKLaunchOptionsDirectionsModeKey: String

Modified MKLaunchOptionsDirectionsModeWalking
Declaration
From
let MKLaunchOptionsDirectionsModeWalking: NSString!
To
let MKLaunchOptionsDirectionsModeWalking: String

Modified MKLaunchOptionsMapCenterKey
Declaration
From
let MKLaunchOptionsMapCenterKey: NSString!
To
let MKLaunchOptionsMapCenterKey: String

Modified MKLaunchOptionsMapSpanKey
Declaration
From
let MKLaunchOptionsMapSpanKey: NSString!
To
let MKLaunchOptionsMapSpanKey: String

Modified MKLaunchOptionsMapTypeKey
Declaration
From
let MKLaunchOptionsMapTypeKey: NSString!
To
let MKLaunchOptionsMapTypeKey: String

Modified MKLaunchOptionsShowsTrafficKey
Declaration
From
let MKLaunchOptionsShowsTrafficKey: NSString!
To
let MKLaunchOptionsShowsTrafficKey: String