diff --git a/Poll/Poll.xcodeproj/project.pbxproj b/Poll/Poll.xcodeproj/project.pbxproj new file mode 100644 index 0000000..7ceadad --- /dev/null +++ b/Poll/Poll.xcodeproj/project.pbxproj @@ -0,0 +1,385 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + 4B00C3952166A7EB0026C355 /* Voting.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4B00C3942166A7EB0026C355 /* Voting.storyboard */; }; + 4BFCA4822166BA10004CE413 /* VotingViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFCA4812166BA10004CE413 /* VotingViewController.swift */; }; + 4BFCA4842166BB44004CE413 /* Results.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4BFCA4832166BB44004CE413 /* Results.storyboard */; }; + 4BFCA4862166BBCC004CE413 /* ResultsTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFCA4852166BBCC004CE413 /* ResultsTableViewController.swift */; }; + 4BFCA4882166BBF5004CE413 /* Combined.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4BFCA4872166BBF5004CE413 /* Combined.storyboard */; }; + 4BFCA48A2166C02E004CE413 /* CombinedViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFCA4892166C02E004CE413 /* CombinedViewController.swift */; }; + 4BFCA48C2166C2C8004CE413 /* PollingTabBarViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFCA48B2166C2C8004CE413 /* PollingTabBarViewController.swift */; }; + 4BFCA48E2166C523004CE413 /* VoteControllerProtocol.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFCA48D2166C523004CE413 /* VoteControllerProtocol.swift */; }; + 4BFD441D21669F550033CA27 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFD441C21669F550033CA27 /* AppDelegate.swift */; }; + 4BFD441F21669F550033CA27 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFD441E21669F550033CA27 /* ViewController.swift */; }; + 4BFD442221669F550033CA27 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4BFD442021669F550033CA27 /* Main.storyboard */; }; + 4BFD442421669F560033CA27 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4BFD442321669F560033CA27 /* Assets.xcassets */; }; + 4BFD442721669F560033CA27 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4BFD442521669F560033CA27 /* LaunchScreen.storyboard */; }; + 4BFD442F21669F750033CA27 /* Vote.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFD442E21669F750033CA27 /* Vote.swift */; }; + 4BFD443121669FC80033CA27 /* LambdaLogoAssets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4BFD443021669FC70033CA27 /* LambdaLogoAssets.xcassets */; }; + 4BFD44332166A1350033CA27 /* VoteController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4BFD44322166A1350033CA27 /* VoteController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 4B00C3942166A7EB0026C355 /* Voting.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = Voting.storyboard; sourceTree = ""; }; + 4BFCA4812166BA10004CE413 /* VotingViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VotingViewController.swift; sourceTree = ""; }; + 4BFCA4832166BB44004CE413 /* Results.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = Results.storyboard; sourceTree = ""; }; + 4BFCA4852166BBCC004CE413 /* ResultsTableViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ResultsTableViewController.swift; sourceTree = ""; }; + 4BFCA4872166BBF5004CE413 /* Combined.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = Combined.storyboard; sourceTree = ""; }; + 4BFCA4892166C02E004CE413 /* CombinedViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CombinedViewController.swift; sourceTree = ""; }; + 4BFCA48B2166C2C8004CE413 /* PollingTabBarViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PollingTabBarViewController.swift; sourceTree = ""; }; + 4BFCA48D2166C523004CE413 /* VoteControllerProtocol.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VoteControllerProtocol.swift; sourceTree = ""; }; + 4BFD441921669F550033CA27 /* Poll.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Poll.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 4BFD441C21669F550033CA27 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 4BFD441E21669F550033CA27 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + 4BFD442121669F550033CA27 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 4BFD442321669F560033CA27 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 4BFD442621669F560033CA27 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 4BFD442821669F560033CA27 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 4BFD442E21669F750033CA27 /* Vote.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Vote.swift; sourceTree = ""; }; + 4BFD443021669FC70033CA27 /* LambdaLogoAssets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = LambdaLogoAssets.xcassets; sourceTree = ""; }; + 4BFD44322166A1350033CA27 /* VoteController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VoteController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 4BFD441621669F550033CA27 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 4BFD441021669F550033CA27 = { + isa = PBXGroup; + children = ( + 4BFD441B21669F550033CA27 /* Poll */, + 4BFD441A21669F550033CA27 /* Products */, + ); + sourceTree = ""; + }; + 4BFD441A21669F550033CA27 /* Products */ = { + isa = PBXGroup; + children = ( + 4BFD441921669F550033CA27 /* Poll.app */, + ); + name = Products; + sourceTree = ""; + }; + 4BFD441B21669F550033CA27 /* Poll */ = { + isa = PBXGroup; + children = ( + 4BFD441C21669F550033CA27 /* AppDelegate.swift */, + 4BFD441E21669F550033CA27 /* ViewController.swift */, + 4BFD442021669F550033CA27 /* Main.storyboard */, + 4BFCA48D2166C523004CE413 /* VoteControllerProtocol.swift */, + 4BFCA48B2166C2C8004CE413 /* PollingTabBarViewController.swift */, + 4B00C3942166A7EB0026C355 /* Voting.storyboard */, + 4BFCA4812166BA10004CE413 /* VotingViewController.swift */, + 4BFCA4832166BB44004CE413 /* Results.storyboard */, + 4BFCA4872166BBF5004CE413 /* Combined.storyboard */, + 4BFCA4892166C02E004CE413 /* CombinedViewController.swift */, + 4BFCA4852166BBCC004CE413 /* ResultsTableViewController.swift */, + 4BFD442E21669F750033CA27 /* Vote.swift */, + 4BFD44322166A1350033CA27 /* VoteController.swift */, + 4BFD442321669F560033CA27 /* Assets.xcassets */, + 4BFD442521669F560033CA27 /* LaunchScreen.storyboard */, + 4BFD442821669F560033CA27 /* Info.plist */, + 4BFD443021669FC70033CA27 /* LambdaLogoAssets.xcassets */, + ); + path = Poll; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 4BFD441821669F550033CA27 /* Poll */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4BFD442B21669F560033CA27 /* Build configuration list for PBXNativeTarget "Poll" */; + buildPhases = ( + 4BFD441521669F550033CA27 /* Sources */, + 4BFD441621669F550033CA27 /* Frameworks */, + 4BFD441721669F550033CA27 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Poll; + productName = Poll; + productReference = 4BFD441921669F550033CA27 /* Poll.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 4BFD441121669F550033CA27 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 1000; + LastUpgradeCheck = 1000; + ORGANIZATIONNAME = "Paul Yi"; + TargetAttributes = { + 4BFD441821669F550033CA27 = { + CreatedOnToolsVersion = 10.0; + }; + }; + }; + buildConfigurationList = 4BFD441421669F550033CA27 /* Build configuration list for PBXProject "Poll" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 4BFD441021669F550033CA27; + productRefGroup = 4BFD441A21669F550033CA27 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 4BFD441821669F550033CA27 /* Poll */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 4BFD441721669F550033CA27 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4BFD442721669F560033CA27 /* LaunchScreen.storyboard in Resources */, + 4B00C3952166A7EB0026C355 /* Voting.storyboard in Resources */, + 4BFD442421669F560033CA27 /* Assets.xcassets in Resources */, + 4BFCA4842166BB44004CE413 /* Results.storyboard in Resources */, + 4BFD443121669FC80033CA27 /* LambdaLogoAssets.xcassets in Resources */, + 4BFCA4882166BBF5004CE413 /* Combined.storyboard in Resources */, + 4BFD442221669F550033CA27 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 4BFD441521669F550033CA27 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4BFCA4862166BBCC004CE413 /* ResultsTableViewController.swift in Sources */, + 4BFD441F21669F550033CA27 /* ViewController.swift in Sources */, + 4BFCA48E2166C523004CE413 /* VoteControllerProtocol.swift in Sources */, + 4BFCA48A2166C02E004CE413 /* CombinedViewController.swift in Sources */, + 4BFD44332166A1350033CA27 /* VoteController.swift in Sources */, + 4BFCA48C2166C2C8004CE413 /* PollingTabBarViewController.swift in Sources */, + 4BFD442F21669F750033CA27 /* Vote.swift in Sources */, + 4BFD441D21669F550033CA27 /* AppDelegate.swift in Sources */, + 4BFCA4822166BA10004CE413 /* VotingViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 4BFD442021669F550033CA27 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 4BFD442121669F550033CA27 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 4BFD442521669F560033CA27 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 4BFD442621669F560033CA27 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 4BFD442921669F560033CA27 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = 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_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + 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 = 12.0; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 4BFD442A21669F560033CA27 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = 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_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "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 = gnu11; + 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 = 12.0; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 4BFD442C21669F560033CA27 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = 6Z7SV6KDUH; + INFOPLIST_FILE = Poll/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.paulyi.Poll; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.2; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 4BFD442D21669F560033CA27 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = 6Z7SV6KDUH; + INFOPLIST_FILE = Poll/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.paulyi.Poll; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.2; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 4BFD441421669F550033CA27 /* Build configuration list for PBXProject "Poll" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4BFD442921669F560033CA27 /* Debug */, + 4BFD442A21669F560033CA27 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4BFD442B21669F560033CA27 /* Build configuration list for PBXNativeTarget "Poll" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4BFD442C21669F560033CA27 /* Debug */, + 4BFD442D21669F560033CA27 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 4BFD441121669F550033CA27 /* Project object */; +} diff --git a/Poll/Poll.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/Poll/Poll.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..9d02d16 --- /dev/null +++ b/Poll/Poll.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/Poll/Poll.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/Poll/Poll.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/Poll/Poll.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/Poll/Poll.xcodeproj/project.xcworkspace/xcuserdata/paulyi.xcuserdatad/UserInterfaceState.xcuserstate b/Poll/Poll.xcodeproj/project.xcworkspace/xcuserdata/paulyi.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..6e1383a Binary files /dev/null and b/Poll/Poll.xcodeproj/project.xcworkspace/xcuserdata/paulyi.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/Poll/Poll.xcodeproj/xcuserdata/paulyi.xcuserdatad/xcschemes/xcschememanagement.plist b/Poll/Poll.xcodeproj/xcuserdata/paulyi.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..aecce71 --- /dev/null +++ b/Poll/Poll.xcodeproj/xcuserdata/paulyi.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,14 @@ + + + + + SchemeUserState + + Poll.xcscheme + + orderHint + 0 + + + + diff --git a/Poll/Poll/AppDelegate.swift b/Poll/Poll/AppDelegate.swift new file mode 100644 index 0000000..e9e2ee8 --- /dev/null +++ b/Poll/Poll/AppDelegate.swift @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// Poll +// +// Created by Paul Yi on 10/4/18. +// Copyright © 2018 Paul Yi. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: 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/Poll/Poll/Assets.xcassets/AppIcon.appiconset/Contents.json b/Poll/Poll/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ b/Poll/Poll/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Poll/Poll/Assets.xcassets/Contents.json b/Poll/Poll/Assets.xcassets/Contents.json new file mode 100644 index 0000000..da4a164 --- /dev/null +++ b/Poll/Poll/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Poll/Poll/Base.lproj/LaunchScreen.storyboard b/Poll/Poll/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 0000000..bfa3612 --- /dev/null +++ b/Poll/Poll/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Poll/Poll/Base.lproj/Main.storyboard b/Poll/Poll/Base.lproj/Main.storyboard new file mode 100644 index 0000000..6c45590 --- /dev/null +++ b/Poll/Poll/Base.lproj/Main.storyboard @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Poll/Poll/Combined.storyboard b/Poll/Poll/Combined.storyboard new file mode 100644 index 0000000..6333a61 --- /dev/null +++ b/Poll/Poll/Combined.storyboard @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Poll/Poll/CombinedViewController.swift b/Poll/Poll/CombinedViewController.swift new file mode 100644 index 0000000..492aa75 --- /dev/null +++ b/Poll/Poll/CombinedViewController.swift @@ -0,0 +1,19 @@ +import UIKit + +class CombinedViewController: UIViewController, VoteControllerProtocol { + var voteController: VoteController? + + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + if segue.identifier == "EmbedVotingPage" { + if let viewController = segue.destination as? VoteControllerProtocol { + viewController.voteController = voteController + } + } else if segue.identifier == "EmbedResultsTable" { + if let viewController = segue.destination as? VoteControllerProtocol { + viewController.voteController = voteController + } + } + } + + +} diff --git a/Poll/Poll/Info.plist b/Poll/Poll/Info.plist new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ b/Poll/Poll/Info.plist @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git a/Poll/Poll/LambdaLogoAssets.xcassets/Contents.json b/Poll/Poll/LambdaLogoAssets.xcassets/Contents.json new file mode 100644 index 0000000..da4a164 --- /dev/null +++ b/Poll/Poll/LambdaLogoAssets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Contents.json b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Contents.json new file mode 100644 index 0000000..a8c4d08 --- /dev/null +++ b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "Lambda_Logo_Full.pdf", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "Lambda_Logo_Full-1.pdf", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "Lambda_Logo_Full-2.pdf", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full-1.pdf b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full-1.pdf new file mode 100644 index 0000000..3a8651d Binary files /dev/null and b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full-1.pdf differ diff --git a/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full-2.pdf b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full-2.pdf new file mode 100644 index 0000000..3a8651d Binary files /dev/null and b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full-2.pdf differ diff --git a/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full.pdf b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full.pdf new file mode 100644 index 0000000..3a8651d Binary files /dev/null and b/Poll/Poll/LambdaLogoAssets.xcassets/Lambda_Logo_Full.imageset/Lambda_Logo_Full.pdf differ diff --git a/Poll/Poll/PollingTabBarViewController.swift b/Poll/Poll/PollingTabBarViewController.swift new file mode 100644 index 0000000..fe1f488 --- /dev/null +++ b/Poll/Poll/PollingTabBarViewController.swift @@ -0,0 +1,21 @@ +import UIKit + +class PollingTabBarViewController: UITabBarController { + + let voteController = VoteController() + + func passVoteControllerToChildViewControllers() { + for childVC in children { + guard let childVC = childVC as? VoteControllerProtocol else { return } + } + + } + + override func viewDidLoad() { + super.viewDidLoad() + + passVoteControllerToChildViewControllers() + } + + +} diff --git a/Poll/Poll/Results.storyboard b/Poll/Poll/Results.storyboard new file mode 100644 index 0000000..80ab9bd --- /dev/null +++ b/Poll/Poll/Results.storyboard @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Poll/Poll/ResultsTableViewController.swift b/Poll/Poll/ResultsTableViewController.swift new file mode 100644 index 0000000..5261da4 --- /dev/null +++ b/Poll/Poll/ResultsTableViewController.swift @@ -0,0 +1,34 @@ +// +// ResultsTableViewController.swift +// Poll +// +// Created by Paul Yi on 10/4/18. +// Copyright © 2018 Paul Yi. All rights reserved. +// + +import UIKit + +class ResultsTableViewController: UITableViewController, VoteControllerProtocol { + var voteController: VoteController? + + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + return voteController?.votes.count ?? 0 + } + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) + + let vote = voteController?.votes[indexPath.row] + + cell.textLabel?.text = vote?.name + cell.detailTextLabel?.text = vote?.response + + return cell + } + + override func viewWillAppear(_ animated: Bool) { + tableView.reloadData() + } + +} diff --git a/Poll/Poll/ViewController.swift b/Poll/Poll/ViewController.swift new file mode 100644 index 0000000..0aa2acf --- /dev/null +++ b/Poll/Poll/ViewController.swift @@ -0,0 +1,20 @@ +// +// ViewController.swift +// Poll +// +// Created by Paul Yi on 10/4/18. +// Copyright © 2018 Paul Yi. 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. + } + + +} + diff --git a/Poll/Poll/Vote.swift b/Poll/Poll/Vote.swift new file mode 100644 index 0000000..8549a43 --- /dev/null +++ b/Poll/Poll/Vote.swift @@ -0,0 +1,11 @@ +import UIKit + +class Vote { + var name: String + var response: String + + init(name: String, response: String) { + self.name = name + self.response = response + } +} diff --git a/Poll/Poll/VoteController.swift b/Poll/Poll/VoteController.swift new file mode 100644 index 0000000..f355e77 --- /dev/null +++ b/Poll/Poll/VoteController.swift @@ -0,0 +1,11 @@ +import UIKit + +class VoteController { + + var votes: [Vote] = [] + + func createVote(name: String, response: String) { + let vote = Vote(name: name, response: response) + votes.append(vote) + } + } diff --git a/Poll/Poll/VoteControllerProtocol.swift b/Poll/Poll/VoteControllerProtocol.swift new file mode 100644 index 0000000..e0b8b92 --- /dev/null +++ b/Poll/Poll/VoteControllerProtocol.swift @@ -0,0 +1,5 @@ +import UIKit + +protocol VoteControllerProtocol: class { + var voteController: VoteController? { get set } +} diff --git a/Poll/Poll/Voting.storyboard b/Poll/Poll/Voting.storyboard new file mode 100644 index 0000000..eaf75f7 --- /dev/null +++ b/Poll/Poll/Voting.storyboard @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Poll/Poll/VotingViewController.swift b/Poll/Poll/VotingViewController.swift new file mode 100644 index 0000000..20c3cdf --- /dev/null +++ b/Poll/Poll/VotingViewController.swift @@ -0,0 +1,24 @@ +import UIKit + +class VotingViewController: UIViewController, VoteControllerProtocol { + + var voteController: VoteController? + + + @IBOutlet weak var nameTextField: UITextField! + @IBOutlet weak var responseTextField: UITextField! + + @IBAction func submitTapped(_ sender: Any) { + guard let name = nameTextField.text, + let response = responseTextField.text else { return } + + voteController?.createVote(name: name, response: response) + + } + + override func viewDidLoad() { + super.viewDidLoad() + + // Do any additional setup after loading the view. + } +}