You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
1.1 KiB
37 lines
1.1 KiB
//
|
|
// AppDelegate.swift
|
|
// elpha-ios
|
|
//
|
|
// Created by Dwayne Harris on 8/25/18.
|
|
// Copyright © 2018 Elpha. All rights reserved.
|
|
//
|
|
|
|
import UIKit
|
|
|
|
extension Notification.Name {
|
|
static let didAuthenticate = Notification.Name("didAuthenticate")
|
|
static let didUnauthenticate = Notification.Name("didUnauthenticate")
|
|
static let didBecomeActive = Notification.Name("didBecomeActive")
|
|
}
|
|
|
|
@UIApplicationMain
|
|
class AppDelegate: UIResponder, UIApplicationDelegate {
|
|
var window: UIWindow?
|
|
|
|
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
|
|
return true
|
|
}
|
|
|
|
func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool {
|
|
if (url.host == "oauth") {
|
|
AuthenticationManager.handle(url: url)
|
|
}
|
|
|
|
return true
|
|
}
|
|
|
|
func applicationDidBecomeActive(_ application: UIApplication) {
|
|
// NotificationCenter.default.post(name: .didBecomeActive, object: nil)
|
|
}
|
|
}
|
|
|