//
//  AppDelegate.swift
//  RxExample
//
//  Created by Krunoslav Zaher on 2/21/15.
//  Copyright © 2015 Krunoslav Zaher. All rights reserved.
//

import UIKit
import RxSwift

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {

    var window: UIWindow?

    func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool {
        if UIApplication.isInUITest {
            UIView.setAnimationsEnabled(false)
        }
        
        RxImagePickerDelegateProxy.register { RxImagePickerDelegateProxy(imagePicker: $0) }

        self.window?.rootViewController = NumbersViewController()
        self.window?.makeKeyAndVisible()
        
        #if DEBUG
//        _ = Observable<Int>.interval(.seconds(1), scheduler: MainScheduler.instance)
//            .subscribe(onNext: { _ in
////                print("Resource count \(RxSwift.Resources.total)")
//            })
        #endif

        return true
    }
}

