From f66f07287c1c8107371454bb1c06e5a36307e380 Mon Sep 17 00:00:00 2001 From: Giles Van Gruisen Date: Sat, 31 Jan 2015 17:45:23 -0500 Subject: [PATCH] Create YouTubePlayerExample, add projects to workspace, remove tests --- .../contents.xcworkspacedata | 10 + .../YouTubePlayer.xcodeproj}/project.pbxproj | 126 -------- .../contents.xcworkspacedata | 0 YouTubePlayer/{ => YouTubePlayer}/Info.plist | 0 .../{ => YouTubePlayer}/VideoPlayerView.swift | 7 + .../{ => YouTubePlayer}/YTPlayer.html | 0 .../{ => YouTubePlayer}/YouTubePlayer.h | 0 .../project.pbxproj | 292 ++++++++++++++++++ .../contents.xcworkspacedata | 7 + .../YouTubePlayerExample/AppDelegate.swift | 46 +++ .../Base.lproj/LaunchScreen.xib | 41 +++ .../Base.lproj/Main.storyboard | 25 ++ .../AppIcon.appiconset/Contents.json | 38 +++ .../YouTubePlayerExample}/Info.plist | 16 +- .../YouTubePlayerExample/ViewController.swift | 26 ++ YouTubePlayerTests/YouTubePlayerTests.swift | 37 --- 16 files changed, 507 insertions(+), 164 deletions(-) create mode 100644 YouTubePlayer.xcworkspace/contents.xcworkspacedata rename {YouTubePlayer.xcodeproj => YouTubePlayer/YouTubePlayer.xcodeproj}/project.pbxproj (68%) rename {YouTubePlayer.xcodeproj => YouTubePlayer/YouTubePlayer.xcodeproj}/project.xcworkspace/contents.xcworkspacedata (100%) rename YouTubePlayer/{ => YouTubePlayer}/Info.plist (100%) rename YouTubePlayer/{ => YouTubePlayer}/VideoPlayerView.swift (97%) rename YouTubePlayer/{ => YouTubePlayer}/YTPlayer.html (100%) rename YouTubePlayer/{ => YouTubePlayer}/YouTubePlayer.h (100%) create mode 100644 YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.pbxproj create mode 100644 YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 YouTubePlayerExample/YouTubePlayerExample/AppDelegate.swift create mode 100644 YouTubePlayerExample/YouTubePlayerExample/Base.lproj/LaunchScreen.xib create mode 100644 YouTubePlayerExample/YouTubePlayerExample/Base.lproj/Main.storyboard create mode 100644 YouTubePlayerExample/YouTubePlayerExample/Images.xcassets/AppIcon.appiconset/Contents.json rename {YouTubePlayerTests => YouTubePlayerExample/YouTubePlayerExample}/Info.plist (65%) create mode 100644 YouTubePlayerExample/YouTubePlayerExample/ViewController.swift delete mode 100644 YouTubePlayerTests/YouTubePlayerTests.swift diff --git a/YouTubePlayer.xcworkspace/contents.xcworkspacedata b/YouTubePlayer.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..2aefbc4 --- /dev/null +++ b/YouTubePlayer.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,10 @@ + + + + + + + diff --git a/YouTubePlayer.xcodeproj/project.pbxproj b/YouTubePlayer/YouTubePlayer.xcodeproj/project.pbxproj similarity index 68% rename from YouTubePlayer.xcodeproj/project.pbxproj rename to YouTubePlayer/YouTubePlayer.xcodeproj/project.pbxproj index 3912bd4..f2140ec 100644 --- a/YouTubePlayer.xcodeproj/project.pbxproj +++ b/YouTubePlayer/YouTubePlayer.xcodeproj/project.pbxproj @@ -7,32 +7,17 @@ objects = { /* Begin PBXBuildFile section */ - 502AE86B1A475FD500306AD1 /* YouTubePlayer.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 502AE85F1A475FD500306AD1 /* YouTubePlayer.framework */; }; 50E5B9C71A4CA9E40099BF69 /* YouTubePlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 50E5B9C61A4CA9E40099BF69 /* YouTubePlayer.h */; settings = {ATTRIBUTES = (Public, ); }; }; 50E5B9C91A4CAA050099BF69 /* YTPlayer.html in Resources */ = {isa = PBXBuildFile; fileRef = 50E5B9C81A4CAA050099BF69 /* YTPlayer.html */; }; 50E5B9CB1A4CAA150099BF69 /* VideoPlayerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 50E5B9CA1A4CAA150099BF69 /* VideoPlayerView.swift */; }; - 50E5B9D01A4CAAFC0099BF69 /* YouTubePlayerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 50E5B9CE1A4CAA700099BF69 /* YouTubePlayerTests.swift */; }; /* End PBXBuildFile section */ -/* Begin PBXContainerItemProxy section */ - 502AE86C1A475FD500306AD1 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 502AE8561A475FD500306AD1 /* Project object */; - proxyType = 1; - remoteGlobalIDString = 502AE85E1A475FD500306AD1; - remoteInfo = SwiftyYouTube; - }; -/* End PBXContainerItemProxy section */ - /* Begin PBXFileReference section */ 502AE85F1A475FD500306AD1 /* YouTubePlayer.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = YouTubePlayer.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 502AE8631A475FD500306AD1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; name = Info.plist; path = YouTubePlayer/Info.plist; sourceTree = ""; }; - 502AE86A1A475FD500306AD1 /* YouTubePlayerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = YouTubePlayerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; - 502AE8701A475FD500306AD1 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist; name = Info.plist; path = YouTubePlayerTests/Info.plist; sourceTree = ""; }; 50E5B9C61A4CA9E40099BF69 /* YouTubePlayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = YouTubePlayer.h; path = YouTubePlayer/YouTubePlayer.h; sourceTree = SOURCE_ROOT; }; 50E5B9C81A4CAA050099BF69 /* YTPlayer.html */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.html; name = YTPlayer.html; path = YouTubePlayer/YTPlayer.html; sourceTree = SOURCE_ROOT; }; 50E5B9CA1A4CAA150099BF69 /* VideoPlayerView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = VideoPlayerView.swift; path = YouTubePlayer/VideoPlayerView.swift; sourceTree = SOURCE_ROOT; }; - 50E5B9CE1A4CAA700099BF69 /* YouTubePlayerTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = YouTubePlayerTests.swift; path = YouTubePlayerTests/YouTubePlayerTests.swift; sourceTree = SOURCE_ROOT; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -43,14 +28,6 @@ ); runOnlyForDeploymentPostprocessing = 0; }; - 502AE8671A475FD500306AD1 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - 502AE86B1A475FD500306AD1 /* YouTubePlayer.framework in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; /* End PBXFrameworksBuildPhase section */ /* Begin PBXGroup section */ @@ -58,7 +35,6 @@ isa = PBXGroup; children = ( 502AE8611A475FD500306AD1 /* YouTubePlayer */, - 502AE86E1A475FD500306AD1 /* SwiftyYouTubeTests */, 502AE8601A475FD500306AD1 /* Products */, ); sourceTree = ""; @@ -67,7 +43,6 @@ isa = PBXGroup; children = ( 502AE85F1A475FD500306AD1 /* YouTubePlayer.framework */, - 502AE86A1A475FD500306AD1 /* YouTubePlayerTests.xctest */, ); name = Products; sourceTree = ""; @@ -92,23 +67,6 @@ name = "Supporting Files"; sourceTree = ""; }; - 502AE86E1A475FD500306AD1 /* SwiftyYouTubeTests */ = { - isa = PBXGroup; - children = ( - 50E5B9CE1A4CAA700099BF69 /* YouTubePlayerTests.swift */, - 502AE86F1A475FD500306AD1 /* Supporting Files */, - ); - path = SwiftyYouTubeTests; - sourceTree = ""; - }; - 502AE86F1A475FD500306AD1 /* Supporting Files */ = { - isa = PBXGroup; - children = ( - 502AE8701A475FD500306AD1 /* Info.plist */, - ); - name = "Supporting Files"; - sourceTree = ""; - }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ @@ -141,24 +99,6 @@ productReference = 502AE85F1A475FD500306AD1 /* YouTubePlayer.framework */; productType = "com.apple.product-type.framework"; }; - 502AE8691A475FD500306AD1 /* YouTubePlayerTests */ = { - isa = PBXNativeTarget; - buildConfigurationList = 502AE8781A475FD500306AD1 /* Build configuration list for PBXNativeTarget "YouTubePlayerTests" */; - buildPhases = ( - 502AE8661A475FD500306AD1 /* Sources */, - 502AE8671A475FD500306AD1 /* Frameworks */, - 502AE8681A475FD500306AD1 /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - 502AE86D1A475FD500306AD1 /* PBXTargetDependency */, - ); - name = YouTubePlayerTests; - productName = SwiftyYouTubeTests; - productReference = 502AE86A1A475FD500306AD1 /* YouTubePlayerTests.xctest */; - productType = "com.apple.product-type.bundle.unit-test"; - }; /* End PBXNativeTarget section */ /* Begin PBXProject section */ @@ -171,9 +111,6 @@ 502AE85E1A475FD500306AD1 = { CreatedOnToolsVersion = 6.1; }; - 502AE8691A475FD500306AD1 = { - CreatedOnToolsVersion = 6.1; - }; }; }; buildConfigurationList = 502AE8591A475FD500306AD1 /* Build configuration list for PBXProject "YouTubePlayer" */; @@ -189,7 +126,6 @@ projectRoot = ""; targets = ( 502AE85E1A475FD500306AD1 /* YouTubePlayer */, - 502AE8691A475FD500306AD1 /* YouTubePlayerTests */, ); }; /* End PBXProject section */ @@ -203,13 +139,6 @@ ); runOnlyForDeploymentPostprocessing = 0; }; - 502AE8681A475FD500306AD1 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; /* End PBXResourcesBuildPhase section */ /* Begin PBXSourcesBuildPhase section */ @@ -221,24 +150,8 @@ ); runOnlyForDeploymentPostprocessing = 0; }; - 502AE8661A475FD500306AD1 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 50E5B9D01A4CAAFC0099BF69 /* YouTubePlayerTests.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; /* End PBXSourcesBuildPhase section */ -/* Begin PBXTargetDependency section */ - 502AE86D1A475FD500306AD1 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - target = 502AE85E1A475FD500306AD1 /* YouTubePlayer */; - targetProxy = 502AE86C1A475FD500306AD1 /* PBXContainerItemProxy */; - }; -/* End PBXTargetDependency section */ - /* Begin XCBuildConfiguration section */ 502AE8731A475FD500306AD1 /* Debug */ = { isa = XCBuildConfiguration; @@ -360,36 +273,6 @@ }; name = Release; }; - 502AE8791A475FD500306AD1 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - FRAMEWORK_SEARCH_PATHS = ( - "$(SDKROOT)/Developer/Library/Frameworks", - "$(inherited)", - ); - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - INFOPLIST_FILE = "$(SOURCE_ROOT)/YouTubePlayerTests/Info.plist"; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - PRODUCT_NAME = YouTubePlayerTests; - }; - name = Debug; - }; - 502AE87A1A475FD500306AD1 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - FRAMEWORK_SEARCH_PATHS = ( - "$(SDKROOT)/Developer/Library/Frameworks", - "$(inherited)", - ); - INFOPLIST_FILE = "$(SOURCE_ROOT)/YouTubePlayerTests/Info.plist"; - LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; - PRODUCT_NAME = YouTubePlayerTests; - }; - name = Release; - }; /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ @@ -411,15 +294,6 @@ defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; - 502AE8781A475FD500306AD1 /* Build configuration list for PBXNativeTarget "YouTubePlayerTests" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 502AE8791A475FD500306AD1 /* Debug */, - 502AE87A1A475FD500306AD1 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; /* End XCConfigurationList section */ }; rootObject = 502AE8561A475FD500306AD1 /* Project object */; diff --git a/YouTubePlayer.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/YouTubePlayer/YouTubePlayer.xcodeproj/project.xcworkspace/contents.xcworkspacedata similarity index 100% rename from YouTubePlayer.xcodeproj/project.xcworkspace/contents.xcworkspacedata rename to YouTubePlayer/YouTubePlayer.xcodeproj/project.xcworkspace/contents.xcworkspacedata diff --git a/YouTubePlayer/Info.plist b/YouTubePlayer/YouTubePlayer/Info.plist similarity index 100% rename from YouTubePlayer/Info.plist rename to YouTubePlayer/YouTubePlayer/Info.plist diff --git a/YouTubePlayer/VideoPlayerView.swift b/YouTubePlayer/YouTubePlayer/VideoPlayerView.swift similarity index 97% rename from YouTubePlayer/VideoPlayerView.swift rename to YouTubePlayer/YouTubePlayer/VideoPlayerView.swift index 1825f92..f796a4c 100644 --- a/YouTubePlayer/VideoPlayerView.swift +++ b/YouTubePlayer/YouTubePlayer/VideoPlayerView.swift @@ -138,6 +138,13 @@ public class YouTubePlayerView: UIView, UIWebViewDelegate { loadWebViewWithParameters(playerParams) } + public func loadPlaylistID(playlistID: String) { + var playerParams = playerParameters() + playerParams["playlistId"] = playlistID + + loadWebViewWithParameters(playerParams) + } + public func play() { evaluatePlayerCommand("playVideo()") } diff --git a/YouTubePlayer/YTPlayer.html b/YouTubePlayer/YouTubePlayer/YTPlayer.html similarity index 100% rename from YouTubePlayer/YTPlayer.html rename to YouTubePlayer/YouTubePlayer/YTPlayer.html diff --git a/YouTubePlayer/YouTubePlayer.h b/YouTubePlayer/YouTubePlayer/YouTubePlayer.h similarity index 100% rename from YouTubePlayer/YouTubePlayer.h rename to YouTubePlayer/YouTubePlayer/YouTubePlayer.h diff --git a/YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.pbxproj b/YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.pbxproj new file mode 100644 index 0000000..0c0a8ff --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.pbxproj @@ -0,0 +1,292 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 50BB8AE81A7D914C00216B49 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 50BB8AE71A7D914C00216B49 /* AppDelegate.swift */; }; + 50BB8AEA1A7D914C00216B49 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 50BB8AE91A7D914C00216B49 /* ViewController.swift */; }; + 50BB8AED1A7D914C00216B49 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 50BB8AEB1A7D914C00216B49 /* Main.storyboard */; }; + 50BB8AEF1A7D914C00216B49 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 50BB8AEE1A7D914C00216B49 /* Images.xcassets */; }; + 50BB8AF21A7D914C00216B49 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 50BB8AF01A7D914C00216B49 /* LaunchScreen.xib */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 50BB8AE21A7D914C00216B49 /* YouTubePlayerExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = YouTubePlayerExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 50BB8AE61A7D914C00216B49 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 50BB8AE71A7D914C00216B49 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 50BB8AE91A7D914C00216B49 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + 50BB8AEC1A7D914C00216B49 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 50BB8AEE1A7D914C00216B49 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; }; + 50BB8AF11A7D914C00216B49 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 50BB8ADF1A7D914C00216B49 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 50BB8AD91A7D914C00216B49 = { + isa = PBXGroup; + children = ( + 50BB8AE41A7D914C00216B49 /* YouTubePlayerExample */, + 50BB8AE31A7D914C00216B49 /* Products */, + ); + sourceTree = ""; + }; + 50BB8AE31A7D914C00216B49 /* Products */ = { + isa = PBXGroup; + children = ( + 50BB8AE21A7D914C00216B49 /* YouTubePlayerExample.app */, + ); + name = Products; + sourceTree = ""; + }; + 50BB8AE41A7D914C00216B49 /* YouTubePlayerExample */ = { + isa = PBXGroup; + children = ( + 50BB8AE71A7D914C00216B49 /* AppDelegate.swift */, + 50BB8AE91A7D914C00216B49 /* ViewController.swift */, + 50BB8AEB1A7D914C00216B49 /* Main.storyboard */, + 50BB8AEE1A7D914C00216B49 /* Images.xcassets */, + 50BB8AF01A7D914C00216B49 /* LaunchScreen.xib */, + 50BB8AE51A7D914C00216B49 /* Supporting Files */, + ); + path = YouTubePlayerExample; + sourceTree = ""; + }; + 50BB8AE51A7D914C00216B49 /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 50BB8AE61A7D914C00216B49 /* Info.plist */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 50BB8AE11A7D914C00216B49 /* YouTubePlayerExample */ = { + isa = PBXNativeTarget; + buildConfigurationList = 50BB8B011A7D914C00216B49 /* Build configuration list for PBXNativeTarget "YouTubePlayerExample" */; + buildPhases = ( + 50BB8ADE1A7D914C00216B49 /* Sources */, + 50BB8ADF1A7D914C00216B49 /* Frameworks */, + 50BB8AE01A7D914C00216B49 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = YouTubePlayerExample; + productName = YouTubePlayerExample; + productReference = 50BB8AE21A7D914C00216B49 /* YouTubePlayerExample.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 50BB8ADA1A7D914C00216B49 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0610; + ORGANIZATIONNAME = "Giles Van Gruisen"; + TargetAttributes = { + 50BB8AE11A7D914C00216B49 = { + CreatedOnToolsVersion = 6.1; + }; + }; + }; + buildConfigurationList = 50BB8ADD1A7D914C00216B49 /* Build configuration list for PBXProject "YouTubePlayerExample" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 50BB8AD91A7D914C00216B49; + productRefGroup = 50BB8AE31A7D914C00216B49 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 50BB8AE11A7D914C00216B49 /* YouTubePlayerExample */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 50BB8AE01A7D914C00216B49 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 50BB8AED1A7D914C00216B49 /* Main.storyboard in Resources */, + 50BB8AF21A7D914C00216B49 /* LaunchScreen.xib in Resources */, + 50BB8AEF1A7D914C00216B49 /* Images.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 50BB8ADE1A7D914C00216B49 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 50BB8AEA1A7D914C00216B49 /* ViewController.swift in Sources */, + 50BB8AE81A7D914C00216B49 /* AppDelegate.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 50BB8AEB1A7D914C00216B49 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 50BB8AEC1A7D914C00216B49 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 50BB8AF01A7D914C00216B49 /* LaunchScreen.xib */ = { + isa = PBXVariantGroup; + children = ( + 50BB8AF11A7D914C00216B49 /* Base */, + ); + name = LaunchScreen.xib; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 50BB8AFF1A7D914C00216B49 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + 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_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_SYMBOLS_PRIVATE_EXTERN = NO; + 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 = 8.1; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 50BB8B001A7D914C00216B49 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + 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_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = YES; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + 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 = 8.1; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 50BB8B021A7D914C00216B49 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + INFOPLIST_FILE = YouTubePlayerExample/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Debug; + }; + 50BB8B031A7D914C00216B49 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + INFOPLIST_FILE = YouTubePlayerExample/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 50BB8ADD1A7D914C00216B49 /* Build configuration list for PBXProject "YouTubePlayerExample" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 50BB8AFF1A7D914C00216B49 /* Debug */, + 50BB8B001A7D914C00216B49 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 50BB8B011A7D914C00216B49 /* Build configuration list for PBXNativeTarget "YouTubePlayerExample" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 50BB8B021A7D914C00216B49 /* Debug */, + 50BB8B031A7D914C00216B49 /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; +/* End XCConfigurationList section */ + }; + rootObject = 50BB8ADA1A7D914C00216B49 /* Project object */; +} diff --git a/YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..3bf031c --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/YouTubePlayerExample/YouTubePlayerExample/AppDelegate.swift b/YouTubePlayerExample/YouTubePlayerExample/AppDelegate.swift new file mode 100644 index 0000000..cd81911 --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample/AppDelegate.swift @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// YouTubePlayerExample +// +// Created by Giles Van Gruisen on 1/31/15. +// Copyright (c) 2015 Giles Van Gruisen. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> 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 throttle down OpenGL ES frame rates. 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 inactive 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/YouTubePlayerExample/YouTubePlayerExample/Base.lproj/LaunchScreen.xib b/YouTubePlayerExample/YouTubePlayerExample/Base.lproj/LaunchScreen.xib new file mode 100644 index 0000000..d7e2dad --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample/Base.lproj/LaunchScreen.xib @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/YouTubePlayerExample/YouTubePlayerExample/Base.lproj/Main.storyboard b/YouTubePlayerExample/YouTubePlayerExample/Base.lproj/Main.storyboard new file mode 100644 index 0000000..52ea29e --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample/Base.lproj/Main.storyboard @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/YouTubePlayerExample/YouTubePlayerExample/Images.xcassets/AppIcon.appiconset/Contents.json b/YouTubePlayerExample/YouTubePlayerExample/Images.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..118c98f --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample/Images.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,38 @@ +{ + "images" : [ + { + "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" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/YouTubePlayerTests/Info.plist b/YouTubePlayerExample/YouTubePlayerExample/Info.plist similarity index 65% rename from YouTubePlayerTests/Info.plist rename to YouTubePlayerExample/YouTubePlayerExample/Info.plist index 4b65573..a8c04fd 100644 --- a/YouTubePlayerTests/Info.plist +++ b/YouTubePlayerExample/YouTubePlayerExample/Info.plist @@ -13,12 +13,26 @@ CFBundleName $(PRODUCT_NAME) CFBundlePackageType - BNDL + APPL CFBundleShortVersionString 1.0 CFBundleSignature ???? CFBundleVersion 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + diff --git a/YouTubePlayerExample/YouTubePlayerExample/ViewController.swift b/YouTubePlayerExample/YouTubePlayerExample/ViewController.swift new file mode 100644 index 0000000..18ee4f1 --- /dev/null +++ b/YouTubePlayerExample/YouTubePlayerExample/ViewController.swift @@ -0,0 +1,26 @@ +// +// ViewController.swift +// YouTubePlayerExample +// +// Created by Giles Van Gruisen on 1/31/15. +// Copyright (c) 2015 Giles Van Gruisen. All rights reserved. +// + +import UIKit +import YouTubePlayer + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git a/YouTubePlayerTests/YouTubePlayerTests.swift b/YouTubePlayerTests/YouTubePlayerTests.swift deleted file mode 100644 index c09ba0f..0000000 --- a/YouTubePlayerTests/YouTubePlayerTests.swift +++ /dev/null @@ -1,37 +0,0 @@ -// -// YouTubePlayerTests.swift -// YouTubePlayerTests -// -// Created by Giles Van Gruisen on 12/21/14. -// Copyright (c) 2014 Giles Van Gruisen. All rights reserved. -// - -import UIKit -import XCTest -import YouTubePlayer - -class YouTubePlayerTests: XCTestCase { - - override func setUp() { - super.setUp() - // Put setup code here. This method is called before the invocation of each test method in the class. - } - - override func tearDown() { - // Put teardown code here. This method is called after the invocation of each test method in the class. - super.tearDown() - } - - func testExample() { - // This is an example of a functional test case. - XCTAssert(true, "Pass") - } - - func testPerformanceExample() { - // This is an example of a performance test case. - self.measureBlock() { - // Put the code you want to measure the time of here. - } - } - -}