-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathAppDelegate.swift
33 lines (27 loc) · 953 Bytes
/
AppDelegate.swift
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import UIKit
import MappableMobile
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
/**
* Replace "your_api_key" with a valid developer key.
*/
let MAPKIT_API_KEY = "your_api_key"
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
/**
* Set API key before interaction with MapKit.
*/
MMKMapKit.setApiKey(MAPKIT_API_KEY)
/**
* You can optionaly customize locale.
* Otherwise MapKit will use default location.
*/
MMKMapKit.setLocale("en_US")
/**
* If you create instance of MMKMapKit not in application:didFinishLaunchingWithOptions:
* you should also explicitly call MMKMapKit.sharedInstance().onStart()
*/
MMKMapKit.sharedInstance()
return true
}
}