diff --git a/WireGuard/WireGuard.xcodeproj/project.pbxproj b/WireGuard/WireGuard.xcodeproj/project.pbxproj index 97c5d56..a6a23f1 100644 --- a/WireGuard/WireGuard.xcodeproj/project.pbxproj +++ b/WireGuard/WireGuard.xcodeproj/project.pbxproj @@ -8,21 +8,19 @@ /* Begin PBXBuildFile section */ 6FF4AC18211EC46F002C96EB /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FF4AC17211EC46F002C96EB /* AppDelegate.swift */; }; - 6FF4AC1A211EC46F002C96EB /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FF4AC19211EC46F002C96EB /* ViewController.swift */; }; - 6FF4AC1D211EC46F002C96EB /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 6FF4AC1B211EC46F002C96EB /* Main.storyboard */; }; 6FF4AC1F211EC472002C96EB /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 6FF4AC1E211EC472002C96EB /* Assets.xcassets */; }; 6FF4AC22211EC472002C96EB /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 6FF4AC20211EC472002C96EB /* LaunchScreen.storyboard */; }; + 6FF4AC2F211F1F57002C96EB /* MainViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 6FF4AC2E211F1F57002C96EB /* MainViewController.swift */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ 6FF4AC14211EC46F002C96EB /* WireGuard.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = WireGuard.app; sourceTree = BUILT_PRODUCTS_DIR; }; 6FF4AC17211EC46F002C96EB /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; - 6FF4AC19211EC46F002C96EB /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; - 6FF4AC1C211EC46F002C96EB /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 6FF4AC1E211EC472002C96EB /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 6FF4AC21211EC472002C96EB /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 6FF4AC23211EC472002C96EB /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 6FF4AC2B211EC776002C96EB /* Developer.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Developer.xcconfig; path = Config/Developer.xcconfig; sourceTree = ""; }; + 6FF4AC2E211F1F57002C96EB /* MainViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MainViewController.swift; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -56,8 +54,7 @@ isa = PBXGroup; children = ( 6FF4AC17211EC46F002C96EB /* AppDelegate.swift */, - 6FF4AC19211EC46F002C96EB /* ViewController.swift */, - 6FF4AC1B211EC46F002C96EB /* Main.storyboard */, + 6FF4AC2E211F1F57002C96EB /* MainViewController.swift */, 6FF4AC1E211EC472002C96EB /* Assets.xcassets */, 6FF4AC20211EC472002C96EB /* LaunchScreen.storyboard */, 6FF4AC23211EC472002C96EB /* Info.plist */, @@ -126,7 +123,6 @@ files = ( 6FF4AC22211EC472002C96EB /* LaunchScreen.storyboard in Resources */, 6FF4AC1F211EC472002C96EB /* Assets.xcassets in Resources */, - 6FF4AC1D211EC46F002C96EB /* Main.storyboard in Resources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -137,22 +133,14 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - 6FF4AC1A211EC46F002C96EB /* ViewController.swift in Sources */, 6FF4AC18211EC46F002C96EB /* AppDelegate.swift in Sources */, + 6FF4AC2F211F1F57002C96EB /* MainViewController.swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; /* End PBXSourcesBuildPhase section */ /* Begin PBXVariantGroup section */ - 6FF4AC1B211EC46F002C96EB /* Main.storyboard */ = { - isa = PBXVariantGroup; - children = ( - 6FF4AC1C211EC46F002C96EB /* Base */, - ); - name = Main.storyboard; - sourceTree = ""; - }; 6FF4AC20211EC472002C96EB /* LaunchScreen.storyboard */ = { isa = PBXVariantGroup; children = ( diff --git a/WireGuard/WireGuard/AppDelegate.swift b/WireGuard/WireGuard/AppDelegate.swift index cd3796f..4052b7b 100644 --- a/WireGuard/WireGuard/AppDelegate.swift +++ b/WireGuard/WireGuard/AppDelegate.swift @@ -13,34 +13,16 @@ class AppDelegate: UIResponder, UIApplicationDelegate { var window: UIWindow? + func application(_ application: UIApplication, + didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + + let window = UIWindow(frame: UIScreen.main.bounds) + window.backgroundColor = UIColor.white + self.window = window + + window.rootViewController = MainViewController() + window.makeKeyAndVisible() - func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { - // Override point for customization after application launch. return true } - - func applicationWillResignActive(_ application: UIApplication) { - // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. - // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. - } - - func applicationDidEnterBackground(_ application: UIApplication) { - // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. - // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. - } - - func applicationWillEnterForeground(_ application: UIApplication) { - // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. - } - - func applicationDidBecomeActive(_ application: UIApplication) { - // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. - } - - func applicationWillTerminate(_ application: UIApplication) { - // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. - } - - } - diff --git a/WireGuard/WireGuard/Base.lproj/Main.storyboard b/WireGuard/WireGuard/Base.lproj/Main.storyboard deleted file mode 100644 index 03c13c2..0000000 --- a/WireGuard/WireGuard/Base.lproj/Main.storyboard +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WireGuard/WireGuard/Info.plist b/WireGuard/WireGuard/Info.plist index 8e30bef..f66b431 100644 --- a/WireGuard/WireGuard/Info.plist +++ b/WireGuard/WireGuard/Info.plist @@ -22,8 +22,6 @@ UILaunchStoryboardName LaunchScreen - UIMainStoryboardFile - Main UIRequiredDeviceCapabilities armv7 diff --git a/WireGuard/WireGuard/MainViewController.swift b/WireGuard/WireGuard/MainViewController.swift new file mode 100644 index 0000000..a296b5f --- /dev/null +++ b/WireGuard/WireGuard/MainViewController.swift @@ -0,0 +1,15 @@ +// +// MainViewController.swift +// WireGuard +// +// Created by Roopesh Chander on 11/08/18. +// Copyright © 2018 Roopesh Chander. All rights reserved. +// + +import UIKit + +class MainViewController: UIViewController { + override func loadView() { + self.view = UIView() + } +} diff --git a/WireGuard/WireGuard/ViewController.swift b/WireGuard/WireGuard/ViewController.swift deleted file mode 100644 index ad705df..0000000 --- a/WireGuard/WireGuard/ViewController.swift +++ /dev/null @@ -1,25 +0,0 @@ -// -// ViewController.swift -// WireGuard -// -// Created by Roopesh Chander on 11/08/18. -// Copyright © 2018 Roopesh Chander. All rights reserved. -// - -import UIKit - -class ViewController: UIViewController { - - override func viewDidLoad() { - super.viewDidLoad() - // Do any additional setup after loading the view, typically from a nib. - } - - override func didReceiveMemoryWarning() { - super.didReceiveMemoryWarning() - // Dispose of any resources that can be recreated. - } - - -} -