diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift.xcodeproj/project.pbxproj b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift.xcodeproj/project.pbxproj new file mode 100644 index 00000000..96e10450 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift.xcodeproj/project.pbxproj @@ -0,0 +1,418 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + D13D3553222F217200664B67 /* PhotosCollectionViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = D13D3552222F217200664B67 /* PhotosCollectionViewController.swift */; }; + D13D3556222F23CB00664B67 /* PhotoDetailViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = D13D3555222F23CB00664B67 /* PhotoDetailViewController.swift */; }; + D1916396222DF268005CE4FD /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = D1916395222DF268005CE4FD /* AppDelegate.m */; }; + D191639C222DF268005CE4FD /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D191639A222DF268005CE4FD /* Main.storyboard */; }; + D191639E222DF26A005CE4FD /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = D191639D222DF26A005CE4FD /* Assets.xcassets */; }; + D19163A1222DF26A005CE4FD /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D191639F222DF26A005CE4FD /* LaunchScreen.storyboard */; }; + D19163A4222DF26A005CE4FD /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = D19163A3222DF26A005CE4FD /* main.m */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + D13D3551222F217100664B67 /* Astronomy ObjC Swift-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Astronomy ObjC Swift-Bridging-Header.h"; sourceTree = ""; }; + D13D3552222F217200664B67 /* PhotosCollectionViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PhotosCollectionViewController.swift; sourceTree = ""; }; + D13D3555222F23CB00664B67 /* PhotoDetailViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PhotoDetailViewController.swift; sourceTree = ""; }; + D1916391222DF268005CE4FD /* Astronomy ObjC Swift.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Astronomy ObjC Swift.app"; sourceTree = BUILT_PRODUCTS_DIR; }; + D1916394222DF268005CE4FD /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; + D1916395222DF268005CE4FD /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; + D191639B222DF268005CE4FD /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + D191639D222DF26A005CE4FD /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + D19163A0222DF26A005CE4FD /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + D19163A2222DF26A005CE4FD /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + D19163A3222DF26A005CE4FD /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + D191638E222DF268005CE4FD /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + D13D3547222F1F1600664B67 /* Resources */ = { + isa = PBXGroup; + children = ( + D191639A222DF268005CE4FD /* Main.storyboard */, + D191639F222DF26A005CE4FD /* LaunchScreen.storyboard */, + D19163A2222DF26A005CE4FD /* Info.plist */, + D191639D222DF26A005CE4FD /* Assets.xcassets */, + D19163A3222DF26A005CE4FD /* main.m */, + ); + path = Resources; + sourceTree = ""; + }; + D13D3548222F1F1A00664B67 /* Utilities */ = { + isa = PBXGroup; + children = ( + ); + path = Utilities; + sourceTree = ""; + }; + D13D3549222F1F1C00664B67 /* Operations */ = { + isa = PBXGroup; + children = ( + ); + path = Operations; + sourceTree = ""; + }; + D13D354A222F1F2700664B67 /* Networking */ = { + isa = PBXGroup; + children = ( + ); + path = Networking; + sourceTree = ""; + }; + D13D354B222F1F2800664B67 /* ViewControllers */ = { + isa = PBXGroup; + children = ( + D13D3552222F217200664B67 /* PhotosCollectionViewController.swift */, + D13D3555222F23CB00664B67 /* PhotoDetailViewController.swift */, + ); + path = ViewControllers; + sourceTree = ""; + }; + D13D354C222F1F2A00664B67 /* Views */ = { + isa = PBXGroup; + children = ( + ); + path = Views; + sourceTree = ""; + }; + D13D354D222F1F5F00664B67 /* Delegates */ = { + isa = PBXGroup; + children = ( + D1916394222DF268005CE4FD /* AppDelegate.h */, + D1916395222DF268005CE4FD /* AppDelegate.m */, + ); + path = Delegates; + sourceTree = ""; + }; + D13D3554222F217C00664B67 /* Bridging */ = { + isa = PBXGroup; + children = ( + D13D3551222F217100664B67 /* Astronomy ObjC Swift-Bridging-Header.h */, + ); + path = Bridging; + sourceTree = ""; + }; + D1916388222DF268005CE4FD = { + isa = PBXGroup; + children = ( + D1916393222DF268005CE4FD /* Astronomy ObjC Swift */, + D1916392222DF268005CE4FD /* Products */, + ); + sourceTree = ""; + }; + D1916392222DF268005CE4FD /* Products */ = { + isa = PBXGroup; + children = ( + D1916391222DF268005CE4FD /* Astronomy ObjC Swift.app */, + ); + name = Products; + sourceTree = ""; + }; + D1916393222DF268005CE4FD /* Astronomy ObjC Swift */ = { + isa = PBXGroup; + children = ( + D13D354D222F1F5F00664B67 /* Delegates */, + D13D354C222F1F2A00664B67 /* Views */, + D13D354B222F1F2800664B67 /* ViewControllers */, + D13D354A222F1F2700664B67 /* Networking */, + D13D3549222F1F1C00664B67 /* Operations */, + D13D3548222F1F1A00664B67 /* Utilities */, + D13D3554222F217C00664B67 /* Bridging */, + D13D3547222F1F1600664B67 /* Resources */, + ); + path = "Astronomy ObjC Swift"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + D1916390222DF268005CE4FD /* Astronomy ObjC Swift */ = { + isa = PBXNativeTarget; + buildConfigurationList = D19163A7222DF26A005CE4FD /* Build configuration list for PBXNativeTarget "Astronomy ObjC Swift" */; + buildPhases = ( + D191638D222DF268005CE4FD /* Sources */, + D191638E222DF268005CE4FD /* Frameworks */, + D191638F222DF268005CE4FD /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = "Astronomy ObjC Swift"; + productName = "Astronomy ObjC Swift"; + productReference = D1916391222DF268005CE4FD /* Astronomy ObjC Swift.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + D1916389222DF268005CE4FD /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 1010; + ORGANIZATIONNAME = "Benjamin Hakes"; + TargetAttributes = { + D1916390222DF268005CE4FD = { + CreatedOnToolsVersion = 10.1; + LastSwiftMigration = 1010; + }; + }; + }; + buildConfigurationList = D191638C222DF268005CE4FD /* Build configuration list for PBXProject "Astronomy ObjC Swift" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = D1916388222DF268005CE4FD; + productRefGroup = D1916392222DF268005CE4FD /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + D1916390222DF268005CE4FD /* Astronomy ObjC Swift */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + D191638F222DF268005CE4FD /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + D19163A1222DF26A005CE4FD /* LaunchScreen.storyboard in Resources */, + D191639E222DF26A005CE4FD /* Assets.xcassets in Resources */, + D191639C222DF268005CE4FD /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + D191638D222DF268005CE4FD /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + D13D3553222F217200664B67 /* PhotosCollectionViewController.swift in Sources */, + D19163A4222DF26A005CE4FD /* main.m in Sources */, + D13D3556222F23CB00664B67 /* PhotoDetailViewController.swift in Sources */, + D1916396222DF268005CE4FD /* AppDelegate.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + D191639A222DF268005CE4FD /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + D191639B222DF268005CE4FD /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + D191639F222DF26A005CE4FD /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + D19163A0222DF26A005CE4FD /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + D19163A5222DF26A005CE4FD /* 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.1; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + }; + name = Debug; + }; + D19163A6222DF26A005CE4FD /* 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.1; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + D19163A8222DF26A005CE4FD /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = S5U94G8XN2; + INFOPLIST_FILE = "Astronomy ObjC Swift/Resources/Info.plist"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = "com.mettabits.Astronomy-ObjC-Swift"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Astronomy ObjC Swift/Bridging/Astronomy ObjC Swift-Bridging-Header.h"; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + SWIFT_VERSION = 4.2; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + D19163A9222DF26A005CE4FD /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CLANG_ENABLE_MODULES = YES; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = S5U94G8XN2; + INFOPLIST_FILE = "Astronomy ObjC Swift/Resources/Info.plist"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = "com.mettabits.Astronomy-ObjC-Swift"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "Astronomy ObjC Swift/Bridging/Astronomy ObjC Swift-Bridging-Header.h"; + SWIFT_VERSION = 4.2; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + D191638C222DF268005CE4FD /* Build configuration list for PBXProject "Astronomy ObjC Swift" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + D19163A5222DF26A005CE4FD /* Debug */, + D19163A6222DF26A005CE4FD /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + D19163A7222DF26A005CE4FD /* Build configuration list for PBXNativeTarget "Astronomy ObjC Swift" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + D19163A8222DF26A005CE4FD /* Debug */, + D19163A9222DF26A005CE4FD /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = D1916389222DF268005CE4FD /* Project object */; +} diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Bridging/Astronomy ObjC Swift-Bridging-Header.h b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Bridging/Astronomy ObjC Swift-Bridging-Header.h new file mode 100644 index 00000000..6baabb99 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Bridging/Astronomy ObjC Swift-Bridging-Header.h @@ -0,0 +1,5 @@ +// +// Use this file to import your target's public headers that you would like to expose to Swift. +// + +//#import "BHPerson.h" diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Delegates/AppDelegate.h b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Delegates/AppDelegate.h new file mode 100644 index 00000000..597f4740 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Delegates/AppDelegate.h @@ -0,0 +1,17 @@ +// +// AppDelegate.h +// Astronomy ObjC Swift +// +// Created by Benjamin Hakes on 3/4/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +#import + +@interface AppDelegate : UIResponder + +@property (strong, nonatomic) UIWindow *window; + + +@end + diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Delegates/AppDelegate.m b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Delegates/AppDelegate.m new file mode 100644 index 00000000..516bc81c --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Delegates/AppDelegate.m @@ -0,0 +1,51 @@ +// +// AppDelegate.m +// Astronomy ObjC Swift +// +// Created by Benjamin Hakes on 3/4/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +#import "AppDelegate.h" + +@interface AppDelegate () + +@end + +@implementation AppDelegate + + +- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + // Override point for customization after application launch. + return YES; +} + + +- (void)applicationWillResignActive:(UIApplication *)application { + // 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. +} + + +- (void)applicationDidEnterBackground:(UIApplication *)application { + // 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. +} + + +- (void)applicationWillEnterForeground:(UIApplication *)application { + // 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. +} + + +- (void)applicationDidBecomeActive:(UIApplication *)application { + // 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. +} + + +- (void)applicationWillTerminate:(UIApplication *)application { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. +} + + +@end diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/AppIcon.appiconset/Contents.json b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..d8db8d65 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/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/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/Contents.json b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/Contents.json new file mode 100644 index 00000000..da4a164c --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/Contents.json b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/Contents.json new file mode 100644 index 00000000..407538ef --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/Contents.json @@ -0,0 +1,23 @@ +{ + "images" : [ + { + "idiom" : "universal", + "filename" : "MarsPlaceholder-2.jpg", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "MarsPlaceholder-1.jpg", + "scale" : "2x" + }, + { + "idiom" : "universal", + "filename" : "MarsPlaceholder.jpg", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder-1.jpg b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder-1.jpg new file mode 100644 index 00000000..a43b5801 Binary files /dev/null and b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder-1.jpg differ diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder-2.jpg b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder-2.jpg new file mode 100644 index 00000000..a43b5801 Binary files /dev/null and b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder-2.jpg differ diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder.jpg b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder.jpg new file mode 100644 index 00000000..a43b5801 Binary files /dev/null and b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Assets.xcassets/MarsPlaceholder.imageset/MarsPlaceholder.jpg differ diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Base.lproj/LaunchScreen.storyboard b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 00000000..bfa36129 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Base.lproj/Main.storyboard b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Base.lproj/Main.storyboard new file mode 100644 index 00000000..31e6efbf --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Base.lproj/Main.storyboard @@ -0,0 +1,153 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Info.plist b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/Info.plist new file mode 100644 index 00000000..16be3b68 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/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/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/main.m b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/main.m new file mode 100644 index 00000000..5f871a1e --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/Resources/main.m @@ -0,0 +1,16 @@ +// +// main.m +// Astronomy ObjC Swift +// +// Created by Benjamin Hakes on 3/4/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +#import +#import "AppDelegate.h" + +int main(int argc, char * argv[]) { + @autoreleasepool { + return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); + } +} diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/ViewControllers/PhotoDetailViewController.swift b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/ViewControllers/PhotoDetailViewController.swift new file mode 100644 index 00000000..b08f792d --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/ViewControllers/PhotoDetailViewController.swift @@ -0,0 +1,20 @@ +// +// PhotoDetailViewController.swift +// Astronomy ObjC Swift +// +// Created by Benjamin Hakes on 3/5/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +import UIKit + +class PhotoDetailViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Do any additional setup after loading the view. + } + + +} diff --git a/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/ViewControllers/PhotosCollectionViewController.swift b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/ViewControllers/PhotosCollectionViewController.swift new file mode 100644 index 00000000..be3ec8e3 --- /dev/null +++ b/Sprint 12/Modules 2&3/Astronomy ObjC Swift/Astronomy ObjC Swift/ViewControllers/PhotosCollectionViewController.swift @@ -0,0 +1,89 @@ +// +// PhotosCollectionViewController.swift +// Astronomy ObjC Swift +// +// Created by Benjamin Hakes on 3/5/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +import UIKit + +private let reuseIdentifier = "Cell" + +class PhotosCollectionViewController: UICollectionViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Register cell classes + self.collectionView!.register(UICollectionViewCell.self, forCellWithReuseIdentifier: reuseIdentifier) + + // Do any additional setup after loading the view. + } + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using [segue destinationViewController]. + // Pass the selected object to the new view controller. + } + */ + + // MARK: UICollectionViewDataSource + + override func numberOfSections(in collectionView: UICollectionView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + + override func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of items + return 0 + } + + override func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { + let cell = collectionView.dequeueReusableCell(withReuseIdentifier: reuseIdentifier, for: indexPath) + + // Configure the cell + + return cell + } + + // MARK: UICollectionViewDelegate + + /* + // Uncomment this method to specify if the specified item should be highlighted during tracking + override func collectionView(_ collectionView: UICollectionView, shouldHighlightItemAt indexPath: IndexPath) -> Bool { + return true + } + */ + + /* + // Uncomment this method to specify if the specified item should be selected + override func collectionView(_ collectionView: UICollectionView, shouldSelectItemAt indexPath: IndexPath) -> Bool { + return true + } + */ + + /* + // Uncomment these methods to specify if an action menu should be displayed for the specified item, and react to actions performed on the item + override func collectionView(_ collectionView: UICollectionView, shouldShowMenuForItemAt indexPath: IndexPath) -> Bool { + return false + } + + override func collectionView(_ collectionView: UICollectionView, canPerformAction action: Selector, forItemAt indexPath: IndexPath, withSender sender: Any?) -> Bool { + return false + } + + override func collectionView(_ collectionView: UICollectionView, performAction action: Selector, forItemAt indexPath: IndexPath, withSender sender: Any?) { + + } + */ + +} diff --git a/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating.xcodeproj/project.pbxproj b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating.xcodeproj/project.pbxproj new file mode 100644 index 00000000..46e55ac7 --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating.xcodeproj/project.pbxproj @@ -0,0 +1,361 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 50; + objects = { + +/* Begin PBXBuildFile section */ + D165880921E543890060B1D6 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = D165880821E543890060B1D6 /* AppDelegate.swift */; }; + D165880B21E543890060B1D6 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = D165880A21E543890060B1D6 /* ViewController.swift */; }; + D165880E21E543890060B1D6 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D165880C21E543890060B1D6 /* Main.storyboard */; }; + D165881021E5438B0060B1D6 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = D165880F21E5438B0060B1D6 /* Assets.xcassets */; }; + D165881321E5438B0060B1D6 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D165881121E5438B0060B1D6 /* LaunchScreen.storyboard */; }; + D165881D21E5451A0060B1D6 /* CustomControl.swift in Sources */ = {isa = PBXBuildFile; fileRef = D165881C21E5451A0060B1D6 /* CustomControl.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + D165880521E543890060B1D6 /* UserStarRating.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = UserStarRating.app; sourceTree = BUILT_PRODUCTS_DIR; }; + D165880821E543890060B1D6 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + D165880A21E543890060B1D6 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + D165880D21E543890060B1D6 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + D165880F21E5438B0060B1D6 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + D165881221E5438B0060B1D6 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + D165881421E5438B0060B1D6 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + D165881C21E5451A0060B1D6 /* CustomControl.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CustomControl.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + D165880221E543890060B1D6 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + D16587FC21E543890060B1D6 = { + isa = PBXGroup; + children = ( + D165880721E543890060B1D6 /* UserStarRating */, + D165880621E543890060B1D6 /* Products */, + ); + sourceTree = ""; + }; + D165880621E543890060B1D6 /* Products */ = { + isa = PBXGroup; + children = ( + D165880521E543890060B1D6 /* UserStarRating.app */, + ); + name = Products; + sourceTree = ""; + }; + D165880721E543890060B1D6 /* UserStarRating */ = { + isa = PBXGroup; + children = ( + D165880821E543890060B1D6 /* AppDelegate.swift */, + D165881B21E544ED0060B1D6 /* CustomControls */, + D165881A21E5446B0060B1D6 /* View Controllers */, + D165880C21E543890060B1D6 /* Main.storyboard */, + D165880F21E5438B0060B1D6 /* Assets.xcassets */, + D165881121E5438B0060B1D6 /* LaunchScreen.storyboard */, + D165881421E5438B0060B1D6 /* Info.plist */, + ); + path = UserStarRating; + sourceTree = ""; + }; + D165881A21E5446B0060B1D6 /* View Controllers */ = { + isa = PBXGroup; + children = ( + D165880A21E543890060B1D6 /* ViewController.swift */, + ); + path = "View Controllers"; + sourceTree = ""; + }; + D165881B21E544ED0060B1D6 /* CustomControls */ = { + isa = PBXGroup; + children = ( + D165881C21E5451A0060B1D6 /* CustomControl.swift */, + ); + path = CustomControls; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + D165880421E543890060B1D6 /* UserStarRating */ = { + isa = PBXNativeTarget; + buildConfigurationList = D165881721E5438B0060B1D6 /* Build configuration list for PBXNativeTarget "UserStarRating" */; + buildPhases = ( + D165880121E543890060B1D6 /* Sources */, + D165880221E543890060B1D6 /* Frameworks */, + D165880321E543890060B1D6 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = UserStarRating; + productName = UserStarRating; + productReference = D165880521E543890060B1D6 /* UserStarRating.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + D16587FD21E543890060B1D6 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 1010; + LastUpgradeCheck = 1010; + ORGANIZATIONNAME = "Benjamin Hakes"; + TargetAttributes = { + D165880421E543890060B1D6 = { + CreatedOnToolsVersion = 10.1; + }; + }; + }; + buildConfigurationList = D165880021E543890060B1D6 /* Build configuration list for PBXProject "UserStarRating" */; + compatibilityVersion = "Xcode 9.3"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = D16587FC21E543890060B1D6; + productRefGroup = D165880621E543890060B1D6 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + D165880421E543890060B1D6 /* UserStarRating */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + D165880321E543890060B1D6 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + D165881321E5438B0060B1D6 /* LaunchScreen.storyboard in Resources */, + D165881021E5438B0060B1D6 /* Assets.xcassets in Resources */, + D165880E21E543890060B1D6 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + D165880121E543890060B1D6 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + D165880B21E543890060B1D6 /* ViewController.swift in Sources */, + D165881D21E5451A0060B1D6 /* CustomControl.swift in Sources */, + D165880921E543890060B1D6 /* AppDelegate.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + D165880C21E543890060B1D6 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + D165880D21E543890060B1D6 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + D165881121E5438B0060B1D6 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + D165881221E5438B0060B1D6 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + D165881521E5438B0060B1D6 /* 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.1; + 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; + }; + D165881621E5438B0060B1D6 /* 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.1; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + D165881821E5438B0060B1D6 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = S5U94G8XN2; + INFOPLIST_FILE = UserStarRating/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.mettabits.UserStarRating; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.2; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + D165881921E5438B0060B1D6 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + DEVELOPMENT_TEAM = S5U94G8XN2; + INFOPLIST_FILE = UserStarRating/Info.plist; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + PRODUCT_BUNDLE_IDENTIFIER = com.mettabits.UserStarRating; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.2; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + D165880021E543890060B1D6 /* Build configuration list for PBXProject "UserStarRating" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + D165881521E5438B0060B1D6 /* Debug */, + D165881621E5438B0060B1D6 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + D165881721E5438B0060B1D6 /* Build configuration list for PBXNativeTarget "UserStarRating" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + D165881821E5438B0060B1D6 /* Debug */, + D165881921E5438B0060B1D6 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = D16587FD21E543890060B1D6 /* Project object */; +} diff --git a/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/AppDelegate.swift b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/AppDelegate.swift new file mode 100644 index 00000000..8cc5fddf --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/AppDelegate.swift @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// UserStarRating +// +// Created by Benjamin Hakes on 1/8/19. +// Copyright © 2019 Benjamin Hakes. 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/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Assets.xcassets/AppIcon.appiconset/Contents.json b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 00000000..d8db8d65 --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/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/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Assets.xcassets/Contents.json b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Assets.xcassets/Contents.json new file mode 100644 index 00000000..da4a164c --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Base.lproj/LaunchScreen.storyboard b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Base.lproj/LaunchScreen.storyboard new file mode 100644 index 00000000..bfa36129 --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Base.lproj/LaunchScreen.storyboard @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Base.lproj/Main.storyboard b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Base.lproj/Main.storyboard new file mode 100644 index 00000000..0028266c --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/Base.lproj/Main.storyboard @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/CustomControls/CustomControl.swift b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/CustomControls/CustomControl.swift new file mode 100644 index 00000000..988485ce --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/CustomControls/CustomControl.swift @@ -0,0 +1,132 @@ +// +// CustomControl.swift +// UserStarRating +// +// Created by Benjamin Hakes on 1/8/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +import UIKit + +class CustomControl: UIControl { + + var value: Int = 1 { + didSet { + + } + } + private var labelArray: [UILabel] = [] + private let componentDimension: CGFloat = 40.0 + private let componentCount = 5 + private let componentActiveColor = UIColor.black + private let componentInactiveColor = UIColor.gray + + required init?(coder aCoder: NSCoder){ + super.init(coder: aCoder) + + setup() + } + + private func setup(){ + for x in 0..<5{ + labelArray.append(UILabel()) + guard let mostRecentLabel = labelArray.last else {fatalError("could not get last element")} + mostRecentLabel.tag = x + 1 + mostRecentLabel.frame = CGRect(origin: CGPoint(x: 8.0 + (Double(x) * 40.0), y: 0.0), size: CGSize(width: componentDimension, height: componentDimension)) + mostRecentLabel.font = UIFont.boldSystemFont(ofSize: CGFloat(integerLiteral: 32)) + mostRecentLabel.text = "★" + mostRecentLabel.textAlignment = .center + if x > 0 { + mostRecentLabel.textColor = componentActiveColor + } else { + mostRecentLabel.textColor = componentInactiveColor + } + + self.addSubview(mostRecentLabel) + + + } + } + + override var intrinsicContentSize: CGSize { + let componentsWidth = CGFloat(componentCount) * componentDimension + let componentsSpacing = CGFloat(componentCount + 1) * 8.0 + let width = componentsWidth + componentsSpacing + return CGSize(width: width, height: componentDimension) + } + + override func beginTracking(_ touch: UITouch, with event: UIEvent?) -> Bool { + + updateValue(at: touch) + sendActions(for: [.touchDown,.valueChanged]) + return true + } + + override func continueTracking(_ touch: UITouch, with event: UIEvent?) -> Bool { + defer { + super.endTracking(touch, with: event) + } + + let touchPoint = touch.location(in: self) + + if bounds.contains(touchPoint){ + // TODO: Implement func + updateValue(at: touch) + sendActions(for: [.touchDragInside, .valueChanged]) + } else { + sendActions(for: [.touchDragOutside]) + } + return true + } + + override func endTracking(_ touch: UITouch?, with event: UIEvent?) { + defer { + super.endTracking(touch, with: event) + } + guard let touch = touch else { return } + + let touchPoint = touch.location(in: self) + + if bounds.contains(touchPoint){ + updateValue(at: touch) + sendActions(for: [.touchUpInside, .valueChanged]) + } else { + sendActions(for: [.touchUpOutside]) + } + + } + + override func cancelTracking(with event: UIEvent?) { + sendActions(for: [.touchCancel]) + super.cancelTracking(with: event) + } + + func updateValue(at touch: UITouch) { + + let touchPoint = touch.location(in: self) + print(touchPoint) + for index in 0.. + + + + 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/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/View Controllers/ViewController.swift b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/View Controllers/ViewController.swift new file mode 100644 index 00000000..2a2cdb49 --- /dev/null +++ b/Sprint 6/Module 2-Custom Controls/UserStarRating/UserStarRating/View Controllers/ViewController.swift @@ -0,0 +1,26 @@ +// +// ViewController.swift +// UserStarRating +// +// Created by Benjamin Hakes on 1/8/19. +// Copyright © 2019 Benjamin Hakes. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + @IBAction func updateRating(_ ratingControl: CustomControl) { + + let value = ratingControl.value + if value > 1 { + self.title = ("User Rating: \(value) stars") + } else { + self.title = ("User Rating: \(value) star") + } + + } + + +} + diff --git a/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/Contents.swift b/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/Contents.swift new file mode 100644 index 00000000..49c1ff6d --- /dev/null +++ b/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/Contents.swift @@ -0,0 +1,3 @@ +import UIKit + +var str = "Hello, playground" diff --git a/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/contents.xcplayground b/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/contents.xcplayground new file mode 100644 index 00000000..9f5f2f40 --- /dev/null +++ b/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/contents.xcplayground @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/timeline.xctimeline b/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/timeline.xctimeline new file mode 100644 index 00000000..bf468afe --- /dev/null +++ b/Sprint 7/Generics (7.2)/CountedSetPlayground.playground/timeline.xctimeline @@ -0,0 +1,6 @@ + + + + + diff --git a/Sprint 9/Creating Frameworks/FrameworksPractice b/Sprint 9/Creating Frameworks/FrameworksPractice new file mode 160000 index 00000000..e80143d3 --- /dev/null +++ b/Sprint 9/Creating Frameworks/FrameworksPractice @@ -0,0 +1 @@ +Subproject commit e80143d36d385a3a14f4f7a3716df9325fcce39e diff --git a/Sprint 9/Creating Frameworks/IndeterminateLoadingView.swift b/Sprint 9/Creating Frameworks/IndeterminateLoadingView.swift index 18a7145d..c59af742 100644 --- a/Sprint 9/Creating Frameworks/IndeterminateLoadingView.swift +++ b/Sprint 9/Creating Frameworks/IndeterminateLoadingView.swift @@ -102,6 +102,6 @@ class IndeterminateLoadingView: UIView, CAAnimationDelegate { private(set) var isAnimating = false private let shapeLayer = CAShapeLayer() - private let duration = 1.0 + private let duration = 5.0 private var shouldStopAnimationOnNextCycle = false } diff --git a/Sprint 9/Creating Frameworks/LoadingFramework b/Sprint 9/Creating Frameworks/LoadingFramework new file mode 160000 index 00000000..c7c4560f --- /dev/null +++ b/Sprint 9/Creating Frameworks/LoadingFramework @@ -0,0 +1 @@ +Subproject commit c7c4560ff3cb6dc02a0ef5cb8556abbe6bec9127