Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

- Add Swift version. The Swift version is just a translation of the o… #120

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -0,0 +1,319 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {

/* Begin PBXBuildFile section */
B72EA6631E71259700D3E7E4 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = B72EA6621E71259700D3E7E4 /* AppDelegate.swift */; };
B72EA6651E71259700D3E7E4 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = B72EA6641E71259700D3E7E4 /* ViewController.swift */; };
B72EA6681E71259700D3E7E4 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = B72EA6661E71259700D3E7E4 /* Main.storyboard */; };
B72EA66A1E71259700D3E7E4 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = B72EA6691E71259700D3E7E4 /* Assets.xcassets */; };
B72EA66D1E71259700D3E7E4 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = B72EA66B1E71259700D3E7E4 /* LaunchScreen.storyboard */; };
B72EA6751E71266E00D3E7E4 /* UIViewController+FDFullscreenPopGesture.swift in Sources */ = {isa = PBXBuildFile; fileRef = B72EA6741E71266E00D3E7E4 /* UIViewController+FDFullscreenPopGesture.swift */; };
B72EA6771E71267500D3E7E4 /* Random.swift in Sources */ = {isa = PBXBuildFile; fileRef = B72EA6761E71267500D3E7E4 /* Random.swift */; };
/* End PBXBuildFile section */

/* Begin PBXFileReference section */
B72EA65F1E71259700D3E7E4 /* FDFullscreenPop.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = FDFullscreenPop.app; sourceTree = BUILT_PRODUCTS_DIR; };
B72EA6621E71259700D3E7E4 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
B72EA6641E71259700D3E7E4 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
B72EA6671E71259700D3E7E4 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
B72EA6691E71259700D3E7E4 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
B72EA66C1E71259700D3E7E4 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
B72EA66E1E71259700D3E7E4 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
B72EA6741E71266E00D3E7E4 /* UIViewController+FDFullscreenPopGesture.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "UIViewController+FDFullscreenPopGesture.swift"; sourceTree = "<group>"; };
B72EA6761E71267500D3E7E4 /* Random.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Random.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
B72EA65C1E71259700D3E7E4 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
B72EA6561E71259700D3E7E4 = {
isa = PBXGroup;
children = (
B72EA6611E71259700D3E7E4 /* FDFullscreenPop */,
B72EA6601E71259700D3E7E4 /* Products */,
);
sourceTree = "<group>";
};
B72EA6601E71259700D3E7E4 /* Products */ = {
isa = PBXGroup;
children = (
B72EA65F1E71259700D3E7E4 /* FDFullscreenPop.app */,
);
name = Products;
sourceTree = "<group>";
};
B72EA6611E71259700D3E7E4 /* FDFullscreenPop */ = {
isa = PBXGroup;
children = (
B72EA6621E71259700D3E7E4 /* AppDelegate.swift */,
B72EA6641E71259700D3E7E4 /* ViewController.swift */,
B72EA6661E71259700D3E7E4 /* Main.storyboard */,
B72EA6691E71259700D3E7E4 /* Assets.xcassets */,
B72EA66B1E71259700D3E7E4 /* LaunchScreen.storyboard */,
B72EA66E1E71259700D3E7E4 /* Info.plist */,
B72EA6741E71266E00D3E7E4 /* UIViewController+FDFullscreenPopGesture.swift */,
B72EA6761E71267500D3E7E4 /* Random.swift */,
);
path = FDFullscreenPop;
sourceTree = "<group>";
};
/* End PBXGroup section */

