├── NVPictureInPicture
├── Assets
│ └── .gitkeep
└── Classes
│ ├── .gitkeep
│ ├── NVPictureInPictureViewController.h
│ └── NVPictureInPictureViewController.m
├── _Pods.xcodeproj
├── Example
├── Tests
│ ├── en.lproj
│ │ └── InfoPlist.strings
│ ├── Tests-Prefix.pch
│ ├── Tests.m
│ └── Tests-Info.plist
├── NVPictureInPicture
│ ├── en.lproj
│ │ └── InfoPlist.strings
│ ├── NVRootViewController.h
│ ├── NVPIPSubViewController.h
│ ├── NVPIPAppDelegate.h
│ ├── NVPictureInPicture-Prefix.pch
│ ├── main.m
│ ├── NVRootViewController.m
│ ├── NVPictureInPicture-Info.plist
│ ├── Base.lproj
│ │ ├── LaunchScreen.storyboard
│ │ └── Main.storyboard
│ ├── Images.xcassets
│ │ └── AppIcon.appiconset
│ │ │ └── Contents.json
│ ├── NVPIPAppDelegate.m
│ └── NVPIPSubViewController.m
├── Pods
│ ├── Headers
│ │ ├── Private
│ │ │ └── NVPictureInPicture
│ │ │ │ └── NVPictureInPictureViewController.h
│ │ └── Public
│ │ │ └── NVPictureInPicture
│ │ │ └── NVPictureInPictureViewController.h
│ ├── Pods.xcodeproj
│ │ ├── project.xcworkspace
│ │ │ └── contents.xcworkspacedata
│ │ └── project.pbxproj
│ ├── Target Support Files
│ │ ├── NVPictureInPicture
│ │ │ ├── NVPictureInPicture.modulemap
│ │ │ ├── NVPictureInPicture-dummy.m
│ │ │ ├── NVPictureInPicture-prefix.pch
│ │ │ ├── NVPictureInPicture-umbrella.h
│ │ │ ├── NVPictureInPicture.xcconfig
│ │ │ └── Info.plist
│ │ ├── Pods-NVPictureInPicture_Tests
│ │ │ ├── Pods-NVPictureInPicture_Tests-acknowledgements.markdown
│ │ │ ├── Pods-NVPictureInPicture_Tests.modulemap
│ │ │ ├── Pods-NVPictureInPicture_Tests-dummy.m
│ │ │ ├── Pods-NVPictureInPicture_Tests-umbrella.h
│ │ │ ├── Pods-NVPictureInPicture_Tests.debug.xcconfig
│ │ │ ├── Pods-NVPictureInPicture_Tests.release.xcconfig
│ │ │ ├── Info.plist
│ │ │ ├── Pods-NVPictureInPicture_Tests-acknowledgements.plist
│ │ │ ├── Pods-NVPictureInPicture_Tests-resources.sh
│ │ │ └── Pods-NVPictureInPicture_Tests-frameworks.sh
│ │ └── Pods-NVPictureInPicture_Example
│ │ │ ├── Pods-NVPictureInPicture_Example.modulemap
│ │ │ ├── Pods-NVPictureInPicture_Example-dummy.m
│ │ │ ├── Pods-NVPictureInPicture_Example-umbrella.h
│ │ │ ├── Pods-NVPictureInPicture_Example.debug.xcconfig
│ │ │ ├── Pods-NVPictureInPicture_Example.release.xcconfig
│ │ │ ├── Info.plist
│ │ │ ├── Pods-NVPictureInPicture_Example-acknowledgements.markdown
│ │ │ ├── Pods-NVPictureInPicture_Example-acknowledgements.plist
│ │ │ ├── Pods-NVPictureInPicture_Example-resources.sh
│ │ │ └── Pods-NVPictureInPicture_Example-frameworks.sh
│ ├── Manifest.lock
│ └── Local Podspecs
│ │ └── NVPictureInPicture.podspec.json
├── Podfile
├── NVPictureInPicture.xcodeproj
│ ├── project.xcworkspace
│ │ └── contents.xcworkspacedata
│ ├── xcshareddata
│ │ └── xcschemes
│ │ │ └── NVPictureInPicture-Example.xcscheme
│ └── project.pbxproj
├── NVPictureInPicture.xcworkspace
│ ├── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
│ └── contents.xcworkspacedata
└── Podfile.lock
├── .travis.yml
├── .gitignore
├── LICENSE
├── README.md
└── NVPictureInPicture.podspec
/NVPictureInPicture/Assets/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/NVPictureInPicture/Classes/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/_Pods.xcodeproj:
--------------------------------------------------------------------------------
1 | Example/Pods/Pods.xcodeproj
--------------------------------------------------------------------------------
/Example/Tests/en.lproj/InfoPlist.strings:
--------------------------------------------------------------------------------
1 | /* Localized versions of Info.plist keys */
2 |
3 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/en.lproj/InfoPlist.strings:
--------------------------------------------------------------------------------
1 | /* Localized versions of Info.plist keys */
2 |
3 |
--------------------------------------------------------------------------------
/Example/Pods/Headers/Private/NVPictureInPicture/NVPictureInPictureViewController.h:
--------------------------------------------------------------------------------
1 | ../../../../../NVPictureInPicture/Classes/NVPictureInPictureViewController.h
--------------------------------------------------------------------------------
/Example/Pods/Headers/Public/NVPictureInPicture/NVPictureInPictureViewController.h:
--------------------------------------------------------------------------------
1 | ../../../../../NVPictureInPicture/Classes/NVPictureInPictureViewController.h
--------------------------------------------------------------------------------
/Example/Pods/Pods.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
--------------------------------------------------------------------------------
/Example/Tests/Tests-Prefix.pch:
--------------------------------------------------------------------------------
1 | // The contents of this file are implicitly included at the beginning of every test case source file.
2 |
3 | #ifdef __OBJC__
4 |
5 |
6 |
7 | #endif
8 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/NVPictureInPicture/NVPictureInPicture.modulemap:
--------------------------------------------------------------------------------
1 | framework module NVPictureInPicture {
2 | umbrella header "NVPictureInPicture-umbrella.h"
3 |
4 | export *
5 | module * { export * }
6 | }
7 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/NVPictureInPicture/NVPictureInPicture-dummy.m:
--------------------------------------------------------------------------------
1 | #import
2 | @interface PodsDummy_NVPictureInPicture : NSObject
3 | @end
4 | @implementation PodsDummy_NVPictureInPicture
5 | @end
6 |
--------------------------------------------------------------------------------
/Example/Podfile:
--------------------------------------------------------------------------------
1 | platform :ios, '9.0'
2 |
3 | target 'NVPictureInPicture_Example' do
4 | pod 'NVPictureInPicture', :path => '../'
5 |
6 | target 'NVPictureInPicture_Tests' do
7 | inherit! :search_paths
8 |
9 |
10 | end
11 | end
12 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-acknowledgements.markdown:
--------------------------------------------------------------------------------
1 | # Acknowledgements
2 | This application makes use of the following third party libraries:
3 | Generated by CocoaPods - https://cocoapods.org
4 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests.modulemap:
--------------------------------------------------------------------------------
1 | framework module Pods_NVPictureInPicture_Tests {
2 | umbrella header "Pods-NVPictureInPicture_Tests-umbrella.h"
3 |
4 | export *
5 | module * { export * }
6 | }
7 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example.modulemap:
--------------------------------------------------------------------------------
1 | framework module Pods_NVPictureInPicture_Example {
2 | umbrella header "Pods-NVPictureInPicture_Example-umbrella.h"
3 |
4 | export *
5 | module * { export * }
6 | }
7 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-dummy.m:
--------------------------------------------------------------------------------
1 | #import
2 | @interface PodsDummy_Pods_NVPictureInPicture_Tests : NSObject
3 | @end
4 | @implementation PodsDummy_Pods_NVPictureInPicture_Tests
5 | @end
6 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-dummy.m:
--------------------------------------------------------------------------------
1 | #import
2 | @interface PodsDummy_Pods_NVPictureInPicture_Example : NSObject
3 | @end
4 | @implementation PodsDummy_Pods_NVPictureInPicture_Example
5 | @end
6 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/NVPictureInPicture/NVPictureInPicture-prefix.pch:
--------------------------------------------------------------------------------
1 | #ifdef __OBJC__
2 | #import
3 | #else
4 | #ifndef FOUNDATION_EXPORT
5 | #if defined(__cplusplus)
6 | #define FOUNDATION_EXPORT extern "C"
7 | #else
8 | #define FOUNDATION_EXPORT extern
9 | #endif
10 | #endif
11 | #endif
12 |
13 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVRootViewController.h:
--------------------------------------------------------------------------------
1 | //
2 | // NVPIPViewController.h
3 | // NVPictureInPicture
4 | //
5 | // Created by niteshvijay1995 on 05/02/2018.
6 | // Copyright (c) 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | @import UIKit;
10 |
11 | @interface NVRootViewController : UIViewController
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/Example/Podfile.lock:
--------------------------------------------------------------------------------
1 | PODS:
2 | - NVPictureInPicture (1.0.0)
3 |
4 | DEPENDENCIES:
5 | - NVPictureInPicture (from `../`)
6 |
7 | EXTERNAL SOURCES:
8 | NVPictureInPicture:
9 | :path: ../
10 |
11 | SPEC CHECKSUMS:
12 | NVPictureInPicture: e6e126c236efa54bf8795a3afda56e7c5bdbcf62
13 |
14 | PODFILE CHECKSUM: 682ec50bd104b727b8b28f46269a977e33566c8f
15 |
16 | COCOAPODS: 1.4.0
17 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVPIPSubViewController.h:
--------------------------------------------------------------------------------
1 | //
2 | // NVPIPSubViewController.h
3 | // NVPictureInPicture_Example
4 | //
5 | // Created by Nitesh Vijay on 03/05/18.
6 | // Copyright © 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | #import "NVPictureInPictureViewController.h"
10 |
11 | @interface NVPIPSubViewController : NVPictureInPictureViewController
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/Example/Pods/Manifest.lock:
--------------------------------------------------------------------------------
1 | PODS:
2 | - NVPictureInPicture (1.0.0)
3 |
4 | DEPENDENCIES:
5 | - NVPictureInPicture (from `../`)
6 |
7 | EXTERNAL SOURCES:
8 | NVPictureInPicture:
9 | :path: ../
10 |
11 | SPEC CHECKSUMS:
12 | NVPictureInPicture: e6e126c236efa54bf8795a3afda56e7c5bdbcf62
13 |
14 | PODFILE CHECKSUM: 682ec50bd104b727b8b28f46269a977e33566c8f
15 |
16 | COCOAPODS: 1.4.0
17 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVPIPAppDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // NVPIPAppDelegate.h
3 | // NVPictureInPicture
4 | //
5 | // Created by niteshvijay1995 on 05/02/2018.
6 | // Copyright (c) 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | @import UIKit;
10 |
11 | @interface NVPIPAppDelegate : UIResponder
12 |
13 | @property (strong, nonatomic) UIWindow *window;
14 |
15 | @end
16 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVPictureInPicture-Prefix.pch:
--------------------------------------------------------------------------------
1 | //
2 | // Prefix header
3 | //
4 | // The contents of this file are implicitly included at the beginning of every source file.
5 | //
6 |
7 | #import
8 |
9 | #ifndef __IPHONE_5_0
10 | #warning "This project uses features only available in iOS SDK 5.0 and later."
11 | #endif
12 |
13 | #ifdef __OBJC__
14 | @import UIKit;
15 | @import Foundation;
16 | #endif
17 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/main.m:
--------------------------------------------------------------------------------
1 | //
2 | // main.m
3 | // NVPictureInPicture
4 | //
5 | // Created by niteshvijay1995 on 05/02/2018.
6 | // Copyright (c) 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | @import UIKit;
10 | #import "NVPIPAppDelegate.h"
11 |
12 | int main(int argc, char * argv[])
13 | {
14 | @autoreleasepool {
15 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([NVPIPAppDelegate class]));
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-umbrella.h:
--------------------------------------------------------------------------------
1 | #ifdef __OBJC__
2 | #import
3 | #else
4 | #ifndef FOUNDATION_EXPORT
5 | #if defined(__cplusplus)
6 | #define FOUNDATION_EXPORT extern "C"
7 | #else
8 | #define FOUNDATION_EXPORT extern
9 | #endif
10 | #endif
11 | #endif
12 |
13 |
14 | FOUNDATION_EXPORT double Pods_NVPictureInPicture_TestsVersionNumber;
15 | FOUNDATION_EXPORT const unsigned char Pods_NVPictureInPicture_TestsVersionString[];
16 |
17 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-umbrella.h:
--------------------------------------------------------------------------------
1 | #ifdef __OBJC__
2 | #import
3 | #else
4 | #ifndef FOUNDATION_EXPORT
5 | #if defined(__cplusplus)
6 | #define FOUNDATION_EXPORT extern "C"
7 | #else
8 | #define FOUNDATION_EXPORT extern
9 | #endif
10 | #endif
11 | #endif
12 |
13 |
14 | FOUNDATION_EXPORT double Pods_NVPictureInPicture_ExampleVersionNumber;
15 | FOUNDATION_EXPORT const unsigned char Pods_NVPictureInPicture_ExampleVersionString[];
16 |
17 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/NVPictureInPicture/NVPictureInPicture-umbrella.h:
--------------------------------------------------------------------------------
1 | #ifdef __OBJC__
2 | #import
3 | #else
4 | #ifndef FOUNDATION_EXPORT
5 | #if defined(__cplusplus)
6 | #define FOUNDATION_EXPORT extern "C"
7 | #else
8 | #define FOUNDATION_EXPORT extern
9 | #endif
10 | #endif
11 | #endif
12 |
13 | #import "NVPictureInPicture.h"
14 | #import "NVPIPViewController.h"
15 | #import "NVPIPWindow.h"
16 |
17 | FOUNDATION_EXPORT double NVPictureInPictureVersionNumber;
18 | FOUNDATION_EXPORT const unsigned char NVPictureInPictureVersionString[];
19 |
20 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | # references:
2 | # * https://www.objc.io/issues/6-build-tools/travis-ci/
3 | # * https://github.com/supermarin/xcpretty#usage
4 |
5 | osx_image: xcode9.3
6 | language: objective-c
7 | # cache: cocoapods
8 | # podfile: Example/Podfile
9 | # before_install:
10 | # - gem install cocoapods # Since Travis is not always on latest version
11 | # - pod install --project-directory=Example
12 | script:
13 | # - set -o pipefail && xcodebuild test -enableCodeCoverage YES -workspace Example/NVPictureInPicture.xcworkspace -scheme NVPictureInPicture-Example -sdk iphonesimulator11.3 ONLY_ACTIVE_ARCH=NO | xcpretty
14 | - pod lib lint
15 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/NVPictureInPicture/NVPictureInPicture.xcconfig:
--------------------------------------------------------------------------------
1 | CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/NVPictureInPicture
2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
3 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/NVPictureInPicture" "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
4 | PODS_BUILD_DIR = ${BUILD_DIR}
5 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
6 | PODS_ROOT = ${SRCROOT}
7 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/../..
8 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier}
9 | SKIP_INSTALL = YES
10 |
--------------------------------------------------------------------------------
/Example/Tests/Tests.m:
--------------------------------------------------------------------------------
1 | //
2 | // NVPictureInPictureTests.m
3 | // NVPictureInPictureTests
4 | //
5 | // Created by niteshvijay1995 on 05/02/2018.
6 | // Copyright (c) 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | @import XCTest;
10 |
11 | @interface Tests : XCTestCase
12 |
13 | @end
14 |
15 | @implementation Tests
16 |
17 | - (void)setUp
18 | {
19 | [super setUp];
20 | // Put setup code here. This method is called before the invocation of each test method in the class.
21 | }
22 |
23 | - (void)tearDown
24 | {
25 | // Put teardown code here. This method is called after the invocation of each test method in the class.
26 | [super tearDown];
27 | }
28 |
29 | @end
30 |
31 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests.debug.xcconfig:
--------------------------------------------------------------------------------
1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
2 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
3 | LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/NVPictureInPicture"
4 | OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
5 | OTHER_LDFLAGS = $(inherited) -ObjC
6 | PODS_BUILD_DIR = ${BUILD_DIR}
7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/.
9 | PODS_ROOT = ${SRCROOT}/Pods
10 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests.release.xcconfig:
--------------------------------------------------------------------------------
1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
2 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
3 | LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/NVPictureInPicture"
4 | OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
5 | OTHER_LDFLAGS = $(inherited) -ObjC
6 | PODS_BUILD_DIR = ${BUILD_DIR}
7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/.
9 | PODS_ROOT = ${SRCROOT}/Pods
10 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example.debug.xcconfig:
--------------------------------------------------------------------------------
1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
2 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
3 | LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/NVPictureInPicture"
4 | OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
5 | OTHER_LDFLAGS = $(inherited) -ObjC -l"NVPictureInPicture"
6 | PODS_BUILD_DIR = ${BUILD_DIR}
7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/.
9 | PODS_ROOT = ${SRCROOT}/Pods
10 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example.release.xcconfig:
--------------------------------------------------------------------------------
1 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
2 | HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Public" "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
3 | LIBRARY_SEARCH_PATHS = $(inherited) "${PODS_CONFIGURATION_BUILD_DIR}/NVPictureInPicture"
4 | OTHER_CFLAGS = $(inherited) -isystem "${PODS_ROOT}/Headers/Public" -isystem "${PODS_ROOT}/Headers/Public/NVPictureInPicture"
5 | OTHER_LDFLAGS = $(inherited) -ObjC -l"NVPictureInPicture"
6 | PODS_BUILD_DIR = ${BUILD_DIR}
7 | PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
8 | PODS_PODFILE_DIR_PATH = ${SRCROOT}/.
9 | PODS_ROOT = ${SRCROOT}/Pods
10 |
--------------------------------------------------------------------------------
/Example/Tests/Tests-Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundlePackageType
14 | BNDL
15 | CFBundleShortVersionString
16 | 1.0
17 | CFBundleSignature
18 | ????
19 | CFBundleVersion
20 | 1
21 |
22 |
23 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # OS X
2 | .DS_Store
3 |
4 | # Xcode
5 | build/
6 | *.pbxuser
7 | !default.pbxuser
8 | *.mode1v3
9 | !default.mode1v3
10 | *.mode2v3
11 | !default.mode2v3
12 | *.perspectivev3
13 | !default.perspectivev3
14 | xcuserdata/
15 | *.xccheckout
16 | profile
17 | *.moved-aside
18 | DerivedData
19 | *.hmap
20 | *.ipa
21 |
22 | # Bundler
23 | .bundle
24 |
25 | # Add this line if you want to avoid checking in source code from Carthage dependencies.
26 | # Carthage/Checkouts
27 |
28 | Carthage/Build
29 |
30 | # We recommend against adding the Pods directory to your .gitignore. However
31 | # you should judge for yourself, the pros and cons are mentioned at:
32 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-ignore-the-pods-directory-in-source-control
33 | #
34 | # Note: if you ignore the Pods directory, make sure to uncomment
35 | # `pod install` in .travis.yml
36 | #
37 | # Pods/
38 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/NVPictureInPicture/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | ${PRODUCT_BUNDLE_IDENTIFIER}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 0.1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | ${CURRENT_PROJECT_VERSION}
23 | NSPrincipalClass
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | ${PRODUCT_BUNDLE_IDENTIFIER}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | ${CURRENT_PROJECT_VERSION}
23 | NSPrincipalClass
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | ${PRODUCT_BUNDLE_IDENTIFIER}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | ${CURRENT_PROJECT_VERSION}
23 | NSPrincipalClass
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/Example/Pods/Local Podspecs/NVPictureInPicture.podspec.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "NVPictureInPicture",
3 | "version": "1.0.0",
4 | "summary": "Picture in Picture for iPhone. It lets you present content floating on top of application.",
5 | "description": "NVPictureInPicture lets you present your custom view controller in Picture-in-Picture view floating on top of your application.\nThe purpose of Picture in Picture is to make your application usable while playing video or on video call.\nThe size and edge insets of Picture in Picture view is customizable.",
6 | "homepage": "https://github.com/niteshvijay1995/NVPictureInPicture",
7 | "license": {
8 | "type": "MIT",
9 | "file": "LICENSE"
10 | },
11 | "authors": {
12 | "niteshvijay1995": "niteshvijay1995@gmail.com"
13 | },
14 | "source": {
15 | "git": "https://github.com/niteshvijay1995/NVPictureInPicture.git",
16 | "tag": "1.0.0"
17 | },
18 | "platforms": {
19 | "ios": "8.0"
20 | },
21 | "source_files": "NVPictureInPicture/Classes/**/*"
22 | }
23 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-acknowledgements.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreferenceSpecifiers
6 |
7 |
8 | FooterText
9 | This application makes use of the following third party libraries:
10 | Title
11 | Acknowledgements
12 | Type
13 | PSGroupSpecifier
14 |
15 |
16 | FooterText
17 | Generated by CocoaPods - https://cocoapods.org
18 | Title
19 |
20 | Type
21 | PSGroupSpecifier
22 |
23 |
24 | StringsTable
25 | Acknowledgements
26 | Title
27 | Acknowledgements
28 |
29 |
30 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVRootViewController.m:
--------------------------------------------------------------------------------
1 | //
2 | // NVPIPViewController.m
3 | // NVPictureInPicture
4 | //
5 | // Created by niteshvijay1995 on 05/02/2018.
6 | // Copyright (c) 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | #import "NVRootViewController.h"
10 | #import "NVPIPSubViewController.h"
11 |
12 |
13 | @interface NVRootViewController ()
14 |
15 | @end
16 |
17 | @implementation NVRootViewController
18 |
19 | - (IBAction)handleTap:(UIButton *)sender {
20 | [self.view endEditing:YES];
21 | NVPIPSubViewController *viewController = (NVPIPSubViewController *)[[UIStoryboard storyboardWithName:@"Main" bundle:nil] instantiateViewControllerWithIdentifier:@"NVPIPSubViewController"];
22 | viewController.view.backgroundColor = sender.backgroundColor;
23 | [viewController presentPictureInPictureViewControllerOnWindow:UIApplication.sharedApplication.keyWindow animated:YES completion:nil];
24 | }
25 |
26 | - (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
27 | [self.view endEditing:YES];
28 | }
29 |
30 | @end
31 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2018 niteshvijay1995
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in
11 | all copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # NVPictureInPicture
2 |
3 | [](https://travis-ci.org/niteshvijay1995/NVPictureInPicture)
4 | [](https://cocoapods.org/pods/NVPictureInPicture)
5 | [](https://cocoapods.org/pods/NVPictureInPicture)
6 | [](https://cocoapods.org/pods/NVPictureInPicture)
7 |
8 | Picture in Picture for iPhone. It lets you present content floating on top of application.
9 |
10 | ## Example
11 |
12 | To run the example project, clone the repo, and run `pod install` from the Example directory first.
13 |
14 | ## Installation
15 |
16 | NVPictureInPicture is available through [CocoaPods](https://cocoapods.org). To install
17 | it, simply add the following line to your Podfile:
18 |
19 | ```ruby
20 | pod 'NVPictureInPicture'
21 | ```
22 |
23 | ## Usage
24 |
25 | 1. Subclass NVPictureInPictureViewController to create custom view controller supporting Picture in Picture.
26 | 2. Use presentOnWindow: to present view on window.
27 |
28 | ## Author
29 |
30 | niteshvijay1995, niteshvijay1995@gmail.com
31 |
32 | ## License
33 |
34 | NVPictureInPicture is available under the MIT license. See the LICENSE file for more info.
35 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-acknowledgements.markdown:
--------------------------------------------------------------------------------
1 | # Acknowledgements
2 | This application makes use of the following third party libraries:
3 |
4 | ## NVPictureInPicture
5 |
6 | Copyright (c) 2018 niteshvijay1995
7 |
8 | Permission is hereby granted, free of charge, to any person obtaining a copy
9 | of this software and associated documentation files (the "Software"), to deal
10 | in the Software without restriction, including without limitation the rights
11 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12 | copies of the Software, and to permit persons to whom the Software is
13 | furnished to do so, subject to the following conditions:
14 |
15 | The above copyright notice and this permission notice shall be included in
16 | all copies or substantial portions of the Software.
17 |
18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
23 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
24 | THE SOFTWARE.
25 |
26 | Generated by CocoaPods - https://cocoapods.org
27 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVPictureInPicture-Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleDisplayName
8 | ${PRODUCT_NAME}
9 | CFBundleExecutable
10 | ${EXECUTABLE_NAME}
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | ${PRODUCT_NAME}
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | 1.0
21 | CFBundleSignature
22 | ????
23 | CFBundleVersion
24 | 1.0
25 | LSRequiresIPhoneOS
26 |
27 | UILaunchStoryboardName
28 | LaunchScreen
29 | UIMainStoryboardFile
30 | Main
31 | UIRequiredDeviceCapabilities
32 |
33 | armv7
34 |
35 | UISupportedInterfaceOrientations
36 |
37 | UIInterfaceOrientationPortrait
38 | UIInterfaceOrientationLandscapeLeft
39 | UIInterfaceOrientationLandscapeRight
40 |
41 | UISupportedInterfaceOrientations~ipad
42 |
43 | UIInterfaceOrientationPortrait
44 | UIInterfaceOrientationPortraitUpsideDown
45 | UIInterfaceOrientationLandscapeLeft
46 | UIInterfaceOrientationLandscapeRight
47 |
48 |
49 |
50 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/Images.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "size" : "20x20",
6 | "scale" : "2x"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "size" : "20x20",
11 | "scale" : "3x"
12 | },
13 | {
14 | "idiom" : "iphone",
15 | "size" : "29x29",
16 | "scale" : "2x"
17 | },
18 | {
19 | "idiom" : "iphone",
20 | "size" : "29x29",
21 | "scale" : "3x"
22 | },
23 | {
24 | "idiom" : "iphone",
25 | "size" : "40x40",
26 | "scale" : "2x"
27 | },
28 | {
29 | "idiom" : "iphone",
30 | "size" : "40x40",
31 | "scale" : "3x"
32 | },
33 | {
34 | "idiom" : "iphone",
35 | "size" : "60x60",
36 | "scale" : "2x"
37 | },
38 | {
39 | "idiom" : "iphone",
40 | "size" : "60x60",
41 | "scale" : "3x"
42 | },
43 | {
44 | "idiom" : "ipad",
45 | "size" : "20x20",
46 | "scale" : "1x"
47 | },
48 | {
49 | "idiom" : "ipad",
50 | "size" : "20x20",
51 | "scale" : "2x"
52 | },
53 | {
54 | "idiom" : "ipad",
55 | "size" : "29x29",
56 | "scale" : "1x"
57 | },
58 | {
59 | "idiom" : "ipad",
60 | "size" : "29x29",
61 | "scale" : "2x"
62 | },
63 | {
64 | "idiom" : "ipad",
65 | "size" : "40x40",
66 | "scale" : "1x"
67 | },
68 | {
69 | "idiom" : "ipad",
70 | "size" : "40x40",
71 | "scale" : "2x"
72 | },
73 | {
74 | "idiom" : "ipad",
75 | "size" : "76x76",
76 | "scale" : "1x"
77 | },
78 | {
79 | "idiom" : "ipad",
80 | "size" : "76x76",
81 | "scale" : "2x"
82 | },
83 | {
84 | "idiom" : "ipad",
85 | "size" : "83.5x83.5",
86 | "scale" : "2x"
87 | },
88 | {
89 | "idiom" : "ios-marketing",
90 | "size" : "1024x1024",
91 | "scale" : "1x"
92 | }
93 | ],
94 | "info" : {
95 | "version" : 1,
96 | "author" : "xcode"
97 | }
98 | }
99 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVPIPAppDelegate.m:
--------------------------------------------------------------------------------
1 | //
2 | // NVPIPAppDelegate.m
3 | // NVPictureInPicture
4 | //
5 | // Created by niteshvijay1995 on 05/02/2018.
6 | // Copyright (c) 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | #import "NVPIPAppDelegate.h"
10 |
11 | @implementation NVPIPAppDelegate
12 |
13 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
14 | {
15 | // Override point for customization after application launch.
16 | return YES;
17 | }
18 |
19 | - (void)applicationWillResignActive:(UIApplication *)application
20 | {
21 | // 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.
22 | // 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.
23 | }
24 |
25 | - (void)applicationDidEnterBackground:(UIApplication *)application
26 | {
27 | // 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.
28 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
29 | }
30 |
31 | - (void)applicationWillEnterForeground:(UIApplication *)application
32 | {
33 | // 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.
34 | }
35 |
36 | - (void)applicationDidBecomeActive:(UIApplication *)application
37 | {
38 | // 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.
39 | }
40 |
41 | - (void)applicationWillTerminate:(UIApplication *)application
42 | {
43 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
44 | }
45 |
46 | @end
47 |
--------------------------------------------------------------------------------
/NVPictureInPicture.podspec:
--------------------------------------------------------------------------------
1 | #
2 | # Be sure to run `pod lib lint NVPictureInPicture.podspec' to ensure this is a
3 | # valid spec before submitting.
4 | #
5 | # Any lines starting with a # are optional, but their use is encouraged
6 | # To learn more about a Podspec see https://guides.cocoapods.org/syntax/podspec.html
7 | #
8 |
9 | Pod::Spec.new do |s|
10 | s.name = 'NVPictureInPicture'
11 | s.version = '1.0.1'
12 | s.summary = 'Picture in Picture for iPhone. It lets you present content floating on top of application.'
13 |
14 | # This description is used to generate tags and improve search results.
15 | # * Think: What does it do? Why did you write it? What is the focus?
16 | # * Try to keep it short, snappy and to the point.
17 | # * Write the description between the DESC delimiters below.
18 | # * Finally, don't worry about the indent, CocoaPods strips it!
19 |
20 | s.description = <<-DESC
21 | NVPictureInPicture lets you present your custom view controller in Picture-in-Picture view floating on top of your application.
22 | The purpose of Picture in Picture is to make your application usable while playing video or on video call.
23 | The size and edge insets of Picture in Picture view is customizable.
24 | DESC
25 |
26 | s.homepage = 'https://github.com/niteshvijay1995/NVPictureInPicture'
27 | # s.screenshots = 'www.example.com/screenshots_1', 'www.example.com/screenshots_2'
28 | s.license = { :type => 'MIT', :file => 'LICENSE' }
29 | s.author = { 'niteshvijay1995' => 'niteshvijay1995@gmail.com' }
30 | s.source = { :git => 'https://github.com/niteshvijay1995/NVPictureInPicture.git', :tag => s.version.to_s }
31 | # s.social_media_url = 'https://twitter.com/'
32 |
33 | s.ios.deployment_target = '8.0'
34 |
35 | s.source_files = 'NVPictureInPicture/Classes/**/*'
36 |
37 | # s.resource_bundles = {
38 | # 'NVPictureInPicture' => ['NVPictureInPicture/Assets/*.png']
39 | # }
40 |
41 | # s.public_header_files = 'Pod/Classes/**/*.h'
42 | # s.frameworks = 'UIKit', 'MapKit'
43 | # s.dependency 'AFNetworking', '~> 2.3'
44 | end
45 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-acknowledgements.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreferenceSpecifiers
6 |
7 |
8 | FooterText
9 | This application makes use of the following third party libraries:
10 | Title
11 | Acknowledgements
12 | Type
13 | PSGroupSpecifier
14 |
15 |
16 | FooterText
17 | Copyright (c) 2018 niteshvijay1995 <niteshvijay1995@gmail.com>
18 |
19 | Permission is hereby granted, free of charge, to any person obtaining a copy
20 | of this software and associated documentation files (the "Software"), to deal
21 | in the Software without restriction, including without limitation the rights
22 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
23 | copies of the Software, and to permit persons to whom the Software is
24 | furnished to do so, subject to the following conditions:
25 |
26 | The above copyright notice and this permission notice shall be included in
27 | all copies or substantial portions of the Software.
28 |
29 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
30 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
31 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
32 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
33 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
34 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
35 | THE SOFTWARE.
36 |
37 | License
38 | MIT
39 | Title
40 | NVPictureInPicture
41 | Type
42 | PSGroupSpecifier
43 |
44 |
45 | FooterText
46 | Generated by CocoaPods - https://cocoapods.org
47 | Title
48 |
49 | Type
50 | PSGroupSpecifier
51 |
52 |
53 | StringsTable
54 | Acknowledgements
55 | Title
56 | Acknowledgements
57 |
58 |
59 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/NVPIPSubViewController.m:
--------------------------------------------------------------------------------
1 | //
2 | // NVPIPSubViewController.m
3 | // NVPictureInPicture_Example
4 | //
5 | // Created by Nitesh Vijay on 03/05/18.
6 | // Copyright © 2018 niteshvijay1995. All rights reserved.
7 | //
8 |
9 | #import "NVPIPSubViewController.h"
10 |
11 | static const CGFloat PictureInPictureCornerRadius = 5.0f;
12 |
13 | @interface NVPIPSubViewController ()
14 |
15 | @property (weak, nonatomic) IBOutlet UIButton *closeButton;
16 | @property (weak, nonatomic) IBOutlet UIButton *backButton;
17 | @property (weak, nonatomic) IBOutlet UILabel *pictureInPictureLabel;
18 | @property (weak, nonatomic) IBOutlet UISwitch *pictureInPictureSwitch;
19 |
20 | @end
21 |
22 | @implementation NVPIPSubViewController
23 |
24 | - (void)viewDidLoad {
25 | [super viewDidLoad];
26 | self.view.clipsToBounds = YES;
27 | self.pictureInPictureDelegate = self;
28 | self.backButton.alpha = 0;
29 | UITapGestureRecognizer *tapGesture = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(handleTap:)];
30 | [self.view addGestureRecognizer:tapGesture];
31 | }
32 |
33 | - (void)pictureInPictureViewControllerWillStartPictureInPicture:(NVPictureInPictureViewController *)pictureInPictureViewController {
34 | self.closeButton.alpha = 0;
35 | self.backButton.alpha = 0;
36 | self.pictureInPictureLabel.alpha = 0;
37 | self.pictureInPictureSwitch.alpha = 0;
38 | }
39 |
40 | - (void)pictureInPictureViewControllerDidStopPictureInPicture:(NVPictureInPictureViewController *)pictureInPictureViewController {
41 | self.closeButton.alpha = 1;
42 | self.backButton.alpha = 1;
43 | self.pictureInPictureLabel.alpha = 1;
44 | self.pictureInPictureSwitch.alpha = 1;
45 | }
46 |
47 | - (IBAction)back:(id)sender {
48 | self.closeButton.alpha = 0;
49 | self.backButton.alpha = 0;
50 | [self startPictureInPictureAnimated:YES];
51 | }
52 | - (IBAction)togglePictureInPicture:(UISwitch *)sender {
53 | if (sender.isOn) {
54 | [self enablePictureInPicture];
55 | self.backButton.alpha = 1;
56 | } else {
57 | [self disablePictureInPicture];
58 | self.backButton.alpha = 0;
59 | }
60 | }
61 |
62 | - (IBAction)close:(id)sender {
63 | [self dismissPictureInPictureViewControllerAnimated:YES completion:nil];
64 | }
65 |
66 | - (UIEdgeInsets)pictureInPictureEdgeInsets {
67 | if (UIApplication.sharedApplication.statusBarOrientation == UIInterfaceOrientationPortrait) {
68 | return UIEdgeInsetsMake(50, 10, 30, 10);
69 | } else {
70 | return UIEdgeInsetsMake(30, 10, 20, 10);
71 | }
72 | }
73 |
74 | - (void)updateViewWithTranslationPercentage:(CGFloat)percentage {
75 | [super updateViewWithTranslationPercentage:percentage];
76 | self.view.layer.cornerRadius = PictureInPictureCornerRadius * percentage;
77 | }
78 |
79 | - (void)handleTap:(UIGestureRecognizer *)gestureRecognizer {
80 | [self stopPictureInPictureAnimated:YES];
81 | }
82 |
83 | @end
84 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture.xcodeproj/xcshareddata/xcschemes/NVPictureInPicture-Example.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
33 |
39 |
40 |
41 |
42 |
43 |
49 |
50 |
51 |
52 |
53 |
54 |
64 |
66 |
72 |
73 |
74 |
75 |
76 |
77 |
83 |
85 |
91 |
92 |
93 |
94 |
96 |
97 |
100 |
101 |
102 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-resources.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | set -e
3 |
4 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
5 |
6 | RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt
7 | > "$RESOURCES_TO_COPY"
8 |
9 | XCASSET_FILES=()
10 |
11 | # This protects against multiple targets copying the same framework dependency at the same time. The solution
12 | # was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html
13 | RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????")
14 |
15 | case "${TARGETED_DEVICE_FAMILY}" in
16 | 1,2)
17 | TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone"
18 | ;;
19 | 1)
20 | TARGET_DEVICE_ARGS="--target-device iphone"
21 | ;;
22 | 2)
23 | TARGET_DEVICE_ARGS="--target-device ipad"
24 | ;;
25 | 3)
26 | TARGET_DEVICE_ARGS="--target-device tv"
27 | ;;
28 | 4)
29 | TARGET_DEVICE_ARGS="--target-device watch"
30 | ;;
31 | *)
32 | TARGET_DEVICE_ARGS="--target-device mac"
33 | ;;
34 | esac
35 |
36 | install_resource()
37 | {
38 | if [[ "$1" = /* ]] ; then
39 | RESOURCE_PATH="$1"
40 | else
41 | RESOURCE_PATH="${PODS_ROOT}/$1"
42 | fi
43 | if [[ ! -e "$RESOURCE_PATH" ]] ; then
44 | cat << EOM
45 | error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script.
46 | EOM
47 | exit 1
48 | fi
49 | case $RESOURCE_PATH in
50 | *.storyboard)
51 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" || true
52 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS}
53 | ;;
54 | *.xib)
55 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" || true
56 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS}
57 | ;;
58 | *.framework)
59 | echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" || true
60 | mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
61 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" || true
62 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
63 | ;;
64 | *.xcdatamodel)
65 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" || true
66 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom"
67 | ;;
68 | *.xcdatamodeld)
69 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" || true
70 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd"
71 | ;;
72 | *.xcmappingmodel)
73 | echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" || true
74 | xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm"
75 | ;;
76 | *.xcassets)
77 | ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH"
78 | XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE")
79 | ;;
80 | *)
81 | echo "$RESOURCE_PATH" || true
82 | echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY"
83 | ;;
84 | esac
85 | }
86 |
87 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
88 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
89 | if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then
90 | mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
91 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
92 | fi
93 | rm -f "$RESOURCES_TO_COPY"
94 |
95 | if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ]
96 | then
97 | # Find all other xcassets (this unfortunately includes those of path pods and other targets).
98 | OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d)
99 | while read line; do
100 | if [[ $line != "${PODS_ROOT}*" ]]; then
101 | XCASSET_FILES+=("$line")
102 | fi
103 | done <<<"$OTHER_XCASSETS"
104 |
105 | printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
106 | fi
107 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-resources.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | set -e
3 |
4 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
5 |
6 | RESOURCES_TO_COPY=${PODS_ROOT}/resources-to-copy-${TARGETNAME}.txt
7 | > "$RESOURCES_TO_COPY"
8 |
9 | XCASSET_FILES=()
10 |
11 | # This protects against multiple targets copying the same framework dependency at the same time. The solution
12 | # was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html
13 | RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????")
14 |
15 | case "${TARGETED_DEVICE_FAMILY}" in
16 | 1,2)
17 | TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone"
18 | ;;
19 | 1)
20 | TARGET_DEVICE_ARGS="--target-device iphone"
21 | ;;
22 | 2)
23 | TARGET_DEVICE_ARGS="--target-device ipad"
24 | ;;
25 | 3)
26 | TARGET_DEVICE_ARGS="--target-device tv"
27 | ;;
28 | 4)
29 | TARGET_DEVICE_ARGS="--target-device watch"
30 | ;;
31 | *)
32 | TARGET_DEVICE_ARGS="--target-device mac"
33 | ;;
34 | esac
35 |
36 | install_resource()
37 | {
38 | if [[ "$1" = /* ]] ; then
39 | RESOURCE_PATH="$1"
40 | else
41 | RESOURCE_PATH="${PODS_ROOT}/$1"
42 | fi
43 | if [[ ! -e "$RESOURCE_PATH" ]] ; then
44 | cat << EOM
45 | error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script.
46 | EOM
47 | exit 1
48 | fi
49 | case $RESOURCE_PATH in
50 | *.storyboard)
51 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" || true
52 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .storyboard`.storyboardc" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS}
53 | ;;
54 | *.xib)
55 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" || true
56 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS}
57 | ;;
58 | *.framework)
59 | echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" || true
60 | mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
61 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" || true
62 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
63 | ;;
64 | *.xcdatamodel)
65 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" || true
66 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom"
67 | ;;
68 | *.xcdatamodeld)
69 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" || true
70 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd"
71 | ;;
72 | *.xcmappingmodel)
73 | echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" || true
74 | xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm"
75 | ;;
76 | *.xcassets)
77 | ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH"
78 | XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE")
79 | ;;
80 | *)
81 | echo "$RESOURCE_PATH" || true
82 | echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY"
83 | ;;
84 | esac
85 | }
86 |
87 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
88 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
89 | if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then
90 | mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
91 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
92 | fi
93 | rm -f "$RESOURCES_TO_COPY"
94 |
95 | if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ]
96 | then
97 | # Find all other xcassets (this unfortunately includes those of path pods and other targets).
98 | OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d)
99 | while read line; do
100 | if [[ $line != "${PODS_ROOT}*" ]]; then
101 | XCASSET_FILES+=("$line")
102 | fi
103 | done <<<"$OTHER_XCASSETS"
104 |
105 | printf "%s\0" "${XCASSET_FILES[@]}" | xargs -0 xcrun actool --output-format human-readable-text --notices --warnings --platform "${PLATFORM_NAME}" --minimum-deployment-target "${!DEPLOYMENT_TARGET_SETTING_NAME}" ${TARGET_DEVICE_ARGS} --compress-pngs --compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"
106 | fi
107 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-frameworks.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | set -e
3 |
4 | echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
5 | mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
6 |
7 | SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"
8 |
9 | # Used as a return value for each invocation of `strip_invalid_archs` function.
10 | STRIP_BINARY_RETVAL=0
11 |
12 | # This protects against multiple targets copying the same framework dependency at the same time. The solution
13 | # was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html
14 | RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????")
15 |
16 | # Copies and strips a vendored framework
17 | install_framework()
18 | {
19 | if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then
20 | local source="${BUILT_PRODUCTS_DIR}/$1"
21 | elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then
22 | local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")"
23 | elif [ -r "$1" ]; then
24 | local source="$1"
25 | fi
26 |
27 | local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
28 |
29 | if [ -L "${source}" ]; then
30 | echo "Symlinked..."
31 | source="$(readlink "${source}")"
32 | fi
33 |
34 | # Use filter instead of exclude so missing patterns don't throw errors.
35 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\""
36 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}"
37 |
38 | local basename
39 | basename="$(basename -s .framework "$1")"
40 | binary="${destination}/${basename}.framework/${basename}"
41 | if ! [ -r "$binary" ]; then
42 | binary="${destination}/${basename}"
43 | fi
44 |
45 | # Strip invalid architectures so "fat" simulator / device frameworks work on device
46 | if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then
47 | strip_invalid_archs "$binary"
48 | fi
49 |
50 | # Resign the code if required by the build settings to avoid unstable apps
51 | code_sign_if_enabled "${destination}/$(basename "$1")"
52 |
53 | # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7.
54 | if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then
55 | local swift_runtime_libs
56 | swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]})
57 | for lib in $swift_runtime_libs; do
58 | echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\""
59 | rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}"
60 | code_sign_if_enabled "${destination}/${lib}"
61 | done
62 | fi
63 | }
64 |
65 | # Copies and strips a vendored dSYM
66 | install_dsym() {
67 | local source="$1"
68 | if [ -r "$source" ]; then
69 | # Copy the dSYM into a the targets temp dir.
70 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${DERIVED_FILES_DIR}\""
71 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${DERIVED_FILES_DIR}"
72 |
73 | local basename
74 | basename="$(basename -s .framework.dSYM "$source")"
75 | binary="${DERIVED_FILES_DIR}/${basename}.framework.dSYM/Contents/Resources/DWARF/${basename}"
76 |
77 | # Strip invalid architectures so "fat" simulator / device frameworks work on device
78 | if [[ "$(file "$binary")" == *"Mach-O dSYM companion"* ]]; then
79 | strip_invalid_archs "$binary"
80 | fi
81 |
82 | if [[ $STRIP_BINARY_RETVAL == 1 ]]; then
83 | # Move the stripped file into its final destination.
84 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${DERIVED_FILES_DIR}/${basename}.framework.dSYM\" \"${DWARF_DSYM_FOLDER_PATH}\""
85 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${DERIVED_FILES_DIR}/${basename}.framework.dSYM" "${DWARF_DSYM_FOLDER_PATH}"
86 | else
87 | # The dSYM was not stripped at all, in this case touch a fake folder so the input/output paths from Xcode do not reexecute this script because the file is missing.
88 | touch "${DWARF_DSYM_FOLDER_PATH}/${basename}.framework.dSYM"
89 | fi
90 | fi
91 | }
92 |
93 | # Signs a framework with the provided identity
94 | code_sign_if_enabled() {
95 | if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then
96 | # Use the current code_sign_identitiy
97 | echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}"
98 | local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements '$1'"
99 |
100 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then
101 | code_sign_cmd="$code_sign_cmd &"
102 | fi
103 | echo "$code_sign_cmd"
104 | eval "$code_sign_cmd"
105 | fi
106 | }
107 |
108 | # Strip invalid architectures
109 | strip_invalid_archs() {
110 | binary="$1"
111 | # Get architectures for current target binary
112 | binary_archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | awk '{$1=$1;print}' | rev)"
113 | # Intersect them with the architectures we are building for
114 | intersected_archs="$(echo ${ARCHS[@]} ${binary_archs[@]} | tr ' ' '\n' | sort | uniq -d)"
115 | # If there are no archs supported by this binary then warn the user
116 | if [[ -z "$intersected_archs" ]]; then
117 | echo "warning: [CP] Vendored binary '$binary' contains architectures ($binary_archs) none of which match the current build architectures ($ARCHS)."
118 | STRIP_BINARY_RETVAL=0
119 | return
120 | fi
121 | stripped=""
122 | for arch in $binary_archs; do
123 | if ! [[ "${ARCHS}" == *"$arch"* ]]; then
124 | # Strip non-valid architectures in-place
125 | lipo -remove "$arch" -output "$binary" "$binary" || exit 1
126 | stripped="$stripped $arch"
127 | fi
128 | done
129 | if [[ "$stripped" ]]; then
130 | echo "Stripped $binary of architectures:$stripped"
131 | fi
132 | STRIP_BINARY_RETVAL=1
133 | }
134 |
135 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then
136 | wait
137 | fi
138 |
--------------------------------------------------------------------------------
/Example/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-frameworks.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | set -e
3 |
4 | echo "mkdir -p ${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
5 | mkdir -p "${CONFIGURATION_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
6 |
7 | SWIFT_STDLIB_PATH="${DT_TOOLCHAIN_DIR}/usr/lib/swift/${PLATFORM_NAME}"
8 |
9 | # Used as a return value for each invocation of `strip_invalid_archs` function.
10 | STRIP_BINARY_RETVAL=0
11 |
12 | # This protects against multiple targets copying the same framework dependency at the same time. The solution
13 | # was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html
14 | RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????")
15 |
16 | # Copies and strips a vendored framework
17 | install_framework()
18 | {
19 | if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then
20 | local source="${BUILT_PRODUCTS_DIR}/$1"
21 | elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then
22 | local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")"
23 | elif [ -r "$1" ]; then
24 | local source="$1"
25 | fi
26 |
27 | local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}"
28 |
29 | if [ -L "${source}" ]; then
30 | echo "Symlinked..."
31 | source="$(readlink "${source}")"
32 | fi
33 |
34 | # Use filter instead of exclude so missing patterns don't throw errors.
35 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\""
36 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}"
37 |
38 | local basename
39 | basename="$(basename -s .framework "$1")"
40 | binary="${destination}/${basename}.framework/${basename}"
41 | if ! [ -r "$binary" ]; then
42 | binary="${destination}/${basename}"
43 | fi
44 |
45 | # Strip invalid architectures so "fat" simulator / device frameworks work on device
46 | if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then
47 | strip_invalid_archs "$binary"
48 | fi
49 |
50 | # Resign the code if required by the build settings to avoid unstable apps
51 | code_sign_if_enabled "${destination}/$(basename "$1")"
52 |
53 | # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7.
54 | if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then
55 | local swift_runtime_libs
56 | swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]})
57 | for lib in $swift_runtime_libs; do
58 | echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\""
59 | rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}"
60 | code_sign_if_enabled "${destination}/${lib}"
61 | done
62 | fi
63 | }
64 |
65 | # Copies and strips a vendored dSYM
66 | install_dsym() {
67 | local source="$1"
68 | if [ -r "$source" ]; then
69 | # Copy the dSYM into a the targets temp dir.
70 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${DERIVED_FILES_DIR}\""
71 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${DERIVED_FILES_DIR}"
72 |
73 | local basename
74 | basename="$(basename -s .framework.dSYM "$source")"
75 | binary="${DERIVED_FILES_DIR}/${basename}.framework.dSYM/Contents/Resources/DWARF/${basename}"
76 |
77 | # Strip invalid architectures so "fat" simulator / device frameworks work on device
78 | if [[ "$(file "$binary")" == *"Mach-O dSYM companion"* ]]; then
79 | strip_invalid_archs "$binary"
80 | fi
81 |
82 | if [[ $STRIP_BINARY_RETVAL == 1 ]]; then
83 | # Move the stripped file into its final destination.
84 | echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${DERIVED_FILES_DIR}/${basename}.framework.dSYM\" \"${DWARF_DSYM_FOLDER_PATH}\""
85 | rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${DERIVED_FILES_DIR}/${basename}.framework.dSYM" "${DWARF_DSYM_FOLDER_PATH}"
86 | else
87 | # The dSYM was not stripped at all, in this case touch a fake folder so the input/output paths from Xcode do not reexecute this script because the file is missing.
88 | touch "${DWARF_DSYM_FOLDER_PATH}/${basename}.framework.dSYM"
89 | fi
90 | fi
91 | }
92 |
93 | # Signs a framework with the provided identity
94 | code_sign_if_enabled() {
95 | if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then
96 | # Use the current code_sign_identitiy
97 | echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}"
98 | local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements '$1'"
99 |
100 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then
101 | code_sign_cmd="$code_sign_cmd &"
102 | fi
103 | echo "$code_sign_cmd"
104 | eval "$code_sign_cmd"
105 | fi
106 | }
107 |
108 | # Strip invalid architectures
109 | strip_invalid_archs() {
110 | binary="$1"
111 | # Get architectures for current target binary
112 | binary_archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | awk '{$1=$1;print}' | rev)"
113 | # Intersect them with the architectures we are building for
114 | intersected_archs="$(echo ${ARCHS[@]} ${binary_archs[@]} | tr ' ' '\n' | sort | uniq -d)"
115 | # If there are no archs supported by this binary then warn the user
116 | if [[ -z "$intersected_archs" ]]; then
117 | echo "warning: [CP] Vendored binary '$binary' contains architectures ($binary_archs) none of which match the current build architectures ($ARCHS)."
118 | STRIP_BINARY_RETVAL=0
119 | return
120 | fi
121 | stripped=""
122 | for arch in $binary_archs; do
123 | if ! [[ "${ARCHS}" == *"$arch"* ]]; then
124 | # Strip non-valid architectures in-place
125 | lipo -remove "$arch" -output "$binary" "$binary" || exit 1
126 | stripped="$stripped $arch"
127 | fi
128 | done
129 | if [[ "$stripped" ]]; then
130 | echo "Stripped $binary of architectures:$stripped"
131 | fi
132 | STRIP_BINARY_RETVAL=1
133 | }
134 |
135 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then
136 | wait
137 | fi
138 |
--------------------------------------------------------------------------------
/NVPictureInPicture/Classes/NVPictureInPictureViewController.h:
--------------------------------------------------------------------------------
1 | //
2 | // NVPictureInPictureViewController.h
3 | // NVPictureInPicture
4 | //
5 | // Created by Nitesh Vijay on 10/05/18.
6 | //
7 |
8 | #import
9 |
10 | @protocol NVPictureInPictureViewControllerDelegate;
11 |
12 | /*!
13 | @class NVPictureInPictureViewController
14 | @abstract NVPictureInPictureViewController is a subclass of UIViewController that can be used to present the contents floating on top of application. Subclass this class to create view controller supporting Picture in Picture. Picture in Picture can be activated either with a pan gesture or by calling -startPictureInPicture.
15 | @note Picture in Picture is disabled by default. Call -enablePictureInPicture to enable it.
16 | */
17 | @interface NVPictureInPictureViewController : UIViewController
18 |
19 | /*!
20 | @property delegate
21 | @abstract The receiver's delegate.
22 | */
23 | @property (nonatomic, weak) id pictureInPictureDelegate;
24 |
25 | /*!
26 | @property pictureInPictureActive
27 | @abstract Whether or not Picture in Picture is currently active.
28 | */
29 | @property(nonatomic, readonly, getter=isPictureInPictureActive) BOOL pictureInPictureActive;
30 |
31 | /*!
32 | @property pictureInPictureEnabled
33 | @abstract Whether or not Picture in Picture is enabled.
34 | */
35 | @property (nonatomic, readonly, getter=isPictureInPictureEnabled) BOOL pictureInPictureEnabled;
36 |
37 | /*!
38 | @method presentPictureInPictureViewControllerOnWindow:animated:completion
39 | @param window
40 | Window of the application where the view is to be added as subview.
41 | @method animated
42 | Presented modally if animated is true.
43 | @param completion
44 | The completion handler, if provided, will be invoked after the presented controller's viewDidAppear: callback is invoked.
45 | @abstract Present NVPictureInPictureViewController
46 | @discussion The view will be presented modally. The view controller will be added as a child of rootViewController of window
47 | */
48 | - (void)presentPictureInPictureViewControllerOnWindow:(UIWindow *)window animated:(BOOL)animated completion:(void (^ _Nullable)(void))completion;
49 |
50 | /*!
51 | @method dismiss
52 | @param animated
53 | Dismissed modally if animated is true.
54 | @param completion
55 | The completion handler, if provided, will be invoked after the dismissed controller's viewDidDisappear: callback is invoked.
56 | @abstract Dismiss NVPictureInPictureViewController
57 | @discussion The view will be dismissed modally. The view and the controller will be removed from the parent.
58 | */
59 | - (void)dismissPictureInPictureViewControllerAnimated:(BOOL)animated completion:(void (^ __nullable)(void))completion;
60 |
61 | /*!
62 | @method reloadPictureInPicture
63 | @abstract Reload Picture in Picture View Controller.
64 | @discussion Reloads everything from scratch. The display mode is preserved. Call reloadPictureInPicture if there is any change in DataSource.
65 | @note Reload is called by default on rotation.
66 | */
67 | - (void)reloadPictureInPicture;
68 |
69 | /*!
70 | @method enablePictureInPicture
71 | @abstract Enable Picture in Picture
72 | @discussion Set pictureInPictureEnabled to YES. Enable pan gesture transition from fullscreen to Picture in Picture.
73 | @note Picture in Picture is disabled by default.
74 | */
75 | - (void)enablePictureInPicture;
76 |
77 | /*!
78 | @method disablePictureInPicture
79 | @abstract Disable Picture in Picture
80 | @discussion Set pictureInPictureEnabled to NO. Disable pan gesture transition from fullscreen to Picture in Picture.
81 | @note It is recommended to first call -stopPictureInPicture if Picture in Picture is active.
82 | */
83 | - (void)disablePictureInPicture;
84 |
85 | /*!
86 | @method startPictureInPictureAnimated:
87 | @method animated
88 | Start Picture in Picture with animations if animated is true.
89 | @abstract Start Picture in Picture with animation.
90 | @discussion Receiver will call -pictureInPictureViewControllerWillStartPictureInPicture: before transition to Picture in Picture and -pictureInPictureViewControllerDidStartPictureInPicture: after successful transition. Client can stop Picture in Picture by calling -stopPictureInPicture. In addition the user can stop Picture in Picture through pan gesture.
91 | @note startPictureInPicture will only work when Picture in Picture is enabled
92 | */
93 | - (void)startPictureInPictureAnimated:(BOOL)animated;
94 |
95 | /*!
96 | @method stopPictureInPictureAnimated:
97 | @method animated
98 | Stop Picture in Picture with animations if animated is true.
99 | @abstract Stop Picture in Picture with animation.
100 | @discussion Receiver will call -pictureInPictureViewControllerWillStopPictureInPicture: before transition to full screen and -pictureInPictureViewControllerDidStopPictureInPicture: after successful transition. Client can stop Picture in Picture by calling -stopPictureInPicture. In addition the user can stop Picture in Picture through tap on view.
101 | */
102 | - (void)stopPictureInPictureAnimated:(BOOL)animated;
103 |
104 | /*!
105 | @method updateViewWithTranslationPercentage:
106 | @param percentage
107 | CGFloat ranging from 0 to 1, where 0 is Fullscreen and 1 is Picture in Picture.
108 | @abstract Override this method to implement custom view update on translation from full screen to Picture in Picture
109 | @note Call super in subclass implementation for default size translation.
110 | */
111 | - (void)updateViewWithTranslationPercentage:(CGFloat)percentage;
112 |
113 | /*!
114 | @method [Layout] pictureInPictureEdgeInsets
115 | @abstract Implement this method in subclass to return custom edge insets for Picture in Picture View.
116 | @discussion If not implemented, default insets will be used which is 10 for all edges. The Edge Insets are calculated with respect to device screen bounds.
117 | */
118 | - (UIEdgeInsets)pictureInPictureEdgeInsets;
119 |
120 | /*!
121 | @method [Layout] pictureInPictureSize
122 | @abstract Implement this method in subclass to return custom size for Picture in Picture View.
123 | @discussion If not implemented, default size will be used which is {100, 150}.
124 | */
125 | - (CGSize)pictureInPictureSize;
126 |
127 | @end
128 |
129 | /*!
130 | @protocol NVPictureInPictureViewControllerDelegate
131 | @abstract A protocol for delegates of NVPictureInPictureViewController.
132 | */
133 | @protocol NVPictureInPictureViewControllerDelegate
134 |
135 | @optional
136 |
137 | /*!
138 | @method pictureInPictureViewControllerWillStartPictureInPicture:
139 | @param pictureInPictureViewController
140 | The Picture in Picture view controller.
141 | @abstract Delegate can implement this method to be notified when Picture in Picture will start.
142 | */
143 | - (void)pictureInPictureViewControllerWillStartPictureInPicture:(NVPictureInPictureViewController *)pictureInPictureViewController;
144 |
145 | /*!
146 | @method pictureInPictureViewControllerDidStartPictureInPicture:
147 | @param pictureInPictureViewController
148 | The Picture in Picture controller.
149 | @abstract Delegate can implement this method to be notified when Picture in Picture did start.
150 | */
151 | - (void)pictureInPictureViewControllerDidStartPictureInPicture:(NVPictureInPictureViewController *)pictureInPictureViewController;
152 |
153 | /*!
154 | @method pictureInPictureViewControllerWillStopPictureInPicture:
155 | @param pictureInPictureViewController
156 | The Picture in Picture controller.
157 | @abstract Delegate can implement this method to be notified when Picture in Picture will stop.
158 | */
159 | - (void)pictureInPictureViewControllerWillStopPictureInPicture:(NVPictureInPictureViewController *)pictureInPictureViewController;
160 |
161 | /*!
162 | @method pictureInPictureViewControllerDidStopPictureInPicture:
163 | @param pictureInPictureViewController
164 | The Picture in Picture controller.
165 | @abstract Delegate can implement this method to be notified when Picture in Picture did stop.
166 | */
167 | - (void)pictureInPictureViewControllerDidStopPictureInPicture:(NVPictureInPictureViewController *)pictureInPictureViewController;
168 |
169 | @end
170 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
39 |
53 |
67 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
135 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 |
--------------------------------------------------------------------------------
/NVPictureInPicture/Classes/NVPictureInPictureViewController.m:
--------------------------------------------------------------------------------
1 | //
2 | // NVPictureInPictureViewController.m
3 | // NVPictureInPicture
4 | //
5 | // Created by Nitesh Vijay on 10/05/18.
6 | //
7 |
8 | #import "NVPictureInPictureViewController.h"
9 |
10 | #define NVAssertMainThread NSAssert([NSThread isMainThread], @"[NVPictureInPicture] NVPictureInPicture should be called from main thread only.")
11 |
12 |
13 | typedef NS_ENUM(NSInteger, PictureInPictureVerticalPosition) {
14 | top = -1,
15 | bottom = 1
16 | };
17 |
18 | typedef NS_ENUM(NSInteger, PictureInPictureHorizontalPosition) {
19 | left = -1,
20 | right = 1
21 | };
22 |
23 | static const CGSize DefaultPictureInPictureSize = {100, 150};
24 | static const UIEdgeInsets DefaultPictureInPictureEdgeInsets = {5,5,5,5};
25 | static const CGFloat PanSensitivity = 1.5f;
26 | static const CGFloat ThresholdTranslationPercentageForPictureInPicture = 0.4;
27 | static const CGFloat AnimationDuration = 0.3f;
28 | static const CGFloat FreeFlowTimeAfterPan = 0.05;
29 | static const CGFloat AnimationDamping = 1.0f;
30 | static const CGFloat PresentationAnimationDuration = 0.5f;
31 | static const CGFloat PresentationAnimationVelocity = 0.5f;
32 |
33 | @interface NVPictureInPictureViewController ()
34 |
35 | @property (nonatomic) BOOL pictureInPictureActive;
36 | @property (nonatomic) BOOL pictureInPictureEnabled;
37 | @property (nonatomic, getter=isRecognizingGesture) BOOL recognizingGesture;
38 | @property (nonatomic) UIPanGestureRecognizer *panGesture;
39 | @property (nonatomic) CGSize pipSize;
40 | @property (nonatomic) CGSize fullScreenSize;
41 | @property (nonatomic) UIEdgeInsets pipEdgeInsets;
42 | @property (nonatomic) CGFloat keyboardHeight;
43 | @property (nonatomic) CGPoint pipCenter;
44 | @property (nonatomic) CGPoint fullScreenCenter;
45 | @property (nonatomic) CGPoint lastPointBeforeKeyboardToggle;
46 | @property (nonatomic) BOOL noInteractionFlag;
47 |
48 | @end
49 |
50 | @implementation NVPictureInPictureViewController
51 |
52 | - (void)loadView {
53 | [super loadView];
54 | [self loadValues];
55 | self.panGesture = [[UIPanGestureRecognizer alloc] initWithTarget:self action:@selector(handlePan:)];
56 | }
57 |
58 | - (void)viewDidLoad {
59 | [[NSNotificationCenter defaultCenter] addObserver:self
60 | selector:@selector(keyboardWillShow:)
61 | name:UIKeyboardWillShowNotification
62 | object:nil];
63 | [[NSNotificationCenter defaultCenter] addObserver:self
64 | selector:@selector(keyboardWillHide:)
65 | name:UIKeyboardWillHideNotification
66 | object:nil];
67 | [UIApplication.sharedApplication sendAction:@selector(resignFirstResponder) to:nil from:nil forEvent:nil];
68 | }
69 |
70 | - (void)loadValues {
71 | self.pipEdgeInsets = [self pictureInPictureEdgeInsets];
72 | self.pipSize = [self pictureInPictureSize];
73 | self.fullScreenSize = [UIScreen mainScreen].bounds.size;
74 | self.fullScreenCenter = CGPointMake(self.fullScreenSize.width / 2, self.fullScreenSize.height / 2);
75 | if (self.isPictureInPictureActive) {
76 | self.pipCenter = [self validCenterPoint:self.pipCenter withSize:self.pipSize];
77 | } else {
78 | [self setPIPCenterWithVerticalPosition:bottom horizontalPosition:right];
79 | }
80 | }
81 |
82 | - (void)dealloc {
83 | [[NSNotificationCenter defaultCenter] removeObserver:self];
84 | }
85 |
86 | #pragma mark Setter
87 |
88 | - (void)setPipCenter:(CGPoint)pipCenter {
89 | _pipCenter = pipCenter;
90 | if (self.isPictureInPictureActive) {
91 | self.view.center = pipCenter;
92 | }
93 | }
94 |
95 |
96 | #pragma mark Public Methods
97 |
98 | - (void)reloadPictureInPicture {
99 | NVAssertMainThread;
100 | [self resetPanGesture];
101 | [self loadValues];
102 | [self validateUIForCurrentStateAnimated:YES];
103 | }
104 |
105 | - (void)enablePictureInPicture {
106 | NVAssertMainThread;
107 | if (self.isPictureInPictureEnabled) {
108 | NSLog(@"[NVPictureInPicture] Warning: enablePictureInPicture called when Picture in Picture is already enabled.");
109 | return;
110 | }
111 | self.pictureInPictureEnabled = YES;
112 | [self.view addGestureRecognizer:self.panGesture];
113 | }
114 |
115 | - (void)disablePictureInPicture {
116 | NVAssertMainThread;
117 | if (!self.isPictureInPictureEnabled) {
118 | NSLog(@"[NVPictureInPicture] Warning: disablePictureInPicture called when Picture in Picture is already disabled.");
119 | return;
120 | }
121 | self.pictureInPictureEnabled = NO;
122 | [self.view removeGestureRecognizer:self.panGesture];
123 | }
124 |
125 | - (void)startPictureInPictureAnimated:(BOOL)animated {
126 | NVAssertMainThread;
127 | [self resetPanGesture];
128 | if (!self.isPictureInPictureEnabled) {
129 | NSLog(@"[NVPictureInPicture] Warning: startPictureInPicture called when Picture in Picture is disabled");
130 | [self validateUIForCurrentStateAnimated:animated];
131 | return;
132 | }
133 | if (self.isPictureInPictureActive) {
134 | NSLog(@"[NVPictureInPicture] Warning: startPictureInPicture called when view is already in picture-in-picture.");
135 | [self validateUIForCurrentStateAnimated:animated];
136 | return;
137 | }
138 | if (self.pictureInPictureDelegate != nil
139 | && [self.pictureInPictureDelegate respondsToSelector:@selector(pictureInPictureViewControllerWillStartPictureInPicture:)]) {
140 | [self.pictureInPictureDelegate pictureInPictureViewControllerWillStartPictureInPicture:self];
141 | }
142 | [self translateViewToPictureInPictureWithInitialSpeed:0.0f animated:animated];
143 | }
144 |
145 | - (void)stopPictureInPictureAnimated:(BOOL)animated {
146 | NVAssertMainThread;
147 | [self resetPanGesture];
148 | if (!self.isPictureInPictureActive) {
149 | NSLog(@"[NVPictureInPicture] stopPictureInPicture called when view is already in full-screen.");
150 | [self validateUIForCurrentStateAnimated:animated];
151 | return;
152 | }
153 | if (self.pictureInPictureDelegate != nil
154 | && [self.pictureInPictureDelegate respondsToSelector:@selector(pictureInPictureViewControllerWillStopPictureInPicture:)]) {
155 | [self.pictureInPictureDelegate pictureInPictureViewControllerWillStopPictureInPicture:self];
156 | }
157 | [self translateViewToFullScreenWithInitialSpeed:0.0f animated:animated];
158 | }
159 |
160 | #pragma mark Datasource Methods
161 |
162 | - (UIEdgeInsets)pictureInPictureEdgeInsets {
163 | if (@available(iOS 11.0, *)) {
164 | UIEdgeInsets safeAreaInsets = UIApplication.sharedApplication.keyWindow.safeAreaInsets;
165 | return UIEdgeInsetsMake(DefaultPictureInPictureEdgeInsets.top + safeAreaInsets.top,
166 | DefaultPictureInPictureEdgeInsets.left + safeAreaInsets.left,
167 | DefaultPictureInPictureEdgeInsets.bottom + safeAreaInsets.bottom,
168 | DefaultPictureInPictureEdgeInsets.right + safeAreaInsets.right);
169 | }
170 | return DefaultPictureInPictureEdgeInsets;
171 | }
172 |
173 | - (CGSize)pictureInPictureSize {
174 | return DefaultPictureInPictureSize;
175 | }
176 |
177 | #pragma mark Pan Gesture Handler
178 |
179 | - (void)handlePan:(UIPanGestureRecognizer *)gestureRecognizer {
180 | if (self.isPictureInPictureActive) {
181 | [self handlePanInPictureInPicture:gestureRecognizer];
182 | } else {
183 | [self handlePanInFullScreen:gestureRecognizer];
184 | }
185 | }
186 |
187 | - (void)handlePanInFullScreen:(UIPanGestureRecognizer *)gestureRecognizer {
188 | static NSInteger yMultiplier;
189 | static NSInteger xMultiplier;
190 | if (gestureRecognizer.state == UIGestureRecognizerStateBegan) {
191 | [self.panGesture setTranslation:CGPointZero inView:self.view];
192 | yMultiplier = 0;
193 | xMultiplier = 0;
194 | self.recognizingGesture = YES;
195 | if (self.pictureInPictureDelegate != nil
196 | && [self.pictureInPictureDelegate respondsToSelector:@selector(pictureInPictureViewControllerWillStartPictureInPicture:)]) {
197 | [self.pictureInPictureDelegate pictureInPictureViewControllerWillStartPictureInPicture:self];
198 | }
199 | } else {
200 | CGPoint translation = [gestureRecognizer translationInView:self.view];
201 | if (yMultiplier == 0 && translation.y != 0) {
202 | yMultiplier = translation.y / fabs(translation.y);
203 | xMultiplier = (translation.x == 0
204 | ? yMultiplier
205 | : (translation.x / fabs(translation.x)));
206 | [self setPIPCenterWithVerticalPosition:yMultiplier
207 | horizontalPosition:xMultiplier];
208 | }
209 | CGFloat percentage = fmax(0.0,
210 | PanSensitivity * yMultiplier * (translation.y / (self.fullScreenSize.height - self.pipSize.height)));
211 | if (gestureRecognizer.state == UIGestureRecognizerStateChanged) {
212 | if (percentage < 1.0) {
213 | [self updateViewWithTranslationPercentage:percentage];
214 | } else {
215 | [self updateViewWithTranslationPercentage:1.0];
216 | }
217 | } else if (gestureRecognizer.state == UIGestureRecognizerStateEnded
218 | || gestureRecognizer.state == UIGestureRecognizerStateCancelled
219 | || gestureRecognizer.state == UIGestureRecognizerStateFailed) {
220 | if (self.isRecognizingGesture) {
221 | self.recognizingGesture = NO;
222 | CGFloat velocity = yMultiplier * [gestureRecognizer velocityInView:self.view].y;
223 | [self setDisplayModeWithTranslationPercentage:percentage velocity:velocity];
224 | }
225 | }
226 | }
227 | }
228 |
229 | - (void)handlePanInPictureInPicture:(UIPanGestureRecognizer *)gestureRecognizer {
230 | if (gestureRecognizer.state == UIGestureRecognizerStateChanged) {
231 | CGPoint translation = [gestureRecognizer translationInView:self.view];
232 | [self.panGesture setTranslation:CGPointZero inView:self.view];
233 | self.recognizingGesture = YES;
234 | CGPoint center = self.view.center;
235 | center.x += translation.x;
236 | center.y += translation.y;
237 | self.pipCenter = center;
238 | } else if (gestureRecognizer.state == UIGestureRecognizerStateEnded
239 | || gestureRecognizer.state == UIGestureRecognizerStateCancelled
240 | || gestureRecognizer.state == UIGestureRecognizerStateFailed) {
241 | if (self.isRecognizingGesture) {
242 | self.noInteractionFlag = NO;
243 | self.recognizingGesture = NO;
244 | CGPoint velocity = [gestureRecognizer velocityInView:self.view];
245 | CGFloat speed = fabs(velocity.y / (self.fullScreenSize.height - self.pipSize.height));
246 | [self animateViewAnimated:YES
247 | speed:speed
248 | animationBlock:^{
249 | CGPoint center = self.view.center;
250 | center.x += velocity.x * FreeFlowTimeAfterPan;
251 | center.y += velocity.y * FreeFlowTimeAfterPan;
252 | self.pipCenter = [self validCenterPoint:center withSize:self.pipSize];
253 | } completionBlock:nil];
254 | }
255 | }
256 | }
257 |
258 | #pragma mark Helper Methods
259 |
260 | - (void)resetPanGesture {
261 | self.recognizingGesture = NO;
262 | self.panGesture.enabled = NO;
263 | self.panGesture.enabled = YES;
264 | }
265 |
266 | - (void)validateUIForCurrentStateAnimated:(BOOL)animated {
267 | if (self.isPictureInPictureActive) {
268 | [self translateViewToPictureInPictureWithInitialSpeed:0.0f animated:animated];
269 | } else {
270 | [self translateViewToFullScreenWithInitialSpeed:0.0 animated:animated];
271 | }
272 | }
273 |
274 | - (CGFloat)normalizePercentage:(CGFloat)percentage WithVelocity:(CGFloat)velocity {
275 | return percentage + (velocity * FreeFlowTimeAfterPan) / (self.fullScreenSize.height - self.pipSize.height);
276 | }
277 |
278 | - (CGFloat)normalizeSpeedWithVelocity:(CGFloat)velocity withPercentage:(CGFloat)percentage {
279 | return fabs(velocity / (self.fullScreenSize.height - self.pipSize.height));
280 | }
281 |
282 | - (void)setDisplayModeWithTranslationPercentage:(CGFloat)percentage velocity:(CGFloat)velocity {
283 | CGFloat speed = [self normalizeSpeedWithVelocity:velocity withPercentage:percentage];
284 | CGFloat normalizePercentage = [self normalizePercentage:percentage WithVelocity:velocity];
285 | if (normalizePercentage > ThresholdTranslationPercentageForPictureInPicture) {
286 | [self translateViewToPictureInPictureWithInitialSpeed:speed animated:YES];
287 | } else {
288 | [self translateViewToFullScreenWithInitialSpeed:speed animated:YES];
289 | }
290 | }
291 |
292 | - (void)updateViewWithTranslationPercentage:(CGFloat)percentage {
293 | CGSize sizeDifference = CGSizeMake(self.fullScreenSize.width - self.pipSize.width,
294 | self.fullScreenSize.height - self.pipSize.height);
295 | CGPoint centerDifference = CGPointMake(self.fullScreenCenter.x - self.pipCenter.x,
296 | self.fullScreenCenter.y - self.pipCenter.y);
297 | self.view.bounds = CGRectMake(0,
298 | 0,
299 | self.fullScreenSize.width - sizeDifference.width * percentage,
300 | self.fullScreenSize.height - sizeDifference.height * percentage);
301 | self.view.center = CGPointMake(self.fullScreenCenter.x - centerDifference.x * percentage,
302 | self.fullScreenCenter.y - centerDifference.y * percentage);
303 | }
304 |
305 | - (void)stickPictureInPictureToEdge {
306 | if (!self.isPictureInPictureActive) {
307 | NSLog(@"[NVPictureInPicture] Warning: stickPictureInPictureToEdge called when Picture-In-Picture is inactive.");
308 | return;
309 | }
310 | [UIView animateWithDuration:AnimationDuration animations:^{
311 | self.pipCenter = [self validCenterPoint:self.view.center
312 | withSize:self.view.bounds.size];
313 | }];
314 | }
315 |
316 | - (CGPoint)validCenterPoint:(CGPoint)point
317 | withSize:(CGSize)size {
318 | CGSize screenSize = [UIScreen mainScreen].bounds.size;
319 | if (point.x < screenSize.width / 2) {
320 | point.x = self.pipEdgeInsets.left + size.width / 2;
321 | } else {
322 | point.x = screenSize.width - size.width / 2 - self.pipEdgeInsets.right;
323 | }
324 | if (point.y < self.pipEdgeInsets.top + size.height / 2) {
325 | point.y = self.pipEdgeInsets.top + size.height / 2;
326 | }else if (point.y > screenSize.height - size.height / 2 - self.pipEdgeInsets.bottom - self.keyboardHeight) {
327 | point.y = screenSize.height - size.height / 2 - self.pipEdgeInsets.bottom - self.keyboardHeight;
328 | }
329 | return point;
330 | }
331 |
332 | - (void)setPIPCenterWithVerticalPosition:(PictureInPictureVerticalPosition)verticalPosition
333 | horizontalPosition:(PictureInPictureHorizontalPosition)horizontalPosition{
334 | CGPoint center = CGPointMake(0, 0);
335 | if(verticalPosition == top) {
336 | center.y = 0 + self.pipEdgeInsets.top + self.pipSize.height / 2;
337 | } else {
338 | center.y = self.fullScreenSize.height - self.pipEdgeInsets.bottom - self.pipSize.height / 2;
339 | }
340 | if(horizontalPosition == left) {
341 | center.x = 0 + self.pipEdgeInsets.left + self.pipSize.width / 2;
342 | } else {
343 | center.x = self.fullScreenSize.width - self.pipEdgeInsets.right - self.pipSize.width / 2;
344 | }
345 | self.pipCenter = center;
346 | }
347 |
348 | #pragma mark Translation Methods
349 |
350 | - (void)translateViewToPictureInPictureWithInitialSpeed:(CGFloat)speed animated:(BOOL)animated {
351 | self.pictureInPictureActive = YES;
352 | self.view.autoresizingMask = UIViewAutoresizingNone;
353 | __weak typeof(self) weakSelf = self;
354 | void(^animationBlock)(void) = ^{
355 | [weakSelf updateViewWithTranslationPercentage:1.0f];
356 | };
357 | void(^completionBlock)(void) = ^{
358 | if (weakSelf.pictureInPictureDelegate != nil
359 | && [weakSelf.pictureInPictureDelegate respondsToSelector:@selector(pictureInPictureViewControllerDidStartPictureInPicture:)]) {
360 | [weakSelf.pictureInPictureDelegate pictureInPictureViewControllerDidStartPictureInPicture:self];
361 | }
362 | };
363 | [self animateViewAnimated:animated speed:speed animationBlock:animationBlock completionBlock:completionBlock];
364 | }
365 |
366 | - (void)translateViewToFullScreenWithInitialSpeed:(CGFloat)speed animated:(BOOL)animated {
367 | self.pictureInPictureActive = NO;
368 | [UIApplication.sharedApplication sendAction:@selector(resignFirstResponder) to:nil from:nil forEvent:nil];
369 | self.view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
370 |
371 | __weak typeof(self) weakSelf = self;
372 | void(^animationBlock)(void) = ^{
373 | [weakSelf updateViewWithTranslationPercentage:0.0f];
374 | };
375 | void(^completionBlock)(void) = ^{
376 | if (weakSelf.pictureInPictureDelegate != nil
377 | && [weakSelf.pictureInPictureDelegate respondsToSelector:@selector(pictureInPictureViewControllerDidStopPictureInPicture:)]) {
378 | [weakSelf.pictureInPictureDelegate pictureInPictureViewControllerDidStopPictureInPicture:self];
379 | }
380 | };
381 | [self animateViewAnimated:animated speed:speed animationBlock:animationBlock completionBlock:completionBlock];
382 | }
383 |
384 | - (void)animateViewAnimated:(BOOL)animated speed:(CGFloat)speed animationBlock:(void (^)(void))animationBlock completionBlock:(void (^)(void))completionBlock {
385 | if (animated) {
386 | [UIView animateWithDuration:AnimationDuration
387 | delay:0
388 | usingSpringWithDamping:AnimationDamping
389 | initialSpringVelocity:speed
390 | options:UIViewAnimationOptionLayoutSubviews | UIViewAnimationCurveEaseInOut
391 | animations:animationBlock
392 | completion:^(BOOL finished) {
393 | (finished
394 | ? (completionBlock != nil ? completionBlock() : nil)
395 | : [self validateUIForCurrentStateAnimated:animated]);
396 | }];
397 | } else {
398 | animationBlock != nil ? animationBlock() : nil;
399 | completionBlock != nil ? completionBlock() : nil;
400 | }
401 | }
402 |
403 | #pragma mark Keyboard Handler
404 |
405 | - (void)animateWithKeyboardInfoDictionary:(NSDictionary *)info animations:(void (^)(void))animations {
406 | CGFloat keyboardAnimationDuration = [[info objectForKey:UIKeyboardAnimationDurationUserInfoKey] doubleValue];
407 | NSInteger keyboardAnimationCurve = [[info objectForKey:UIKeyboardAnimationCurveUserInfoKey] integerValue];
408 | [UIView beginAnimations:nil context:NULL];
409 | [UIView setAnimationDuration:keyboardAnimationDuration];
410 | [UIView setAnimationCurve:keyboardAnimationCurve];
411 | [UIView setAnimationBeginsFromCurrentState:YES];
412 | animations();
413 | [UIView commitAnimations];
414 | }
415 |
416 | - (void)keyboardWillShow:(NSNotification *)notification {
417 | NSDictionary* info = [notification userInfo];
418 | self.keyboardHeight = [[info objectForKey:UIKeyboardFrameEndUserInfoKey] CGRectValue].size.height;
419 | if (self.isPictureInPictureActive) {
420 | self.lastPointBeforeKeyboardToggle = self.view.center;
421 | self.noInteractionFlag = YES;
422 | [self animateWithKeyboardInfoDictionary:info animations:^{
423 | self.pipCenter = [self validCenterPoint:self.view.center withSize:self.view.bounds.size];
424 | }];
425 | }
426 | }
427 |
428 | - (void)keyboardWillHide:(NSNotification *)notification {
429 | self.keyboardHeight = 0.0f;
430 | NSDictionary* info = [notification userInfo];
431 | if (self.isPictureInPictureActive && self.noInteractionFlag) {
432 | [self animateWithKeyboardInfoDictionary:info animations:^{
433 | self.pipCenter = [self validCenterPoint:self.lastPointBeforeKeyboardToggle withSize:self.view.bounds.size];
434 | }];
435 | self.noInteractionFlag = NO;
436 | }
437 | }
438 |
439 | #pragma mark Rotation Handler
440 |
441 | - (void)viewWillTransitionToSize:(CGSize)size withTransitionCoordinator:(id)coordinator {
442 | self.noInteractionFlag = NO;
443 | [coordinator animateAlongsideTransition:^(id _Nonnull context) {
444 | if (self.isPictureInPictureActive) {
445 | CGPoint originRatio = CGPointMake((self.view.frame.origin.x - self.pipEdgeInsets.left)
446 | / (self.fullScreenSize.width - self.pipSize.width - self.pipEdgeInsets.left - self.pipEdgeInsets.right),
447 | (self.view.frame.origin.y - self.pipEdgeInsets.top)
448 | / (self.fullScreenSize.height - self.pipSize.height - self.pipEdgeInsets.top - self.pipEdgeInsets.bottom));
449 | [self reloadPictureInPicture];
450 | CGPoint newCenter;
451 | newCenter.x = self.pipEdgeInsets.left + self.pipSize.width / 2 + originRatio.x * (size.width - self.pipSize.width - self.pipEdgeInsets.left - self.pipEdgeInsets.right);
452 | newCenter.y = self.pipEdgeInsets.top + self.pipSize.height / 2 + originRatio.y * (size.height - self.pipSize.height - self.pipEdgeInsets.top - self.pipEdgeInsets.bottom);
453 | self.pipCenter = [self validCenterPoint:newCenter withSize:self.view.bounds.size];
454 | }
455 | } completion:^(id _Nonnull context) {
456 | [self reloadPictureInPicture];
457 | }];
458 | }
459 |
460 | # pragma mark Presentor
461 |
462 | - (void)presentPictureInPictureViewControllerOnWindow:(UIWindow *)window animated:(BOOL)animated completion:(void (^ _Nullable)(void))completion {
463 | NVAssertMainThread;
464 | self.view.frame = CGRectMake(0,
465 | self.fullScreenSize.height,
466 | self.fullScreenSize.width,
467 | self.fullScreenSize.height);
468 | [window addSubview:self.view];
469 | void(^animationBlock)(void) = ^{
470 | self.view.frame = CGRectMake(0,
471 | 0,
472 | self.fullScreenSize.width,
473 | self.fullScreenSize.height);
474 | };
475 | void(^completionBlock)(void) = ^{
476 | [window.rootViewController addChildViewController:self];
477 | [self didMoveToParentViewController:window.rootViewController];
478 | if (completion != NULL) {
479 | completion();
480 | }
481 | };
482 | if (animated) {
483 | [UIView animateWithDuration:PresentationAnimationDuration
484 | delay:0.0f
485 | usingSpringWithDamping:AnimationDamping
486 | initialSpringVelocity:PresentationAnimationVelocity
487 | options:UIViewAnimationOptionCurveEaseIn
488 | animations:^{
489 | animationBlock();
490 | } completion:^(BOOL finished) {
491 | completionBlock();
492 | }];
493 | } else {
494 | animationBlock();
495 | completionBlock();
496 | }
497 | }
498 |
499 | - (void)dismissPictureInPictureViewControllerAnimated:(BOOL)animated completion:(void (^ __nullable)(void))completion {
500 | NVAssertMainThread;
501 | [self viewWillDisappear:YES];
502 | __weak typeof(self) weakSelf = self;
503 | void(^animationBlock)(void) = ^{
504 | self.view.frame = CGRectMake(self.view.frame.origin.x,
505 | self.fullScreenSize.height,
506 | self.view.frame.size.width,
507 | self.view.frame.size.height);
508 | };
509 | void(^completionBlock)(void) = ^{
510 | [weakSelf.view removeFromSuperview];
511 | [weakSelf viewDidDisappear:YES];
512 | [weakSelf removeFromParentViewController];
513 | if (completion != NULL) {
514 | completion();
515 | }
516 | };
517 | if (animated) {
518 | [UIView animateWithDuration:PresentationAnimationDuration
519 | delay:0.0f
520 | usingSpringWithDamping:AnimationDamping
521 | initialSpringVelocity:PresentationAnimationVelocity
522 | options:UIViewAnimationOptionCurveEaseOut
523 | animations:^{
524 | animationBlock();
525 | } completion:^(BOOL finished) {
526 | completionBlock();
527 | }];
528 | } else {
529 | animationBlock();
530 | completionBlock();
531 | }
532 | }
533 |
534 | @end
535 |
--------------------------------------------------------------------------------
/Example/Pods/Pods.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 1C1C97D806B0ACDCDC5F5885C11EEF7A /* NVPictureInPicture-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 5B842FBAF7299C305A4F041547FCCEAC /* NVPictureInPicture-dummy.m */; };
11 | 3CE2287CCC9AF5D3F883FFB8CA683E6D /* NVPictureInPictureViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = C0C4D11AF3B739E895A980D17E0453DE /* NVPictureInPictureViewController.h */; settings = {ATTRIBUTES = (Project, ); }; };
12 | 41F056FB1600923F7380B4948D14441C /* Pods-NVPictureInPicture_Tests-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 4E88ADABF79C3289FEA6A9684A3629E1 /* Pods-NVPictureInPicture_Tests-dummy.m */; };
13 | 4D1000C39A365AFEFCF4B2B4812FE98E /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; };
14 | 57EA5849B5BEEFB7F24ABD9B5886CE9C /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; };
15 | C3637D5A13EFF223725473663546EFE6 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; };
16 | CD377750A88A06C3362478C762B4DB19 /* NVPictureInPictureViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = C6395F8B786F9D0B30B39B86182192A2 /* NVPictureInPictureViewController.m */; };
17 | CEB2E93C3261F2AD4E8A3D2057AD05DA /* Pods-NVPictureInPicture_Example-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 7200BFC8FF3ED918B17FA4FF4DAC882A /* Pods-NVPictureInPicture_Example-dummy.m */; };
18 | /* End PBXBuildFile section */
19 |
20 | /* Begin PBXContainerItemProxy section */
21 | A87F09648E07F3EC6BADB2ADF6AC759B /* PBXContainerItemProxy */ = {
22 | isa = PBXContainerItemProxy;
23 | containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */;
24 | proxyType = 1;
25 | remoteGlobalIDString = 7494A1892A211CD25BD2B34A578D060E;
26 | remoteInfo = NVPictureInPicture;
27 | };
28 | /* End PBXContainerItemProxy section */
29 |
30 | /* Begin PBXFileReference section */
31 | 0C304EF8FD485E4809537D4633777074 /* Pods-NVPictureInPicture_Example-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-NVPictureInPicture_Example-resources.sh"; sourceTree = ""; };
32 | 104C729EC8A1A4B577CCCE2D5399B856 /* NVPictureInPicture-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "NVPictureInPicture-prefix.pch"; sourceTree = ""; };
33 | 334D56C9F0FBBF3799C98A9BD1CFDFD4 /* Pods-NVPictureInPicture_Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-NVPictureInPicture_Example.debug.xcconfig"; sourceTree = ""; };
34 | 34D5A8175AD009BD4EF7B0349AD0C35F /* Pods-NVPictureInPicture_Example-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-NVPictureInPicture_Example-acknowledgements.markdown"; sourceTree = ""; };
35 | 39C2F74A54A33FD36004AA88B2966135 /* NVPictureInPicture.podspec */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; lastKnownFileType = text; path = NVPictureInPicture.podspec; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.ruby; };
36 | 3F3B2023C2110CDEB742F45D345D5727 /* libPods-NVPictureInPicture_Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; name = "libPods-NVPictureInPicture_Tests.a"; path = "libPods-NVPictureInPicture_Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
37 | 45EDD9522EE3AE822E274DC0287B5A2B /* LICENSE */ = {isa = PBXFileReference; includeInIndex = 1; path = LICENSE; sourceTree = ""; };
38 | 4CD2D34E749FCBEF43A8BE8F721A3C53 /* Pods-NVPictureInPicture_Tests-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-NVPictureInPicture_Tests-frameworks.sh"; sourceTree = ""; };
39 | 4E88ADABF79C3289FEA6A9684A3629E1 /* Pods-NVPictureInPicture_Tests-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-NVPictureInPicture_Tests-dummy.m"; sourceTree = ""; };
40 | 51CD206626B5D920C7AE6B9DD9864EAF /* Pods-NVPictureInPicture_Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-NVPictureInPicture_Tests.debug.xcconfig"; sourceTree = ""; };
41 | 5AAB23B249BA7AD882BCA10EB6575DAD /* Pods-NVPictureInPicture_Tests-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-NVPictureInPicture_Tests-resources.sh"; sourceTree = ""; };
42 | 5B842FBAF7299C305A4F041547FCCEAC /* NVPictureInPicture-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "NVPictureInPicture-dummy.m"; sourceTree = ""; };
43 | 5CF429AF17A6554A6C3083EB49404A73 /* NVPictureInPicture.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = NVPictureInPicture.xcconfig; sourceTree = ""; };
44 | 5DD54B79331BFC4A48993E1AD0571464 /* Pods-NVPictureInPicture_Example-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-NVPictureInPicture_Example-acknowledgements.plist"; sourceTree = ""; };
45 | 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS10.3.sdk/System/Library/Frameworks/Foundation.framework; sourceTree = DEVELOPER_DIR; };
46 | 6CC95EA7DAFAA7F4995986CBE683755E /* Pods-NVPictureInPicture_Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-NVPictureInPicture_Tests.release.xcconfig"; sourceTree = ""; };
47 | 7200BFC8FF3ED918B17FA4FF4DAC882A /* Pods-NVPictureInPicture_Example-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-NVPictureInPicture_Example-dummy.m"; sourceTree = ""; };
48 | 73B815B919B882EF680EBB161E256774 /* libPods-NVPictureInPicture_Example.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; name = "libPods-NVPictureInPicture_Example.a"; path = "libPods-NVPictureInPicture_Example.a"; sourceTree = BUILT_PRODUCTS_DIR; };
49 | 8CC82C3A79C900ED21E97CADE722E6A1 /* README.md */ = {isa = PBXFileReference; includeInIndex = 1; path = README.md; sourceTree = ""; };
50 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; lastKnownFileType = text; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; };
51 | 9A984DE076AEE924BD33CE55081047C4 /* Pods-NVPictureInPicture_Example-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-NVPictureInPicture_Example-frameworks.sh"; sourceTree = ""; };
52 | A1C28CE8C3236CB9F7B2945EA12915F6 /* libNVPictureInPicture.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; name = libNVPictureInPicture.a; path = libNVPictureInPicture.a; sourceTree = BUILT_PRODUCTS_DIR; };
53 | A75715183DF75C4675424B6AD9F4EA05 /* Pods-NVPictureInPicture_Tests-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-NVPictureInPicture_Tests-acknowledgements.plist"; sourceTree = ""; };
54 | C0C4D11AF3B739E895A980D17E0453DE /* NVPictureInPictureViewController.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; name = NVPictureInPictureViewController.h; path = NVPictureInPicture/Classes/NVPictureInPictureViewController.h; sourceTree = ""; };
55 | C4D2AAD1551403CE6DA821D4CEB179CD /* Pods-NVPictureInPicture_Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-NVPictureInPicture_Example.release.xcconfig"; sourceTree = ""; };
56 | C6395F8B786F9D0B30B39B86182192A2 /* NVPictureInPictureViewController.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; name = NVPictureInPictureViewController.m; path = NVPictureInPicture/Classes/NVPictureInPictureViewController.m; sourceTree = ""; };
57 | F80D49804C6492735075C566B043CF58 /* Pods-NVPictureInPicture_Tests-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-NVPictureInPicture_Tests-acknowledgements.markdown"; sourceTree = ""; };
58 | /* End PBXFileReference section */
59 |
60 | /* Begin PBXFrameworksBuildPhase section */
61 | 766A601E30203E8AC474EC23BC245AE4 /* Frameworks */ = {
62 | isa = PBXFrameworksBuildPhase;
63 | buildActionMask = 2147483647;
64 | files = (
65 | C3637D5A13EFF223725473663546EFE6 /* Foundation.framework in Frameworks */,
66 | );
67 | runOnlyForDeploymentPostprocessing = 0;
68 | };
69 | 932A0207C48D819F779F8BBE964210F5 /* Frameworks */ = {
70 | isa = PBXFrameworksBuildPhase;
71 | buildActionMask = 2147483647;
72 | files = (
73 | 57EA5849B5BEEFB7F24ABD9B5886CE9C /* Foundation.framework in Frameworks */,
74 | );
75 | runOnlyForDeploymentPostprocessing = 0;
76 | };
77 | DEF09A251ECE3D7F9017E66EDE6F1860 /* Frameworks */ = {
78 | isa = PBXFrameworksBuildPhase;
79 | buildActionMask = 2147483647;
80 | files = (
81 | 4D1000C39A365AFEFCF4B2B4812FE98E /* Foundation.framework in Frameworks */,
82 | );
83 | runOnlyForDeploymentPostprocessing = 0;
84 | };
85 | /* End PBXFrameworksBuildPhase section */
86 |
87 | /* Begin PBXGroup section */
88 | 1CBB4F2EA42EE4DD6A8E04F4E69D026D /* Targets Support Files */ = {
89 | isa = PBXGroup;
90 | children = (
91 | 8E82DEF11D581FA4B0AF1C4BF02E2DB6 /* Pods-NVPictureInPicture_Example */,
92 | 4B286AAC5EA4343228F6F04513B923D2 /* Pods-NVPictureInPicture_Tests */,
93 | );
94 | name = "Targets Support Files";
95 | sourceTree = "";
96 | };
97 | 4B286AAC5EA4343228F6F04513B923D2 /* Pods-NVPictureInPicture_Tests */ = {
98 | isa = PBXGroup;
99 | children = (
100 | F80D49804C6492735075C566B043CF58 /* Pods-NVPictureInPicture_Tests-acknowledgements.markdown */,
101 | A75715183DF75C4675424B6AD9F4EA05 /* Pods-NVPictureInPicture_Tests-acknowledgements.plist */,
102 | 4E88ADABF79C3289FEA6A9684A3629E1 /* Pods-NVPictureInPicture_Tests-dummy.m */,
103 | 4CD2D34E749FCBEF43A8BE8F721A3C53 /* Pods-NVPictureInPicture_Tests-frameworks.sh */,
104 | 5AAB23B249BA7AD882BCA10EB6575DAD /* Pods-NVPictureInPicture_Tests-resources.sh */,
105 | 51CD206626B5D920C7AE6B9DD9864EAF /* Pods-NVPictureInPicture_Tests.debug.xcconfig */,
106 | 6CC95EA7DAFAA7F4995986CBE683755E /* Pods-NVPictureInPicture_Tests.release.xcconfig */,
107 | );
108 | name = "Pods-NVPictureInPicture_Tests";
109 | path = "Target Support Files/Pods-NVPictureInPicture_Tests";
110 | sourceTree = "";
111 | };
112 | 74602A9862101CF05348A58B492AF1F6 /* NVPictureInPicture */ = {
113 | isa = PBXGroup;
114 | children = (
115 | C0C4D11AF3B739E895A980D17E0453DE /* NVPictureInPictureViewController.h */,
116 | C6395F8B786F9D0B30B39B86182192A2 /* NVPictureInPictureViewController.m */,
117 | E8EEC14214E1A97CE2E815F78E8E7744 /* Pod */,
118 | E8233DABA49C830CDB9DC2B5B3BEE073 /* Support Files */,
119 | );
120 | name = NVPictureInPicture;
121 | path = ../..;
122 | sourceTree = "";
123 | };
124 | 7DB346D0F39D3F0E887471402A8071AB = {
125 | isa = PBXGroup;
126 | children = (
127 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */,
128 | 91F2DEB76AA477A693FF06D88A6B2E8F /* Development Pods */,
129 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */,
130 | A33775578F681AEDA673D1A07370CD54 /* Products */,
131 | 1CBB4F2EA42EE4DD6A8E04F4E69D026D /* Targets Support Files */,
132 | );
133 | sourceTree = "";
134 | };
135 | 8E82DEF11D581FA4B0AF1C4BF02E2DB6 /* Pods-NVPictureInPicture_Example */ = {
136 | isa = PBXGroup;
137 | children = (
138 | 34D5A8175AD009BD4EF7B0349AD0C35F /* Pods-NVPictureInPicture_Example-acknowledgements.markdown */,
139 | 5DD54B79331BFC4A48993E1AD0571464 /* Pods-NVPictureInPicture_Example-acknowledgements.plist */,
140 | 7200BFC8FF3ED918B17FA4FF4DAC882A /* Pods-NVPictureInPicture_Example-dummy.m */,
141 | 9A984DE076AEE924BD33CE55081047C4 /* Pods-NVPictureInPicture_Example-frameworks.sh */,
142 | 0C304EF8FD485E4809537D4633777074 /* Pods-NVPictureInPicture_Example-resources.sh */,
143 | 334D56C9F0FBBF3799C98A9BD1CFDFD4 /* Pods-NVPictureInPicture_Example.debug.xcconfig */,
144 | C4D2AAD1551403CE6DA821D4CEB179CD /* Pods-NVPictureInPicture_Example.release.xcconfig */,
145 | );
146 | name = "Pods-NVPictureInPicture_Example";
147 | path = "Target Support Files/Pods-NVPictureInPicture_Example";
148 | sourceTree = "";
149 | };
150 | 91F2DEB76AA477A693FF06D88A6B2E8F /* Development Pods */ = {
151 | isa = PBXGroup;
152 | children = (
153 | 74602A9862101CF05348A58B492AF1F6 /* NVPictureInPicture */,
154 | );
155 | name = "Development Pods";
156 | sourceTree = "";
157 | };
158 | A33775578F681AEDA673D1A07370CD54 /* Products */ = {
159 | isa = PBXGroup;
160 | children = (
161 | A1C28CE8C3236CB9F7B2945EA12915F6 /* libNVPictureInPicture.a */,
162 | 73B815B919B882EF680EBB161E256774 /* libPods-NVPictureInPicture_Example.a */,
163 | 3F3B2023C2110CDEB742F45D345D5727 /* libPods-NVPictureInPicture_Tests.a */,
164 | );
165 | name = Products;
166 | sourceTree = "";
167 | };
168 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */ = {
169 | isa = PBXGroup;
170 | children = (
171 | D35AF013A5F0BAD4F32504907A52519E /* iOS */,
172 | );
173 | name = Frameworks;
174 | sourceTree = "";
175 | };
176 | D35AF013A5F0BAD4F32504907A52519E /* iOS */ = {
177 | isa = PBXGroup;
178 | children = (
179 | 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */,
180 | );
181 | name = iOS;
182 | sourceTree = "";
183 | };
184 | E8233DABA49C830CDB9DC2B5B3BEE073 /* Support Files */ = {
185 | isa = PBXGroup;
186 | children = (
187 | 5CF429AF17A6554A6C3083EB49404A73 /* NVPictureInPicture.xcconfig */,
188 | 5B842FBAF7299C305A4F041547FCCEAC /* NVPictureInPicture-dummy.m */,
189 | 104C729EC8A1A4B577CCCE2D5399B856 /* NVPictureInPicture-prefix.pch */,
190 | );
191 | name = "Support Files";
192 | path = "Example/Pods/Target Support Files/NVPictureInPicture";
193 | sourceTree = "";
194 | };
195 | E8EEC14214E1A97CE2E815F78E8E7744 /* Pod */ = {
196 | isa = PBXGroup;
197 | children = (
198 | 45EDD9522EE3AE822E274DC0287B5A2B /* LICENSE */,
199 | 39C2F74A54A33FD36004AA88B2966135 /* NVPictureInPicture.podspec */,
200 | 8CC82C3A79C900ED21E97CADE722E6A1 /* README.md */,
201 | );
202 | name = Pod;
203 | sourceTree = "";
204 | };
205 | /* End PBXGroup section */
206 |
207 | /* Begin PBXHeadersBuildPhase section */
208 | 332B24D26BE185BF1E80B3EAE1448A75 /* Headers */ = {
209 | isa = PBXHeadersBuildPhase;
210 | buildActionMask = 2147483647;
211 | files = (
212 | 3CE2287CCC9AF5D3F883FFB8CA683E6D /* NVPictureInPictureViewController.h in Headers */,
213 | );
214 | runOnlyForDeploymentPostprocessing = 0;
215 | };
216 | /* End PBXHeadersBuildPhase section */
217 |
218 | /* Begin PBXNativeTarget section */
219 | 17190C6957F0F0C1B992549749C7055D /* Pods-NVPictureInPicture_Example */ = {
220 | isa = PBXNativeTarget;
221 | buildConfigurationList = BD83D450E36C7B7CB95FEAEE0F40109E /* Build configuration list for PBXNativeTarget "Pods-NVPictureInPicture_Example" */;
222 | buildPhases = (
223 | 551DD2D1C014B8B9A68D84C9ACD1CD3D /* Sources */,
224 | 932A0207C48D819F779F8BBE964210F5 /* Frameworks */,
225 | );
226 | buildRules = (
227 | );
228 | dependencies = (
229 | 7A1D310162822B5FF3E24C0AE6C0F412 /* PBXTargetDependency */,
230 | );
231 | name = "Pods-NVPictureInPicture_Example";
232 | productName = "Pods-NVPictureInPicture_Example";
233 | productReference = 73B815B919B882EF680EBB161E256774 /* libPods-NVPictureInPicture_Example.a */;
234 | productType = "com.apple.product-type.library.static";
235 | };
236 | 7494A1892A211CD25BD2B34A578D060E /* NVPictureInPicture */ = {
237 | isa = PBXNativeTarget;
238 | buildConfigurationList = A6BB2EFFB74889D751D77DA5FE19F318 /* Build configuration list for PBXNativeTarget "NVPictureInPicture" */;
239 | buildPhases = (
240 | 41FF92F18D2C8ED2FA5A088D001F1EE1 /* Sources */,
241 | DEF09A251ECE3D7F9017E66EDE6F1860 /* Frameworks */,
242 | 332B24D26BE185BF1E80B3EAE1448A75 /* Headers */,
243 | );
244 | buildRules = (
245 | );
246 | dependencies = (
247 | );
248 | name = NVPictureInPicture;
249 | productName = NVPictureInPicture;
250 | productReference = A1C28CE8C3236CB9F7B2945EA12915F6 /* libNVPictureInPicture.a */;
251 | productType = "com.apple.product-type.library.static";
252 | };
253 | B9B19DD02AB6B2617628E04A878FE086 /* Pods-NVPictureInPicture_Tests */ = {
254 | isa = PBXNativeTarget;
255 | buildConfigurationList = D137B6A2909531A92D990C0B6CA58272 /* Build configuration list for PBXNativeTarget "Pods-NVPictureInPicture_Tests" */;
256 | buildPhases = (
257 | 62B15AAEA52D670DB7EB4DB348186C09 /* Sources */,
258 | 766A601E30203E8AC474EC23BC245AE4 /* Frameworks */,
259 | );
260 | buildRules = (
261 | );
262 | dependencies = (
263 | );
264 | name = "Pods-NVPictureInPicture_Tests";
265 | productName = "Pods-NVPictureInPicture_Tests";
266 | productReference = 3F3B2023C2110CDEB742F45D345D5727 /* libPods-NVPictureInPicture_Tests.a */;
267 | productType = "com.apple.product-type.library.static";
268 | };
269 | /* End PBXNativeTarget section */
270 |
271 | /* Begin PBXProject section */
272 | D41D8CD98F00B204E9800998ECF8427E /* Project object */ = {
273 | isa = PBXProject;
274 | attributes = {
275 | LastSwiftUpdateCheck = 0930;
276 | LastUpgradeCheck = 0930;
277 | };
278 | buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */;
279 | compatibilityVersion = "Xcode 3.2";
280 | developmentRegion = English;
281 | hasScannedForEncodings = 0;
282 | knownRegions = (
283 | en,
284 | );
285 | mainGroup = 7DB346D0F39D3F0E887471402A8071AB;
286 | productRefGroup = A33775578F681AEDA673D1A07370CD54 /* Products */;
287 | projectDirPath = "";
288 | projectRoot = "";
289 | targets = (
290 | 7494A1892A211CD25BD2B34A578D060E /* NVPictureInPicture */,
291 | 17190C6957F0F0C1B992549749C7055D /* Pods-NVPictureInPicture_Example */,
292 | B9B19DD02AB6B2617628E04A878FE086 /* Pods-NVPictureInPicture_Tests */,
293 | );
294 | };
295 | /* End PBXProject section */
296 |
297 | /* Begin PBXSourcesBuildPhase section */
298 | 41FF92F18D2C8ED2FA5A088D001F1EE1 /* Sources */ = {
299 | isa = PBXSourcesBuildPhase;
300 | buildActionMask = 2147483647;
301 | files = (
302 | 1C1C97D806B0ACDCDC5F5885C11EEF7A /* NVPictureInPicture-dummy.m in Sources */,
303 | CD377750A88A06C3362478C762B4DB19 /* NVPictureInPictureViewController.m in Sources */,
304 | );
305 | runOnlyForDeploymentPostprocessing = 0;
306 | };
307 | 551DD2D1C014B8B9A68D84C9ACD1CD3D /* Sources */ = {
308 | isa = PBXSourcesBuildPhase;
309 | buildActionMask = 2147483647;
310 | files = (
311 | CEB2E93C3261F2AD4E8A3D2057AD05DA /* Pods-NVPictureInPicture_Example-dummy.m in Sources */,
312 | );
313 | runOnlyForDeploymentPostprocessing = 0;
314 | };
315 | 62B15AAEA52D670DB7EB4DB348186C09 /* Sources */ = {
316 | isa = PBXSourcesBuildPhase;
317 | buildActionMask = 2147483647;
318 | files = (
319 | 41F056FB1600923F7380B4948D14441C /* Pods-NVPictureInPicture_Tests-dummy.m in Sources */,
320 | );
321 | runOnlyForDeploymentPostprocessing = 0;
322 | };
323 | /* End PBXSourcesBuildPhase section */
324 |
325 | /* Begin PBXTargetDependency section */
326 | 7A1D310162822B5FF3E24C0AE6C0F412 /* PBXTargetDependency */ = {
327 | isa = PBXTargetDependency;
328 | name = NVPictureInPicture;
329 | target = 7494A1892A211CD25BD2B34A578D060E /* NVPictureInPicture */;
330 | targetProxy = A87F09648E07F3EC6BADB2ADF6AC759B /* PBXContainerItemProxy */;
331 | };
332 | /* End PBXTargetDependency section */
333 |
334 | /* Begin XCBuildConfiguration section */
335 | 11E13A8036263B31B5E939E22DABF526 /* Release */ = {
336 | isa = XCBuildConfiguration;
337 | baseConfigurationReference = C4D2AAD1551403CE6DA821D4CEB179CD /* Pods-NVPictureInPicture_Example.release.xcconfig */;
338 | buildSettings = {
339 | CODE_SIGN_IDENTITY = "iPhone Developer";
340 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = "";
341 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
342 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = "";
343 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
344 | MACH_O_TYPE = staticlib;
345 | OTHER_LDFLAGS = "";
346 | OTHER_LIBTOOLFLAGS = "";
347 | PODS_ROOT = "$(SRCROOT)";
348 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}";
349 | SDKROOT = iphoneos;
350 | SKIP_INSTALL = YES;
351 | TARGETED_DEVICE_FAMILY = "1,2";
352 | VALIDATE_PRODUCT = YES;
353 | };
354 | name = Release;
355 | };
356 | 26F954BA177A9A46FFFD4E23ED11D67A /* Release */ = {
357 | isa = XCBuildConfiguration;
358 | buildSettings = {
359 | ALWAYS_SEARCH_USER_PATHS = NO;
360 | CLANG_ANALYZER_NONNULL = YES;
361 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
362 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
363 | CLANG_CXX_LIBRARY = "libc++";
364 | CLANG_ENABLE_MODULES = YES;
365 | CLANG_ENABLE_OBJC_ARC = YES;
366 | CLANG_ENABLE_OBJC_WEAK = YES;
367 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
368 | CLANG_WARN_BOOL_CONVERSION = YES;
369 | CLANG_WARN_COMMA = YES;
370 | CLANG_WARN_CONSTANT_CONVERSION = YES;
371 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
372 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
373 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
374 | CLANG_WARN_EMPTY_BODY = YES;
375 | CLANG_WARN_ENUM_CONVERSION = YES;
376 | CLANG_WARN_INFINITE_RECURSION = YES;
377 | CLANG_WARN_INT_CONVERSION = YES;
378 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
379 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
380 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
381 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
382 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
383 | CLANG_WARN_STRICT_PROTOTYPES = YES;
384 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
385 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
386 | CLANG_WARN_UNREACHABLE_CODE = YES;
387 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
388 | CODE_SIGNING_REQUIRED = NO;
389 | COPY_PHASE_STRIP = NO;
390 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
391 | ENABLE_NS_ASSERTIONS = NO;
392 | ENABLE_STRICT_OBJC_MSGSEND = YES;
393 | GCC_C_LANGUAGE_STANDARD = gnu11;
394 | GCC_NO_COMMON_BLOCKS = YES;
395 | GCC_PREPROCESSOR_DEFINITIONS = (
396 | "POD_CONFIGURATION_RELEASE=1",
397 | "$(inherited)",
398 | );
399 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
400 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
401 | GCC_WARN_UNDECLARED_SELECTOR = YES;
402 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
403 | GCC_WARN_UNUSED_FUNCTION = YES;
404 | GCC_WARN_UNUSED_VARIABLE = YES;
405 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
406 | MTL_ENABLE_DEBUG_INFO = NO;
407 | PRODUCT_NAME = "$(TARGET_NAME)";
408 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/;
409 | STRIP_INSTALLED_PRODUCT = NO;
410 | SYMROOT = "${SRCROOT}/../build";
411 | };
412 | name = Release;
413 | };
414 | 40FFC9CFE35EEEC2E7C2E96029B85EA2 /* Release */ = {
415 | isa = XCBuildConfiguration;
416 | baseConfigurationReference = 5CF429AF17A6554A6C3083EB49404A73 /* NVPictureInPicture.xcconfig */;
417 | buildSettings = {
418 | CODE_SIGN_IDENTITY = "iPhone Developer";
419 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = "";
420 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
421 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = "";
422 | GCC_PREFIX_HEADER = "Target Support Files/NVPictureInPicture/NVPictureInPicture-prefix.pch";
423 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
424 | OTHER_LDFLAGS = "";
425 | OTHER_LIBTOOLFLAGS = "";
426 | PRIVATE_HEADERS_FOLDER_PATH = "";
427 | PUBLIC_HEADERS_FOLDER_PATH = "";
428 | SDKROOT = iphoneos;
429 | SKIP_INSTALL = YES;
430 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = "$(inherited) ";
431 | TARGETED_DEVICE_FAMILY = "1,2";
432 | VALIDATE_PRODUCT = YES;
433 | };
434 | name = Release;
435 | };
436 | 5F64B4A8F2FE521D34161840AD27E590 /* Debug */ = {
437 | isa = XCBuildConfiguration;
438 | baseConfigurationReference = 334D56C9F0FBBF3799C98A9BD1CFDFD4 /* Pods-NVPictureInPicture_Example.debug.xcconfig */;
439 | buildSettings = {
440 | CODE_SIGN_IDENTITY = "iPhone Developer";
441 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = "";
442 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
443 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = "";
444 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
445 | MACH_O_TYPE = staticlib;
446 | OTHER_LDFLAGS = "";
447 | OTHER_LIBTOOLFLAGS = "";
448 | PODS_ROOT = "$(SRCROOT)";
449 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}";
450 | SDKROOT = iphoneos;
451 | SKIP_INSTALL = YES;
452 | TARGETED_DEVICE_FAMILY = "1,2";
453 | };
454 | name = Debug;
455 | };
456 | 65F0A28085F6C377141E6C64BDF4531A /* Release */ = {
457 | isa = XCBuildConfiguration;
458 | baseConfigurationReference = 6CC95EA7DAFAA7F4995986CBE683755E /* Pods-NVPictureInPicture_Tests.release.xcconfig */;
459 | buildSettings = {
460 | CODE_SIGN_IDENTITY = "iPhone Developer";
461 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = "";
462 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
463 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = "";
464 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
465 | MACH_O_TYPE = staticlib;
466 | OTHER_LDFLAGS = "";
467 | OTHER_LIBTOOLFLAGS = "";
468 | PODS_ROOT = "$(SRCROOT)";
469 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}";
470 | SDKROOT = iphoneos;
471 | SKIP_INSTALL = YES;
472 | TARGETED_DEVICE_FAMILY = "1,2";
473 | VALIDATE_PRODUCT = YES;
474 | };
475 | name = Release;
476 | };
477 | C811AA7DD13B4A943475ED843E3A6D20 /* Debug */ = {
478 | isa = XCBuildConfiguration;
479 | baseConfigurationReference = 5CF429AF17A6554A6C3083EB49404A73 /* NVPictureInPicture.xcconfig */;
480 | buildSettings = {
481 | CODE_SIGN_IDENTITY = "iPhone Developer";
482 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = "";
483 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
484 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = "";
485 | GCC_PREFIX_HEADER = "Target Support Files/NVPictureInPicture/NVPictureInPicture-prefix.pch";
486 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
487 | OTHER_LDFLAGS = "";
488 | OTHER_LIBTOOLFLAGS = "";
489 | PRIVATE_HEADERS_FOLDER_PATH = "";
490 | PUBLIC_HEADERS_FOLDER_PATH = "";
491 | SDKROOT = iphoneos;
492 | SKIP_INSTALL = YES;
493 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = "$(inherited) ";
494 | TARGETED_DEVICE_FAMILY = "1,2";
495 | };
496 | name = Debug;
497 | };
498 | E2BF6D6731C31DE69900B7B24E6F0445 /* Debug */ = {
499 | isa = XCBuildConfiguration;
500 | buildSettings = {
501 | ALWAYS_SEARCH_USER_PATHS = NO;
502 | CLANG_ANALYZER_NONNULL = YES;
503 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
504 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
505 | CLANG_CXX_LIBRARY = "libc++";
506 | CLANG_ENABLE_MODULES = YES;
507 | CLANG_ENABLE_OBJC_ARC = YES;
508 | CLANG_ENABLE_OBJC_WEAK = YES;
509 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
510 | CLANG_WARN_BOOL_CONVERSION = YES;
511 | CLANG_WARN_COMMA = YES;
512 | CLANG_WARN_CONSTANT_CONVERSION = YES;
513 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
514 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
515 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
516 | CLANG_WARN_EMPTY_BODY = YES;
517 | CLANG_WARN_ENUM_CONVERSION = YES;
518 | CLANG_WARN_INFINITE_RECURSION = YES;
519 | CLANG_WARN_INT_CONVERSION = YES;
520 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
521 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
522 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
523 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
524 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
525 | CLANG_WARN_STRICT_PROTOTYPES = YES;
526 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
527 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
528 | CLANG_WARN_UNREACHABLE_CODE = YES;
529 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
530 | CODE_SIGNING_REQUIRED = NO;
531 | COPY_PHASE_STRIP = NO;
532 | DEBUG_INFORMATION_FORMAT = dwarf;
533 | ENABLE_STRICT_OBJC_MSGSEND = YES;
534 | ENABLE_TESTABILITY = YES;
535 | GCC_C_LANGUAGE_STANDARD = gnu11;
536 | GCC_DYNAMIC_NO_PIC = NO;
537 | GCC_NO_COMMON_BLOCKS = YES;
538 | GCC_OPTIMIZATION_LEVEL = 0;
539 | GCC_PREPROCESSOR_DEFINITIONS = (
540 | "POD_CONFIGURATION_DEBUG=1",
541 | "DEBUG=1",
542 | "$(inherited)",
543 | );
544 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
545 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
546 | GCC_WARN_UNDECLARED_SELECTOR = YES;
547 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
548 | GCC_WARN_UNUSED_FUNCTION = YES;
549 | GCC_WARN_UNUSED_VARIABLE = YES;
550 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
551 | MTL_ENABLE_DEBUG_INFO = YES;
552 | ONLY_ACTIVE_ARCH = YES;
553 | PRODUCT_NAME = "$(TARGET_NAME)";
554 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/;
555 | STRIP_INSTALLED_PRODUCT = NO;
556 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
557 | SYMROOT = "${SRCROOT}/../build";
558 | };
559 | name = Debug;
560 | };
561 | FC3B887491B5363F144045407E4AF115 /* Debug */ = {
562 | isa = XCBuildConfiguration;
563 | baseConfigurationReference = 51CD206626B5D920C7AE6B9DD9864EAF /* Pods-NVPictureInPicture_Tests.debug.xcconfig */;
564 | buildSettings = {
565 | CODE_SIGN_IDENTITY = "iPhone Developer";
566 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = "";
567 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
568 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = "";
569 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
570 | MACH_O_TYPE = staticlib;
571 | OTHER_LDFLAGS = "";
572 | OTHER_LIBTOOLFLAGS = "";
573 | PODS_ROOT = "$(SRCROOT)";
574 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}";
575 | SDKROOT = iphoneos;
576 | SKIP_INSTALL = YES;
577 | TARGETED_DEVICE_FAMILY = "1,2";
578 | };
579 | name = Debug;
580 | };
581 | /* End XCBuildConfiguration section */
582 |
583 | /* Begin XCConfigurationList section */
584 | 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */ = {
585 | isa = XCConfigurationList;
586 | buildConfigurations = (
587 | E2BF6D6731C31DE69900B7B24E6F0445 /* Debug */,
588 | 26F954BA177A9A46FFFD4E23ED11D67A /* Release */,
589 | );
590 | defaultConfigurationIsVisible = 0;
591 | defaultConfigurationName = Release;
592 | };
593 | A6BB2EFFB74889D751D77DA5FE19F318 /* Build configuration list for PBXNativeTarget "NVPictureInPicture" */ = {
594 | isa = XCConfigurationList;
595 | buildConfigurations = (
596 | C811AA7DD13B4A943475ED843E3A6D20 /* Debug */,
597 | 40FFC9CFE35EEEC2E7C2E96029B85EA2 /* Release */,
598 | );
599 | defaultConfigurationIsVisible = 0;
600 | defaultConfigurationName = Release;
601 | };
602 | BD83D450E36C7B7CB95FEAEE0F40109E /* Build configuration list for PBXNativeTarget "Pods-NVPictureInPicture_Example" */ = {
603 | isa = XCConfigurationList;
604 | buildConfigurations = (
605 | 5F64B4A8F2FE521D34161840AD27E590 /* Debug */,
606 | 11E13A8036263B31B5E939E22DABF526 /* Release */,
607 | );
608 | defaultConfigurationIsVisible = 0;
609 | defaultConfigurationName = Release;
610 | };
611 | D137B6A2909531A92D990C0B6CA58272 /* Build configuration list for PBXNativeTarget "Pods-NVPictureInPicture_Tests" */ = {
612 | isa = XCConfigurationList;
613 | buildConfigurations = (
614 | FC3B887491B5363F144045407E4AF115 /* Debug */,
615 | 65F0A28085F6C377141E6C64BDF4531A /* Release */,
616 | );
617 | defaultConfigurationIsVisible = 0;
618 | defaultConfigurationName = Release;
619 | };
620 | /* End XCConfigurationList section */
621 | };
622 | rootObject = D41D8CD98F00B204E9800998ECF8427E /* Project object */;
623 | }
624 |
--------------------------------------------------------------------------------
/Example/NVPictureInPicture.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 0A2E3CE2209B054C0012F89F /* NVPIPSubViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 0A2E3CE1209B054C0012F89F /* NVPIPSubViewController.m */; };
11 | 0CB681C1EBD7F44070421F31 /* libPods-NVPictureInPicture_Example.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BFC8F793C22115012893653B /* libPods-NVPictureInPicture_Example.a */; };
12 | 6003F58E195388D20070C39A /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F58D195388D20070C39A /* Foundation.framework */; };
13 | 6003F590195388D20070C39A /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F58F195388D20070C39A /* CoreGraphics.framework */; };
14 | 6003F592195388D20070C39A /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F591195388D20070C39A /* UIKit.framework */; };
15 | 6003F598195388D20070C39A /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 6003F596195388D20070C39A /* InfoPlist.strings */; };
16 | 6003F59A195388D20070C39A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 6003F599195388D20070C39A /* main.m */; };
17 | 6003F59E195388D20070C39A /* NVPIPAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 6003F59D195388D20070C39A /* NVPIPAppDelegate.m */; };
18 | 6003F5A7195388D20070C39A /* NVRootViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 6003F5A6195388D20070C39A /* NVRootViewController.m */; };
19 | 6003F5A9195388D20070C39A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 6003F5A8195388D20070C39A /* Images.xcassets */; };
20 | 6003F5B0195388D20070C39A /* XCTest.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F5AF195388D20070C39A /* XCTest.framework */; };
21 | 6003F5B1195388D20070C39A /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F58D195388D20070C39A /* Foundation.framework */; };
22 | 6003F5B2195388D20070C39A /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6003F591195388D20070C39A /* UIKit.framework */; };
23 | 6003F5BA195388D20070C39A /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 6003F5B8195388D20070C39A /* InfoPlist.strings */; };
24 | 6003F5BC195388D20070C39A /* Tests.m in Sources */ = {isa = PBXBuildFile; fileRef = 6003F5BB195388D20070C39A /* Tests.m */; };
25 | 71719F9F1E33DC2100824A3D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 71719F9D1E33DC2100824A3D /* LaunchScreen.storyboard */; };
26 | 873B8AEB1B1F5CCA007FD442 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 873B8AEA1B1F5CCA007FD442 /* Main.storyboard */; };
27 | A6B3452C216718203727E4AA /* libPods-NVPictureInPicture_Tests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 99AD241038C25B7F0DF46AD1 /* libPods-NVPictureInPicture_Tests.a */; };
28 | /* End PBXBuildFile section */
29 |
30 | /* Begin PBXContainerItemProxy section */
31 | 6003F5B3195388D20070C39A /* PBXContainerItemProxy */ = {
32 | isa = PBXContainerItemProxy;
33 | containerPortal = 6003F582195388D10070C39A /* Project object */;
34 | proxyType = 1;
35 | remoteGlobalIDString = 6003F589195388D20070C39A;
36 | remoteInfo = NVPictureInPicture;
37 | };
38 | /* End PBXContainerItemProxy section */
39 |
40 | /* Begin PBXFileReference section */
41 | 0A2E3CDE209AEDD00012F89F /* NVPictureInPicture.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = NVPictureInPicture.framework; sourceTree = BUILT_PRODUCTS_DIR; };
42 | 0A2E3CE0209B054C0012F89F /* NVPIPSubViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = NVPIPSubViewController.h; sourceTree = ""; };
43 | 0A2E3CE1209B054C0012F89F /* NVPIPSubViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = NVPIPSubViewController.m; sourceTree = ""; };
44 | 200ADAF86B4508A2C0BE30F8 /* README.md */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = net.daringfireball.markdown; name = README.md; path = ../README.md; sourceTree = ""; };
45 | 2B863DE4C7F683959599624D /* Pods-NVPictureInPicture_Tests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NVPictureInPicture_Tests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests.debug.xcconfig"; sourceTree = ""; };
46 | 2CCDB32DB972F6F1CA64E4CE /* Pods-NVPictureInPicture_Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NVPictureInPicture_Example.release.xcconfig"; path = "Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example.release.xcconfig"; sourceTree = ""; };
47 | 4352BC3A01429E4BE870352B /* NVPictureInPicture.podspec */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = NVPictureInPicture.podspec; path = ../NVPictureInPicture.podspec; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.ruby; };
48 | 6003F58A195388D20070C39A /* NVPictureInPicture_Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = NVPictureInPicture_Example.app; sourceTree = BUILT_PRODUCTS_DIR; };
49 | 6003F58D195388D20070C39A /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
50 | 6003F58F195388D20070C39A /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
51 | 6003F591195388D20070C39A /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
52 | 6003F595195388D20070C39A /* NVPictureInPicture-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "NVPictureInPicture-Info.plist"; sourceTree = ""; };
53 | 6003F597195388D20070C39A /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; };
54 | 6003F599195388D20070C39A /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; };
55 | 6003F59B195388D20070C39A /* NVPictureInPicture-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "NVPictureInPicture-Prefix.pch"; sourceTree = ""; };
56 | 6003F59C195388D20070C39A /* NVPIPAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = NVPIPAppDelegate.h; sourceTree = ""; };
57 | 6003F59D195388D20070C39A /* NVPIPAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = NVPIPAppDelegate.m; sourceTree = ""; };
58 | 6003F5A5195388D20070C39A /* NVRootViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = NVRootViewController.h; sourceTree = ""; };
59 | 6003F5A6195388D20070C39A /* NVRootViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = NVRootViewController.m; sourceTree = ""; };
60 | 6003F5A8195388D20070C39A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; };
61 | 6003F5AE195388D20070C39A /* NVPictureInPicture_Tests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = NVPictureInPicture_Tests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
62 | 6003F5AF195388D20070C39A /* XCTest.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = XCTest.framework; path = Library/Frameworks/XCTest.framework; sourceTree = DEVELOPER_DIR; };
63 | 6003F5B7195388D20070C39A /* Tests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "Tests-Info.plist"; sourceTree = ""; };
64 | 6003F5B9195388D20070C39A /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = ""; };
65 | 6003F5BB195388D20070C39A /* Tests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = Tests.m; sourceTree = ""; };
66 | 606FC2411953D9B200FFA9A0 /* Tests-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Tests-Prefix.pch"; sourceTree = ""; };
67 | 6828BAD10A08D07F30D614F1 /* Pods-NVPictureInPicture_Tests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NVPictureInPicture_Tests.release.xcconfig"; path = "Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests.release.xcconfig"; sourceTree = ""; };
68 | 71719F9E1E33DC2100824A3D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
69 | 873B8AEA1B1F5CCA007FD442 /* Main.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = Main.storyboard; path = Base.lproj/Main.storyboard; sourceTree = ""; };
70 | 965E2B8141704E553F1CA74C /* Pods-NVPictureInPicture_Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-NVPictureInPicture_Example.debug.xcconfig"; path = "Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example.debug.xcconfig"; sourceTree = ""; };
71 | 99AD241038C25B7F0DF46AD1 /* libPods-NVPictureInPicture_Tests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-NVPictureInPicture_Tests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
72 | A7BCE79E1DE4116CC23882A5 /* LICENSE */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; name = LICENSE; path = ../LICENSE; sourceTree = ""; };
73 | BFC8F793C22115012893653B /* libPods-NVPictureInPicture_Example.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-NVPictureInPicture_Example.a"; sourceTree = BUILT_PRODUCTS_DIR; };
74 | /* End PBXFileReference section */
75 |
76 | /* Begin PBXFrameworksBuildPhase section */
77 | 6003F587195388D20070C39A /* Frameworks */ = {
78 | isa = PBXFrameworksBuildPhase;
79 | buildActionMask = 2147483647;
80 | files = (
81 | 6003F590195388D20070C39A /* CoreGraphics.framework in Frameworks */,
82 | 6003F592195388D20070C39A /* UIKit.framework in Frameworks */,
83 | 6003F58E195388D20070C39A /* Foundation.framework in Frameworks */,
84 | 0CB681C1EBD7F44070421F31 /* libPods-NVPictureInPicture_Example.a in Frameworks */,
85 | );
86 | runOnlyForDeploymentPostprocessing = 0;
87 | };
88 | 6003F5AB195388D20070C39A /* Frameworks */ = {
89 | isa = PBXFrameworksBuildPhase;
90 | buildActionMask = 2147483647;
91 | files = (
92 | 6003F5B0195388D20070C39A /* XCTest.framework in Frameworks */,
93 | 6003F5B2195388D20070C39A /* UIKit.framework in Frameworks */,
94 | 6003F5B1195388D20070C39A /* Foundation.framework in Frameworks */,
95 | A6B3452C216718203727E4AA /* libPods-NVPictureInPicture_Tests.a in Frameworks */,
96 | );
97 | runOnlyForDeploymentPostprocessing = 0;
98 | };
99 | /* End PBXFrameworksBuildPhase section */
100 |
101 | /* Begin PBXGroup section */
102 | 1A763084AA5AB09C971CEEFB /* Pods */ = {
103 | isa = PBXGroup;
104 | children = (
105 | 965E2B8141704E553F1CA74C /* Pods-NVPictureInPicture_Example.debug.xcconfig */,
106 | 2CCDB32DB972F6F1CA64E4CE /* Pods-NVPictureInPicture_Example.release.xcconfig */,
107 | 2B863DE4C7F683959599624D /* Pods-NVPictureInPicture_Tests.debug.xcconfig */,
108 | 6828BAD10A08D07F30D614F1 /* Pods-NVPictureInPicture_Tests.release.xcconfig */,
109 | );
110 | name = Pods;
111 | sourceTree = "";
112 | };
113 | 6003F581195388D10070C39A = {
114 | isa = PBXGroup;
115 | children = (
116 | 60FF7A9C1954A5C5007DD14C /* Podspec Metadata */,
117 | 6003F593195388D20070C39A /* Example for NVPictureInPicture */,
118 | 6003F5B5195388D20070C39A /* Tests */,
119 | 6003F58C195388D20070C39A /* Frameworks */,
120 | 6003F58B195388D20070C39A /* Products */,
121 | 1A763084AA5AB09C971CEEFB /* Pods */,
122 | );
123 | sourceTree = "";
124 | };
125 | 6003F58B195388D20070C39A /* Products */ = {
126 | isa = PBXGroup;
127 | children = (
128 | 6003F58A195388D20070C39A /* NVPictureInPicture_Example.app */,
129 | 6003F5AE195388D20070C39A /* NVPictureInPicture_Tests.xctest */,
130 | );
131 | name = Products;
132 | sourceTree = "";
133 | };
134 | 6003F58C195388D20070C39A /* Frameworks */ = {
135 | isa = PBXGroup;
136 | children = (
137 | 0A2E3CDE209AEDD00012F89F /* NVPictureInPicture.framework */,
138 | 6003F58D195388D20070C39A /* Foundation.framework */,
139 | 6003F58F195388D20070C39A /* CoreGraphics.framework */,
140 | 6003F591195388D20070C39A /* UIKit.framework */,
141 | 6003F5AF195388D20070C39A /* XCTest.framework */,
142 | BFC8F793C22115012893653B /* libPods-NVPictureInPicture_Example.a */,
143 | 99AD241038C25B7F0DF46AD1 /* libPods-NVPictureInPicture_Tests.a */,
144 | );
145 | name = Frameworks;
146 | sourceTree = "";
147 | };
148 | 6003F593195388D20070C39A /* Example for NVPictureInPicture */ = {
149 | isa = PBXGroup;
150 | children = (
151 | 6003F59C195388D20070C39A /* NVPIPAppDelegate.h */,
152 | 6003F59D195388D20070C39A /* NVPIPAppDelegate.m */,
153 | 873B8AEA1B1F5CCA007FD442 /* Main.storyboard */,
154 | 6003F5A5195388D20070C39A /* NVRootViewController.h */,
155 | 6003F5A6195388D20070C39A /* NVRootViewController.m */,
156 | 71719F9D1E33DC2100824A3D /* LaunchScreen.storyboard */,
157 | 6003F5A8195388D20070C39A /* Images.xcassets */,
158 | 0A2E3CE0209B054C0012F89F /* NVPIPSubViewController.h */,
159 | 0A2E3CE1209B054C0012F89F /* NVPIPSubViewController.m */,
160 | 6003F594195388D20070C39A /* Supporting Files */,
161 | );
162 | name = "Example for NVPictureInPicture";
163 | path = NVPictureInPicture;
164 | sourceTree = "";
165 | };
166 | 6003F594195388D20070C39A /* Supporting Files */ = {
167 | isa = PBXGroup;
168 | children = (
169 | 6003F595195388D20070C39A /* NVPictureInPicture-Info.plist */,
170 | 6003F596195388D20070C39A /* InfoPlist.strings */,
171 | 6003F599195388D20070C39A /* main.m */,
172 | 6003F59B195388D20070C39A /* NVPictureInPicture-Prefix.pch */,
173 | );
174 | name = "Supporting Files";
175 | sourceTree = "";
176 | };
177 | 6003F5B5195388D20070C39A /* Tests */ = {
178 | isa = PBXGroup;
179 | children = (
180 | 6003F5BB195388D20070C39A /* Tests.m */,
181 | 6003F5B6195388D20070C39A /* Supporting Files */,
182 | );
183 | path = Tests;
184 | sourceTree = "";
185 | };
186 | 6003F5B6195388D20070C39A /* Supporting Files */ = {
187 | isa = PBXGroup;
188 | children = (
189 | 6003F5B7195388D20070C39A /* Tests-Info.plist */,
190 | 6003F5B8195388D20070C39A /* InfoPlist.strings */,
191 | 606FC2411953D9B200FFA9A0 /* Tests-Prefix.pch */,
192 | );
193 | name = "Supporting Files";
194 | sourceTree = "";
195 | };
196 | 60FF7A9C1954A5C5007DD14C /* Podspec Metadata */ = {
197 | isa = PBXGroup;
198 | children = (
199 | 4352BC3A01429E4BE870352B /* NVPictureInPicture.podspec */,
200 | 200ADAF86B4508A2C0BE30F8 /* README.md */,
201 | A7BCE79E1DE4116CC23882A5 /* LICENSE */,
202 | );
203 | name = "Podspec Metadata";
204 | sourceTree = "";
205 | };
206 | /* End PBXGroup section */
207 |
208 | /* Begin PBXNativeTarget section */
209 | 6003F589195388D20070C39A /* NVPictureInPicture_Example */ = {
210 | isa = PBXNativeTarget;
211 | buildConfigurationList = 6003F5BF195388D20070C39A /* Build configuration list for PBXNativeTarget "NVPictureInPicture_Example" */;
212 | buildPhases = (
213 | 4E383139E0A454D6AF599EA3 /* [CP] Check Pods Manifest.lock */,
214 | 6003F586195388D20070C39A /* Sources */,
215 | 6003F587195388D20070C39A /* Frameworks */,
216 | 6003F588195388D20070C39A /* Resources */,
217 | 4BEB499B300712A356A5582C /* [CP] Embed Pods Frameworks */,
218 | 3CB03E72F75D548D733F9834 /* [CP] Copy Pods Resources */,
219 | );
220 | buildRules = (
221 | );
222 | dependencies = (
223 | );
224 | name = NVPictureInPicture_Example;
225 | productName = NVPictureInPicture;
226 | productReference = 6003F58A195388D20070C39A /* NVPictureInPicture_Example.app */;
227 | productType = "com.apple.product-type.application";
228 | };
229 | 6003F5AD195388D20070C39A /* NVPictureInPicture_Tests */ = {
230 | isa = PBXNativeTarget;
231 | buildConfigurationList = 6003F5C2195388D20070C39A /* Build configuration list for PBXNativeTarget "NVPictureInPicture_Tests" */;
232 | buildPhases = (
233 | C0475DA91FA66C9195A5A330 /* [CP] Check Pods Manifest.lock */,
234 | 6003F5AA195388D20070C39A /* Sources */,
235 | 6003F5AB195388D20070C39A /* Frameworks */,
236 | 6003F5AC195388D20070C39A /* Resources */,
237 | A9C09AEDC5EA326C7A99F082 /* [CP] Embed Pods Frameworks */,
238 | D4C6100454D50A7FE89A3458 /* [CP] Copy Pods Resources */,
239 | );
240 | buildRules = (
241 | );
242 | dependencies = (
243 | 6003F5B4195388D20070C39A /* PBXTargetDependency */,
244 | );
245 | name = NVPictureInPicture_Tests;
246 | productName = NVPictureInPictureTests;
247 | productReference = 6003F5AE195388D20070C39A /* NVPictureInPicture_Tests.xctest */;
248 | productType = "com.apple.product-type.bundle.unit-test";
249 | };
250 | /* End PBXNativeTarget section */
251 |
252 | /* Begin PBXProject section */
253 | 6003F582195388D10070C39A /* Project object */ = {
254 | isa = PBXProject;
255 | attributes = {
256 | CLASSPREFIX = NVPIP;
257 | LastUpgradeCheck = 0720;
258 | ORGANIZATIONNAME = niteshvijay1995;
259 | TargetAttributes = {
260 | 6003F589195388D20070C39A = {
261 | DevelopmentTeam = B4X8EQS24E;
262 | };
263 | 6003F5AD195388D20070C39A = {
264 | TestTargetID = 6003F589195388D20070C39A;
265 | };
266 | };
267 | };
268 | buildConfigurationList = 6003F585195388D10070C39A /* Build configuration list for PBXProject "NVPictureInPicture" */;
269 | compatibilityVersion = "Xcode 3.2";
270 | developmentRegion = English;
271 | hasScannedForEncodings = 0;
272 | knownRegions = (
273 | en,
274 | Base,
275 | );
276 | mainGroup = 6003F581195388D10070C39A;
277 | productRefGroup = 6003F58B195388D20070C39A /* Products */;
278 | projectDirPath = "";
279 | projectRoot = "";
280 | targets = (
281 | 6003F589195388D20070C39A /* NVPictureInPicture_Example */,
282 | 6003F5AD195388D20070C39A /* NVPictureInPicture_Tests */,
283 | );
284 | };
285 | /* End PBXProject section */
286 |
287 | /* Begin PBXResourcesBuildPhase section */
288 | 6003F588195388D20070C39A /* Resources */ = {
289 | isa = PBXResourcesBuildPhase;
290 | buildActionMask = 2147483647;
291 | files = (
292 | 873B8AEB1B1F5CCA007FD442 /* Main.storyboard in Resources */,
293 | 71719F9F1E33DC2100824A3D /* LaunchScreen.storyboard in Resources */,
294 | 6003F5A9195388D20070C39A /* Images.xcassets in Resources */,
295 | 6003F598195388D20070C39A /* InfoPlist.strings in Resources */,
296 | );
297 | runOnlyForDeploymentPostprocessing = 0;
298 | };
299 | 6003F5AC195388D20070C39A /* Resources */ = {
300 | isa = PBXResourcesBuildPhase;
301 | buildActionMask = 2147483647;
302 | files = (
303 | 6003F5BA195388D20070C39A /* InfoPlist.strings in Resources */,
304 | );
305 | runOnlyForDeploymentPostprocessing = 0;
306 | };
307 | /* End PBXResourcesBuildPhase section */
308 |
309 | /* Begin PBXShellScriptBuildPhase section */
310 | 3CB03E72F75D548D733F9834 /* [CP] Copy Pods Resources */ = {
311 | isa = PBXShellScriptBuildPhase;
312 | buildActionMask = 2147483647;
313 | files = (
314 | );
315 | inputPaths = (
316 | );
317 | name = "[CP] Copy Pods Resources";
318 | outputPaths = (
319 | );
320 | runOnlyForDeploymentPostprocessing = 0;
321 | shellPath = /bin/sh;
322 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-resources.sh\"\n";
323 | showEnvVarsInLog = 0;
324 | };
325 | 4BEB499B300712A356A5582C /* [CP] Embed Pods Frameworks */ = {
326 | isa = PBXShellScriptBuildPhase;
327 | buildActionMask = 2147483647;
328 | files = (
329 | );
330 | inputPaths = (
331 | "${SRCROOT}/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-frameworks.sh",
332 | "${BUILT_PRODUCTS_DIR}/NVPictureInPicture/NVPictureInPicture.framework",
333 | );
334 | name = "[CP] Embed Pods Frameworks";
335 | outputPaths = (
336 | "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/NVPictureInPicture.framework",
337 | );
338 | runOnlyForDeploymentPostprocessing = 0;
339 | shellPath = /bin/sh;
340 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-NVPictureInPicture_Example/Pods-NVPictureInPicture_Example-frameworks.sh\"\n";
341 | showEnvVarsInLog = 0;
342 | };
343 | 4E383139E0A454D6AF599EA3 /* [CP] Check Pods Manifest.lock */ = {
344 | isa = PBXShellScriptBuildPhase;
345 | buildActionMask = 2147483647;
346 | files = (
347 | );
348 | inputPaths = (
349 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
350 | "${PODS_ROOT}/Manifest.lock",
351 | );
352 | name = "[CP] Check Pods Manifest.lock";
353 | outputPaths = (
354 | "$(DERIVED_FILE_DIR)/Pods-NVPictureInPicture_Example-checkManifestLockResult.txt",
355 | );
356 | runOnlyForDeploymentPostprocessing = 0;
357 | shellPath = /bin/sh;
358 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
359 | showEnvVarsInLog = 0;
360 | };
361 | A9C09AEDC5EA326C7A99F082 /* [CP] Embed Pods Frameworks */ = {
362 | isa = PBXShellScriptBuildPhase;
363 | buildActionMask = 2147483647;
364 | files = (
365 | );
366 | inputPaths = (
367 | );
368 | name = "[CP] Embed Pods Frameworks";
369 | outputPaths = (
370 | );
371 | runOnlyForDeploymentPostprocessing = 0;
372 | shellPath = /bin/sh;
373 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-frameworks.sh\"\n";
374 | showEnvVarsInLog = 0;
375 | };
376 | C0475DA91FA66C9195A5A330 /* [CP] Check Pods Manifest.lock */ = {
377 | isa = PBXShellScriptBuildPhase;
378 | buildActionMask = 2147483647;
379 | files = (
380 | );
381 | inputPaths = (
382 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
383 | "${PODS_ROOT}/Manifest.lock",
384 | );
385 | name = "[CP] Check Pods Manifest.lock";
386 | outputPaths = (
387 | "$(DERIVED_FILE_DIR)/Pods-NVPictureInPicture_Tests-checkManifestLockResult.txt",
388 | );
389 | runOnlyForDeploymentPostprocessing = 0;
390 | shellPath = /bin/sh;
391 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
392 | showEnvVarsInLog = 0;
393 | };
394 | D4C6100454D50A7FE89A3458 /* [CP] Copy Pods Resources */ = {
395 | isa = PBXShellScriptBuildPhase;
396 | buildActionMask = 2147483647;
397 | files = (
398 | );
399 | inputPaths = (
400 | );
401 | name = "[CP] Copy Pods Resources";
402 | outputPaths = (
403 | );
404 | runOnlyForDeploymentPostprocessing = 0;
405 | shellPath = /bin/sh;
406 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-NVPictureInPicture_Tests/Pods-NVPictureInPicture_Tests-resources.sh\"\n";
407 | showEnvVarsInLog = 0;
408 | };
409 | /* End PBXShellScriptBuildPhase section */
410 |
411 | /* Begin PBXSourcesBuildPhase section */
412 | 6003F586195388D20070C39A /* Sources */ = {
413 | isa = PBXSourcesBuildPhase;
414 | buildActionMask = 2147483647;
415 | files = (
416 | 6003F59E195388D20070C39A /* NVPIPAppDelegate.m in Sources */,
417 | 0A2E3CE2209B054C0012F89F /* NVPIPSubViewController.m in Sources */,
418 | 6003F5A7195388D20070C39A /* NVRootViewController.m in Sources */,
419 | 6003F59A195388D20070C39A /* main.m in Sources */,
420 | );
421 | runOnlyForDeploymentPostprocessing = 0;
422 | };
423 | 6003F5AA195388D20070C39A /* Sources */ = {
424 | isa = PBXSourcesBuildPhase;
425 | buildActionMask = 2147483647;
426 | files = (
427 | 6003F5BC195388D20070C39A /* Tests.m in Sources */,
428 | );
429 | runOnlyForDeploymentPostprocessing = 0;
430 | };
431 | /* End PBXSourcesBuildPhase section */
432 |
433 | /* Begin PBXTargetDependency section */
434 | 6003F5B4195388D20070C39A /* PBXTargetDependency */ = {
435 | isa = PBXTargetDependency;
436 | target = 6003F589195388D20070C39A /* NVPictureInPicture_Example */;
437 | targetProxy = 6003F5B3195388D20070C39A /* PBXContainerItemProxy */;
438 | };
439 | /* End PBXTargetDependency section */
440 |
441 | /* Begin PBXVariantGroup section */
442 | 6003F596195388D20070C39A /* InfoPlist.strings */ = {
443 | isa = PBXVariantGroup;
444 | children = (
445 | 6003F597195388D20070C39A /* en */,
446 | );
447 | name = InfoPlist.strings;
448 | sourceTree = "";
449 | };
450 | 6003F5B8195388D20070C39A /* InfoPlist.strings */ = {
451 | isa = PBXVariantGroup;
452 | children = (
453 | 6003F5B9195388D20070C39A /* en */,
454 | );
455 | name = InfoPlist.strings;
456 | sourceTree = "";
457 | };
458 | 71719F9D1E33DC2100824A3D /* LaunchScreen.storyboard */ = {
459 | isa = PBXVariantGroup;
460 | children = (
461 | 71719F9E1E33DC2100824A3D /* Base */,
462 | );
463 | name = LaunchScreen.storyboard;
464 | sourceTree = "";
465 | };
466 | /* End PBXVariantGroup section */
467 |
468 | /* Begin XCBuildConfiguration section */
469 | 6003F5BD195388D20070C39A /* Debug */ = {
470 | isa = XCBuildConfiguration;
471 | buildSettings = {
472 | ALWAYS_SEARCH_USER_PATHS = NO;
473 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
474 | CLANG_CXX_LIBRARY = "libc++";
475 | CLANG_ENABLE_MODULES = YES;
476 | CLANG_ENABLE_OBJC_ARC = YES;
477 | CLANG_WARN_BOOL_CONVERSION = YES;
478 | CLANG_WARN_CONSTANT_CONVERSION = YES;
479 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
480 | CLANG_WARN_EMPTY_BODY = YES;
481 | CLANG_WARN_ENUM_CONVERSION = YES;
482 | CLANG_WARN_INT_CONVERSION = YES;
483 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
484 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
485 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
486 | COPY_PHASE_STRIP = NO;
487 | ENABLE_TESTABILITY = YES;
488 | GCC_C_LANGUAGE_STANDARD = gnu99;
489 | GCC_DYNAMIC_NO_PIC = NO;
490 | GCC_OPTIMIZATION_LEVEL = 0;
491 | GCC_PREPROCESSOR_DEFINITIONS = (
492 | "DEBUG=1",
493 | "$(inherited)",
494 | );
495 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
496 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
497 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
498 | GCC_WARN_UNDECLARED_SELECTOR = YES;
499 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
500 | GCC_WARN_UNUSED_FUNCTION = YES;
501 | GCC_WARN_UNUSED_VARIABLE = YES;
502 | IPHONEOS_DEPLOYMENT_TARGET = 9.3;
503 | ONLY_ACTIVE_ARCH = YES;
504 | SDKROOT = iphoneos;
505 | TARGETED_DEVICE_FAMILY = "1,2";
506 | };
507 | name = Debug;
508 | };
509 | 6003F5BE195388D20070C39A /* Release */ = {
510 | isa = XCBuildConfiguration;
511 | buildSettings = {
512 | ALWAYS_SEARCH_USER_PATHS = NO;
513 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
514 | CLANG_CXX_LIBRARY = "libc++";
515 | CLANG_ENABLE_MODULES = YES;
516 | CLANG_ENABLE_OBJC_ARC = YES;
517 | CLANG_WARN_BOOL_CONVERSION = YES;
518 | CLANG_WARN_CONSTANT_CONVERSION = YES;
519 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
520 | CLANG_WARN_EMPTY_BODY = YES;
521 | CLANG_WARN_ENUM_CONVERSION = YES;
522 | CLANG_WARN_INT_CONVERSION = YES;
523 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
524 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
525 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
526 | COPY_PHASE_STRIP = YES;
527 | ENABLE_NS_ASSERTIONS = NO;
528 | GCC_C_LANGUAGE_STANDARD = gnu99;
529 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
530 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
531 | GCC_WARN_UNDECLARED_SELECTOR = YES;
532 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
533 | GCC_WARN_UNUSED_FUNCTION = YES;
534 | GCC_WARN_UNUSED_VARIABLE = YES;
535 | IPHONEOS_DEPLOYMENT_TARGET = 9.3;
536 | SDKROOT = iphoneos;
537 | TARGETED_DEVICE_FAMILY = "1,2";
538 | VALIDATE_PRODUCT = YES;
539 | };
540 | name = Release;
541 | };
542 | 6003F5C0195388D20070C39A /* Debug */ = {
543 | isa = XCBuildConfiguration;
544 | baseConfigurationReference = 965E2B8141704E553F1CA74C /* Pods-NVPictureInPicture_Example.debug.xcconfig */;
545 | buildSettings = {
546 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
547 | DEVELOPMENT_TEAM = B4X8EQS24E;
548 | GCC_PRECOMPILE_PREFIX_HEADER = YES;
549 | GCC_PREFIX_HEADER = "NVPictureInPicture/NVPictureInPicture-Prefix.pch";
550 | INFOPLIST_FILE = "NVPictureInPicture/NVPictureInPicture-Info.plist";
551 | MODULE_NAME = ExampleApp;
552 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.${PRODUCT_NAME:rfc1034identifier}";
553 | PRODUCT_NAME = "$(TARGET_NAME)";
554 | WRAPPER_EXTENSION = app;
555 | };
556 | name = Debug;
557 | };
558 | 6003F5C1195388D20070C39A /* Release */ = {
559 | isa = XCBuildConfiguration;
560 | baseConfigurationReference = 2CCDB32DB972F6F1CA64E4CE /* Pods-NVPictureInPicture_Example.release.xcconfig */;
561 | buildSettings = {
562 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
563 | DEVELOPMENT_TEAM = B4X8EQS24E;
564 | GCC_PRECOMPILE_PREFIX_HEADER = YES;
565 | GCC_PREFIX_HEADER = "NVPictureInPicture/NVPictureInPicture-Prefix.pch";
566 | INFOPLIST_FILE = "NVPictureInPicture/NVPictureInPicture-Info.plist";
567 | MODULE_NAME = ExampleApp;
568 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.${PRODUCT_NAME:rfc1034identifier}";
569 | PRODUCT_NAME = "$(TARGET_NAME)";
570 | WRAPPER_EXTENSION = app;
571 | };
572 | name = Release;
573 | };
574 | 6003F5C3195388D20070C39A /* Debug */ = {
575 | isa = XCBuildConfiguration;
576 | baseConfigurationReference = 2B863DE4C7F683959599624D /* Pods-NVPictureInPicture_Tests.debug.xcconfig */;
577 | buildSettings = {
578 | BUNDLE_LOADER = "$(TEST_HOST)";
579 | FRAMEWORK_SEARCH_PATHS = (
580 | "$(SDKROOT)/Developer/Library/Frameworks",
581 | "$(inherited)",
582 | "$(DEVELOPER_FRAMEWORKS_DIR)",
583 | );
584 | GCC_PRECOMPILE_PREFIX_HEADER = YES;
585 | GCC_PREFIX_HEADER = "Tests/Tests-Prefix.pch";
586 | GCC_PREPROCESSOR_DEFINITIONS = (
587 | "DEBUG=1",
588 | "$(inherited)",
589 | );
590 | INFOPLIST_FILE = "Tests/Tests-Info.plist";
591 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.${PRODUCT_NAME:rfc1034identifier}";
592 | PRODUCT_NAME = "$(TARGET_NAME)";
593 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/NVPictureInPicture_Example.app/NVPictureInPicture_Example";
594 | WRAPPER_EXTENSION = xctest;
595 | };
596 | name = Debug;
597 | };
598 | 6003F5C4195388D20070C39A /* Release */ = {
599 | isa = XCBuildConfiguration;
600 | baseConfigurationReference = 6828BAD10A08D07F30D614F1 /* Pods-NVPictureInPicture_Tests.release.xcconfig */;
601 | buildSettings = {
602 | BUNDLE_LOADER = "$(TEST_HOST)";
603 | FRAMEWORK_SEARCH_PATHS = (
604 | "$(SDKROOT)/Developer/Library/Frameworks",
605 | "$(inherited)",
606 | "$(DEVELOPER_FRAMEWORKS_DIR)",
607 | );
608 | GCC_PRECOMPILE_PREFIX_HEADER = YES;
609 | GCC_PREFIX_HEADER = "Tests/Tests-Prefix.pch";
610 | INFOPLIST_FILE = "Tests/Tests-Info.plist";
611 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.${PRODUCT_NAME:rfc1034identifier}";
612 | PRODUCT_NAME = "$(TARGET_NAME)";
613 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/NVPictureInPicture_Example.app/NVPictureInPicture_Example";
614 | WRAPPER_EXTENSION = xctest;
615 | };
616 | name = Release;
617 | };
618 | /* End XCBuildConfiguration section */
619 |
620 | /* Begin XCConfigurationList section */
621 | 6003F585195388D10070C39A /* Build configuration list for PBXProject "NVPictureInPicture" */ = {
622 | isa = XCConfigurationList;
623 | buildConfigurations = (
624 | 6003F5BD195388D20070C39A /* Debug */,
625 | 6003F5BE195388D20070C39A /* Release */,
626 | );
627 | defaultConfigurationIsVisible = 0;
628 | defaultConfigurationName = Release;
629 | };
630 | 6003F5BF195388D20070C39A /* Build configuration list for PBXNativeTarget "NVPictureInPicture_Example" */ = {
631 | isa = XCConfigurationList;
632 | buildConfigurations = (
633 | 6003F5C0195388D20070C39A /* Debug */,
634 | 6003F5C1195388D20070C39A /* Release */,
635 | );
636 | defaultConfigurationIsVisible = 0;
637 | defaultConfigurationName = Release;
638 | };
639 | 6003F5C2195388D20070C39A /* Build configuration list for PBXNativeTarget "NVPictureInPicture_Tests" */ = {
640 | isa = XCConfigurationList;
641 | buildConfigurations = (
642 | 6003F5C3195388D20070C39A /* Debug */,
643 | 6003F5C4195388D20070C39A /* Release */,
644 | );
645 | defaultConfigurationIsVisible = 0;
646 | defaultConfigurationName = Release;
647 | };
648 | /* End XCConfigurationList section */
649 | };
650 | rootObject = 6003F582195388D10070C39A /* Project object */;
651 | }
652 |
--------------------------------------------------------------------------------