-
-
Notifications
You must be signed in to change notification settings - Fork 48
/
AppDelegate.swift
40 lines (34 loc) · 1.39 KB
/
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
34
35
36
37
38
39
40
//
// AppDelegate.swift
// FlyoverKit-Example
//
// Created by Sven Tiigi on 22.04.18.
// Copyright © 2018 FlyoverKit. All rights reserved.
//
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
/// The UINavigationController with ViewController as root
lazy private var navigationController: UINavigationController = {
let navigationController = UINavigationController(rootViewController: ViewController())
navigationController.navigationBar.prefersLargeTitles = true
navigationController.navigationBar.largeTitleTextAttributes = [
.foregroundColor: UIColor.main
]
navigationController.view.backgroundColor = .white
navigationController.navigationBar.tintColor = .main
navigationController.navigationBar.titleTextAttributes = [
.foregroundColor: UIColor.main
]
return navigationController
}()
func application(_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
// Override point for customization after application launch.
self.window = UIWindow(frame: UIScreen.main.bounds)
self.window?.rootViewController = self.navigationController
self.window?.makeKeyAndVisible()
return true
}
}