/* Begin PBXNativeTarget section */
B72EA65E1E71259700D3E7E4 /* FDFullscreenPop */ = {
isa = PBXNativeTarget;
buildConfigurationList = B72EA6711E71259700D3E7E4 /* Build configuration list for PBXNativeTarget "FDFullscreenPop" */;
buildPhases = (
B72EA65B1E71259700D3E7E4 /* Sources */,
B72EA65C1E71259700D3E7E4 /* Frameworks */,
B72EA65D1E71259700D3E7E4 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = FDFullscreenPop;
productName = FDFullscreenPop;
productReference = B72EA65F1E71259700D3E7E4 /* FDFullscreenPop.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */

/* Begin PBXProject section */
B72EA6571E71259700D3E7E4 /* Project object */ = {
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0820;
LastUpgradeCheck = 0820;
ORGANIZATIONNAME = lionhylra;
TargetAttributes = {
B72EA65E1E71259700D3E7E4 = {
CreatedOnToolsVersion = 8.2.1;
DevelopmentTeam = 7K48CFLDT2;
ProvisioningStyle = Automatic;
};
};
};
buildConfigurationList = B72EA65A1E71259700D3E7E4 /* Build configuration list for PBXProject "FDFullscreenPop" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = B72EA6561E71259700D3E7E4;
productRefGroup = B72EA6601E71259700D3E7E4 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
B72EA65E1E71259700D3E7E4 /* FDFullscreenPop */,
);
};
/* End PBXProject section */

/* Begin PBXResourcesBuildPhase section */
B72EA65D1E71259700D3E7E4 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
B72EA66D1E71259700D3E7E4 /* LaunchScreen.storyboard in Resources */,
B72EA66A1E71259700D3E7E4 /* Assets.xcassets in Resources */,
B72EA6681E71259700D3E7E4 /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */

/* Begin PBXSourcesBuildPhase section */
B72EA65B1E71259700D3E7E4 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
B72EA6751E71266E00D3E7E4 /* UIViewController+FDFullscreenPopGesture.swift in Sources */,
B72EA6771E71267500D3E7E4 /* Random.swift in Sources */,
B72EA6651E71259700D3E7E4 /* ViewController.swift in Sources */,
B72EA6631E71259700D3E7E4 /* AppDelegate.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */

/* Begin PBXVariantGroup section */
B72EA6661E71259700D3E7E4 /* Main.storyboard */ = {
isa = PBXVariantGroup;
children = (
B72EA6671E71259700D3E7E4 /* Base */,
);
name = Main.storyboard;
sourceTree = "<group>";
};
B72EA66B1E71259700D3E7E4 /* LaunchScreen.storyboard */ = {
isa = PBXVariantGroup;
children = (
B72EA66C1E71259700D3E7E4 /* Base */,
);
name = LaunchScreen.storyboard;
sourceTree = "<group>";
};
/* End PBXVariantGroup section */

/* Begin XCBuildConfiguration section */
B72EA66F1E71259700D3E7E4 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.2;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
B72EA6701E71259700D3E7E4 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 10.2;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
};
name = Release;
};
B72EA6721E71259700D3E7E4 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
DEVELOPMENT_TEAM = 7K48CFLDT2;
INFOPLIST_FILE = FDFullscreenPop/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.lionhylra.FDFullscreenPop;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
};
name = Debug;
};
B72EA6731E71259700D3E7E4 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
DEVELOPMENT_TEAM = 7K48CFLDT2;
INFOPLIST_FILE = FDFullscreenPop/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.lionhylra.FDFullscreenPop;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
};
name = Release;
};
/* End XCBuildConfiguration section */

/* Begin XCConfigurationList section */
B72EA65A1E71259700D3E7E4 /* Build configuration list for PBXProject "FDFullscreenPop" */ = {
isa = XCConfigurationList;
buildConfigurations = (
B72EA66F1E71259700D3E7E4 /* Debug */,
B72EA6701E71259700D3E7E4 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
B72EA6711E71259700D3E7E4 /* Build configuration list for PBXNativeTarget "FDFullscreenPop" */ = {
isa = XCConfigurationList;
buildConfigurations = (
B72EA6721E71259700D3E7E4 /* Debug */,
B72EA6731E71259700D3E7E4 /* Release */,
);
defaultConfigurationIsVisible = 0;
};
/* End XCConfigurationList section */
};
rootObject = B72EA6571E71259700D3E7E4 /* Project object */;
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

@@ -0,0 +1,46 @@
//
// AppDelegate.swift
// FDFullscreenPop
//
// Created by Yilei on 9/3/17.
// Copyright © 2017 lionhylra. All rights reserved.
//

import UIKit

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {

var window: UIWindow?


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:.
}


}