├── header.png ├── screenshot-1.png ├── screenshot-2.png ├── Partita ├── Assets.xcassets │ ├── Contents.json │ └── AppIcon.appiconset │ │ ├── Icon-29.png │ │ ├── Icon-40.png │ │ ├── Icon-76.png │ │ ├── Icon-29@2x-1.png │ │ ├── Icon-29@2x.png │ │ ├── Icon-29@3x.png │ │ ├── Icon-40@2x-1.png │ │ ├── Icon-40@2x.png │ │ ├── Icon-40@3x.png │ │ ├── Icon-60@2x.png │ │ ├── Icon-60@3x.png │ │ ├── Icon-76@2x.png │ │ └── Contents.json ├── Info.plist ├── Launch Screen.storyboard ├── AppDelegate.swift ├── UIColorExtension.swift ├── TunerView.swift ├── MainViewController.swift └── InfoViewController.swift ├── Partita.xcworkspace ├── contents.xcworkspacedata └── xcshareddata │ └── Partita.xcscmblueprint ├── .gitignore ├── Podfile ├── LICENSE ├── README.md └── Partita.xcodeproj └── project.pbxproj /header.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/header.png -------------------------------------------------------------------------------- /screenshot-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/screenshot-1.png -------------------------------------------------------------------------------- /screenshot-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/screenshot-2.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-29.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-40.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-76.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-29@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-29@2x-1.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-29@2x.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-29@3x.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-40@2x-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-40@2x-1.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-40@2x.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-40@3x.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-60@2x.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-60@3x.png -------------------------------------------------------------------------------- /Partita/Assets.xcassets/AppIcon.appiconset/Icon-76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/comyar/Partita/HEAD/Partita/Assets.xcassets/AppIcon.appiconset/Icon-76@2x.png -------------------------------------------------------------------------------- /Partita.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | Pods/ 2 | Assets/ 3 | Podfile.lock 4 | .DS_Store 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 | *.moved-aside 17 | DerivedData 18 | *.hmap 19 | *.ipa 20 | *.xcuserstate 21 | Carthage/Build 22 | -------------------------------------------------------------------------------- /Podfile: -------------------------------------------------------------------------------- 1 | source 'https://github.com/CocoaPods/Specs.git' 2 | 3 | platform :ios, '9.0' 4 | inhibit_all_warnings! 5 | use_frameworks! 6 | 7 | target 'Partita' do 8 | pod 'AMWaveTransition', '~> 0.6' 9 | pod 'PodsLicenseReader', '~> 0.0.4' 10 | pod 'PermissionScope', '~> 1.0' 11 | pod 'BubbleTransition', '~> 2.0' 12 | pod 'BFPaperButton', '~> 2.0' 13 | pod 'WMGaugeView', '~> 0.0.3' 14 | pod 'TuningFork', '~> 0.2.0' 15 | end 16 | 17 | post_install do |installer| 18 | installer.pods_project.targets.each do |target| 19 | target.build_configurations.each do |config| 20 | config.build_settings['ENABLE_BITCODE'] = 'NO' 21 | end 22 | end 23 | end 24 | 25 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 Comyar Zaheri 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ![](header.png) 2 | 3 | # Overview 4 | 5 | Partita is a simple instrument tuner for iOS written in Swift, powered by [TuningFork](https://github.com/comyarzaheri/TuningFork). 6 | 7 | 8 | 9 | 10 | # Usage 11 | 12 | ###### Getting Started 13 | 14 | 1. Run the following commands in your terminal to download and setup the project: 15 | 16 | ```bash 17 | $ git clone https://github.com/comyarzaheri/Partita.git 18 | $ cd Partita 19 | $ pod install 20 | $ open . 21 | ``` 22 | 2. Open `Partita.xcworkspace` in Xcode, choose your simulator, and click run. 23 | 3. Party on, Garth. 24 | 25 | # FAQ 26 | 27 | **"Can I fork this project, make my own changes, then release it on the App Store?"** 28 | 29 | Yes! 30 | 31 | **"Can I fork this project, make none of my own changes, then release it on the App Store?"** 32 | 33 | (Less enthusiastic) Yes. 34 | 35 | **"Can I contribute/are you taking pull requests?"** 36 | 37 | Yes! If you contribute, then you agree that I can include any or all of your contributions in a release or update to the app in the App Store. 38 | 39 | # License 40 | 41 | Partita is available under the [MIT License](LICENSE). 42 | 43 | # Contributors 44 | 45 | * [@comyar](https://github.com/comyar) 46 | * [@nnarayann](https://github.com/nnarayann) 47 | 48 | 49 | -------------------------------------------------------------------------------- /Partita/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 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | Launch Screen 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | 35 | NSMicrophoneUsageDescription 36 | Partita requires microphone access for instrument tuning. 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /Partita/Launch Screen.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 | -------------------------------------------------------------------------------- /Partita/Assets.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 | "size" : "29x29", 15 | "idiom" : "iphone", 16 | "filename" : "Icon-29@2x.png", 17 | "scale" : "2x" 18 | }, 19 | { 20 | "size" : "29x29", 21 | "idiom" : "iphone", 22 | "filename" : "Icon-29@3x.png", 23 | "scale" : "3x" 24 | }, 25 | { 26 | "size" : "40x40", 27 | "idiom" : "iphone", 28 | "filename" : "Icon-40@2x.png", 29 | "scale" : "2x" 30 | }, 31 | { 32 | "size" : "40x40", 33 | "idiom" : "iphone", 34 | "filename" : "Icon-40@3x.png", 35 | "scale" : "3x" 36 | }, 37 | { 38 | "size" : "60x60", 39 | "idiom" : "iphone", 40 | "filename" : "Icon-60@2x.png", 41 | "scale" : "2x" 42 | }, 43 | { 44 | "size" : "60x60", 45 | "idiom" : "iphone", 46 | "filename" : "Icon-60@3x.png", 47 | "scale" : "3x" 48 | }, 49 | { 50 | "idiom" : "ipad", 51 | "size" : "20x20", 52 | "scale" : "1x" 53 | }, 54 | { 55 | "idiom" : "ipad", 56 | "size" : "20x20", 57 | "scale" : "2x" 58 | }, 59 | { 60 | "size" : "29x29", 61 | "idiom" : "ipad", 62 | "filename" : "Icon-29.png", 63 | "scale" : "1x" 64 | }, 65 | { 66 | "size" : "29x29", 67 | "idiom" : "ipad", 68 | "filename" : "Icon-29@2x-1.png", 69 | "scale" : "2x" 70 | }, 71 | { 72 | "size" : "40x40", 73 | "idiom" : "ipad", 74 | "filename" : "Icon-40.png", 75 | "scale" : "1x" 76 | }, 77 | { 78 | "size" : "40x40", 79 | "idiom" : "ipad", 80 | "filename" : "Icon-40@2x-1.png", 81 | "scale" : "2x" 82 | }, 83 | { 84 | "size" : "76x76", 85 | "idiom" : "ipad", 86 | "filename" : "Icon-76.png", 87 | "scale" : "1x" 88 | }, 89 | { 90 | "size" : "76x76", 91 | "idiom" : "ipad", 92 | "filename" : "Icon-76@2x.png", 93 | "scale" : "2x" 94 | }, 95 | { 96 | "idiom" : "ipad", 97 | "size" : "83.5x83.5", 98 | "scale" : "2x" 99 | } 100 | ], 101 | "info" : { 102 | "version" : 1, 103 | "author" : "xcode" 104 | } 105 | } -------------------------------------------------------------------------------- /Partita/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // Partita 4 | // 5 | // Copyright (c) 2015 Comyar Zaheri. All rights reserved. 6 | // 7 | // Permission is hereby granted, free of charge, to any person obtaining a copy 8 | // of this software and associated documentation files (the "Software"), to 9 | // deal in the Software without restriction, including without limitation the 10 | // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or 11 | // sell copies of the Software, and to permit persons to whom the Software is 12 | // furnished to do so, subject to the following conditions: 13 | // 14 | // The above copyright notice and this permission notice shall be included in 15 | // all copies or substantial portions of the Software. 16 | // 17 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 20 | // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS 23 | // IN THE SOFTWARE. 24 | // 25 | 26 | 27 | // MARK:- Imports 28 | 29 | import UIKit 30 | import AVFoundation 31 | 32 | 33 | // MARK:- AppDelegate 34 | 35 | @UIApplicationMain 36 | class AppDelegate: UIResponder, UIApplicationDelegate { 37 | 38 | // MARK: Properties 39 | 40 | var window: UIWindow? 41 | fileprivate var mainViewController: MainViewController? 42 | 43 | // MARK: UIApplicationDelegate 44 | 45 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { 46 | do { 47 | try AVAudioSession.sharedInstance().setActive(false) 48 | } catch { 49 | // TODO: ??? *shrug* 50 | print("Something is broke with AVAudioSession, yo!") 51 | } 52 | window = UIWindow(frame: UIScreen.main.bounds) 53 | window?.backgroundColor = UIColor.backgroundColor() 54 | mainViewController = MainViewController() 55 | window?.rootViewController = mainViewController 56 | window?.makeKeyAndVisible() 57 | return true 58 | } 59 | 60 | func applicationWillResignActive(_ application: UIApplication) { 61 | mainViewController?.stopTuner() 62 | } 63 | 64 | func applicationDidEnterBackground(_ application: UIApplication) { 65 | mainViewController?.stopTuner() 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /Partita/UIColorExtension.swift: -------------------------------------------------------------------------------- 1 | // 2 | // UIColorExtension.swift 3 | // Partita 4 | // 5 | // Copyright (c) 2015 Comyar Zaheri. All rights reserved. 6 | // 7 | // Permission is hereby granted, free of charge, to any person obtaining a copy 8 | // of this software and associated documentation files (the "Software"), to 9 | // deal in the Software without restriction, including without limitation the 10 | // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or 11 | // sell copies of the Software, and to permit persons to whom the Software is 12 | // furnished to do so, subject to the following conditions: 13 | // 14 | // The above copyright notice and this permission notice shall be included in 15 | // all copies or substantial portions of the Software. 16 | // 17 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 20 | // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS 23 | // IN THE SOFTWARE. 24 | // 25 | 26 | 27 | // MARK:- Imports 28 | 29 | import UIKit 30 | 31 | 32 | // MARK:- UIColor 33 | 34 | extension UIColor { 35 | 36 | class func backgroundColor() -> UIColor { 37 | return partitaLightGrayColor() 38 | } 39 | 40 | class func textColor() -> UIColor { 41 | return partitaDarkBlueColor() 42 | } 43 | 44 | class func titleColor() -> UIColor { 45 | return partitaRedColor() 46 | } 47 | 48 | class func actionButtonColor() -> UIColor { 49 | return partitaRedColor() 50 | } 51 | 52 | class func authorizedColor() -> UIColor { 53 | return partitaGreenColor() 54 | } 55 | 56 | class func unauthorizedColor() -> UIColor { 57 | return partitaRedColor() 58 | } 59 | 60 | class func infoBackgroundColor() -> UIColor { 61 | return partitaDarkBlueColor() 62 | } 63 | 64 | class func rgba(_ r: Float, _ g: Float, _ b: Float, _ a: Float) -> UIColor { 65 | return UIColor(red: CGFloat(r/255.0), green: CGFloat(g/255.0), blue: CGFloat(b/255.0), alpha: CGFloat(a)) 66 | } 67 | 68 | class func partitaGreenColor() -> UIColor { 69 | return rgba(97, 255, 104, 1.0) 70 | } 71 | 72 | class func partitaRedColor() -> UIColor { 73 | return rgba(255, 104, 97, 1.0) 74 | } 75 | 76 | class func partitaDarkBlueColor() -> UIColor { 77 | return rgba(68, 84, 105, 1.0) 78 | } 79 | 80 | class func partitaLightGrayColor() -> UIColor { 81 | return rgba(238, 238, 238, 1.0) 82 | } 83 | } 84 | -------------------------------------------------------------------------------- /Partita.xcworkspace/xcshareddata/Partita.xcscmblueprint: -------------------------------------------------------------------------------- 1 | { 2 | "DVTSourceControlWorkspaceBlueprintPrimaryRemoteRepositoryKey" : "A982776C16572600A3C3810370B9A2085426E8EC", 3 | "DVTSourceControlWorkspaceBlueprintWorkingCopyRepositoryLocationsKey" : { 4 | 5 | }, 6 | "DVTSourceControlWorkspaceBlueprintWorkingCopyStatesKey" : { 7 | "74914B9EE9EBF231E7B13EF2EEED44A03386E384" : 0, 8 | "A982776C16572600A3C3810370B9A2085426E8EC" : 0, 9 | "3F71BD4C747CA866AF046C34BD7CE42A76158BC9" : 0, 10 | "FE88E1987558047B8E6131C66EE143C683887BCF" : 9223372036854775807, 11 | "2192753D52723932CEB751B153E7D54C8953DF7B" : 0, 12 | "EA8ABE342AD5A0D6FDE4A373157E673C374A215C" : 0, 13 | "2225EB71B37609C7774278206AB6E3E6F7133EBA" : 0, 14 | "6138F21667ED3AF98430D880DCC3B3F4E84D4954" : 0 15 | }, 16 | "DVTSourceControlWorkspaceBlueprintIdentifierKey" : "AE6BAE13-BFB5-4E40-B4A9-5CE079F141AE", 17 | "DVTSourceControlWorkspaceBlueprintWorkingCopyPathsKey" : { 18 | "74914B9EE9EBF231E7B13EF2EEED44A03386E384" : "WMGaugeView\/", 19 | "A982776C16572600A3C3810370B9A2085426E8EC" : "Partita\/", 20 | "3F71BD4C747CA866AF046C34BD7CE42A76158BC9" : "Chronos-Swift\/", 21 | "FE88E1987558047B8E6131C66EE143C683887BCF" : "PodsLicenseReader\/", 22 | "2192753D52723932CEB751B153E7D54C8953DF7B" : "ios-process-button\/", 23 | "EA8ABE342AD5A0D6FDE4A373157E673C374A215C" : "Metronome\/", 24 | "2225EB71B37609C7774278206AB6E3E6F7133EBA" : "TuningFork\/", 25 | "6138F21667ED3AF98430D880DCC3B3F4E84D4954" : "LiquidLoader\/" 26 | }, 27 | "DVTSourceControlWorkspaceBlueprintNameKey" : "Partita", 28 | "DVTSourceControlWorkspaceBlueprintVersion" : 204, 29 | "DVTSourceControlWorkspaceBlueprintRelativePathToProjectKey" : "Partita.xcworkspace", 30 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoriesKey" : [ 31 | { 32 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:Viddi\/ios-process-button.git", 33 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 34 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "2192753D52723932CEB751B153E7D54C8953DF7B" 35 | }, 36 | { 37 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:comyarzaheri\/TuningFork.git", 38 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 39 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "2225EB71B37609C7774278206AB6E3E6F7133EBA" 40 | }, 41 | { 42 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:comyarzaheri\/Chronos-Swift.git", 43 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 44 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "3F71BD4C747CA866AF046C34BD7CE42A76158BC9" 45 | }, 46 | { 47 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:comyarzaheri\/LiquidLoader.git", 48 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 49 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "6138F21667ED3AF98430D880DCC3B3F4E84D4954" 50 | }, 51 | { 52 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:Will-tm\/WMGaugeView.git", 53 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 54 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "74914B9EE9EBF231E7B13EF2EEED44A03386E384" 55 | }, 56 | { 57 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:comyarzaheri\/Partita.git", 58 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 59 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "A982776C16572600A3C3810370B9A2085426E8EC" 60 | }, 61 | { 62 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:comyarzaheri\/Metronome.git", 63 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 64 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "EA8ABE342AD5A0D6FDE4A373157E673C374A215C" 65 | }, 66 | { 67 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryURLKey" : "github.com:comyarzaheri\/PodsLicenseReader.git", 68 | "DVTSourceControlWorkspaceBlueprintRemoteRepositorySystemKey" : "com.apple.dt.Xcode.sourcecontrol.Git", 69 | "DVTSourceControlWorkspaceBlueprintRemoteRepositoryIdentifierKey" : "FE88E1987558047B8E6131C66EE143C683887BCF" 70 | } 71 | ] 72 | } -------------------------------------------------------------------------------- /Partita/TunerView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // TunerView.swift 3 | // Partita 4 | // 5 | // Copyright (c) 2015 Comyar Zaheri. All rights reserved. 6 | // 7 | // Permission is hereby granted, free of charge, to any person obtaining a copy 8 | // of this software and associated documentation files (the "Software"), to 9 | // deal in the Software without restriction, including without limitation the 10 | // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or 11 | // sell copies of the Software, and to permit persons to whom the Software is 12 | // furnished to do so, subject to the following conditions: 13 | // 14 | // The above copyright notice and this permission notice shall be included in 15 | // all copies or substantial portions of the Software. 16 | // 17 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 20 | // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS 23 | // IN THE SOFTWARE. 24 | // 25 | 26 | 27 | // MARK: Imports 28 | 29 | import UIKit 30 | import WMGaugeView 31 | import BFPaperButton 32 | 33 | 34 | // MARK:- TunerView 35 | 36 | class TunerView: UIView { 37 | 38 | // MARK: Properties 39 | 40 | let pitchLabel: UILabel 41 | let gaugeView: WMGaugeView 42 | let actionButton: BFPaperButton 43 | 44 | fileprivate let titleLabel: UILabel 45 | fileprivate let pitchTitleLabel: UILabel 46 | 47 | // MARK: Creating a TunerView 48 | 49 | override init(frame: CGRect) { 50 | titleLabel = UILabel() 51 | titleLabel.font = UIFont.systemFont(ofSize: 32, weight: UIFontWeightLight) 52 | titleLabel.adjustsFontSizeToFitWidth = true 53 | titleLabel.textColor = UIColor.textColor() 54 | titleLabel.textAlignment = .center 55 | titleLabel.text = "Tuner" 56 | 57 | gaugeView = WMGaugeView() 58 | gaugeView.maxValue = 50.0 59 | gaugeView.minValue = -50.0 60 | gaugeView.needleWidth = 0.01 61 | gaugeView.needleHeight = 0.4 62 | gaugeView.scaleDivisions = 10 63 | gaugeView.scaleEndAngle = 270 64 | gaugeView.scaleStartAngle = 90 65 | gaugeView.scaleSubdivisions = 5 66 | gaugeView.showScaleShadow = false 67 | gaugeView.needleScrewRadius = 0.05 68 | gaugeView.scaleDivisionsLength = 0.05 69 | gaugeView.scaleDivisionsWidth = 0.007 70 | gaugeView.scaleSubdivisionsLength = 0.02 71 | gaugeView.scaleSubdivisionsWidth = 0.002 72 | gaugeView.backgroundColor = UIColor.clear 73 | gaugeView.needleStyle = WMGaugeViewNeedleStyleFlatThin 74 | gaugeView.needleScrewStyle = WMGaugeViewNeedleScrewStylePlain 75 | gaugeView.innerBackgroundStyle = WMGaugeViewInnerBackgroundStyleFlat 76 | gaugeView.scalesubdivisionsaligment = WMGaugeViewSubdivisionsAlignmentCenter 77 | gaugeView.scaleFont = UIFont.systemFont(ofSize: 0.05, weight: UIFontWeightUltraLight) 78 | 79 | pitchTitleLabel = UILabel() 80 | pitchTitleLabel.font = UIFont.systemFont(ofSize: 24, weight: UIFontWeightLight) 81 | pitchTitleLabel.adjustsFontSizeToFitWidth = true 82 | pitchTitleLabel.textColor = UIColor.textColor() 83 | pitchTitleLabel.textAlignment = .center 84 | pitchTitleLabel.text = "Pitch" 85 | 86 | pitchLabel = UILabel() 87 | pitchLabel.font = UIFont.systemFont(ofSize: 32, weight: UIFontWeightLight) 88 | pitchLabel.adjustsFontSizeToFitWidth = true 89 | pitchLabel.textColor = UIColor.textColor() 90 | pitchLabel.textAlignment = .center 91 | pitchLabel.text = "--" 92 | 93 | actionButton = BFPaperButton(raised: false) 94 | actionButton.setTitle("Start", for: .normal) 95 | actionButton.backgroundColor = UIColor.actionButtonColor() 96 | actionButton.setTitleColor(UIColor.white, for: .normal) 97 | actionButton.setTitleColor(UIColor(white: 1.0, alpha: 0.5), for: .highlighted) 98 | 99 | super.init(frame: frame) 100 | 101 | addSubview(titleLabel) 102 | addSubview(gaugeView) 103 | addSubview(pitchTitleLabel) 104 | addSubview(pitchLabel) 105 | addSubview(actionButton) 106 | } 107 | 108 | required init?(coder aDecoder: NSCoder) { 109 | fatalError("init(coder:) has not been implemented") 110 | } 111 | 112 | // MARK: UIView 113 | 114 | override func layoutSubviews() { 115 | super.layoutSubviews() 116 | titleLabel.frame = CGRect(x: 0.0, y: 30, width: bounds.width, height: bounds.height / 18.52) 117 | gaugeView.frame = CGRect(x: 0, y: ((bounds).height - (bounds).width) / 2.0, width: (bounds).width, height: (bounds).width) 118 | pitchTitleLabel.frame = CGRect(x: 0, y: gaugeView.frame.origin.y + 0.85 * (gaugeView.bounds).height, width: (bounds).width, height: (bounds).height / 23.82) 119 | pitchLabel.frame = CGRect(x: 0, y: pitchTitleLabel.frame.origin.y + pitchTitleLabel.frame.height, width: bounds.width, height: bounds.height / 18.52) 120 | actionButton.frame = CGRect(x: 0, y: (bounds).height - 55, width: (bounds).width, height: 55) 121 | actionButton.tapCircleDiameter = 0.75 * (bounds).width 122 | } 123 | } 124 | -------------------------------------------------------------------------------- /Partita/MainViewController.swift: -------------------------------------------------------------------------------- 1 | 2 | // 3 | // TunerViewController.swift 4 | // Partita 5 | // 6 | // Copyright (c) 2015 Comyar Zaheri. All rights reserved. 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 10 | // deal in the Software without restriction, including without limitation the 11 | // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or 12 | // sell 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 23 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS 24 | // IN THE SOFTWARE. 25 | // 26 | 27 | 28 | // MARK:- Imports 29 | 30 | import UIKit 31 | import TuningFork 32 | import BFPaperButton 33 | import PermissionScope 34 | import BubbleTransition 35 | import PodsLicenseReader 36 | 37 | 38 | // MARK:- MainViewController 39 | 40 | class MainViewController: UIViewController, UIViewControllerTransitioningDelegate, TunerDelegate { 41 | 42 | // MARK: Properties 43 | 44 | fileprivate var tuner: Tuner? 45 | fileprivate var tunerView: TunerView? 46 | fileprivate var infoButton: BFPaperButton? 47 | fileprivate var infoViewController: InfoViewController? 48 | 49 | fileprivate var running = false 50 | fileprivate let transition = BubbleTransition() 51 | fileprivate let permissions = PermissionScope() 52 | 53 | // MARK: UIViewController 54 | 55 | override func viewDidLoad() { 56 | super.viewDidLoad() 57 | 58 | permissions.addPermission(MicrophonePermission(), message: "Partita would like to use your microphone.") 59 | permissions.closeButtonTextColor = UIColor.actionButtonColor() 60 | permissions.authorizedButtonColor = UIColor.authorizedColor() 61 | permissions.unauthorizedButtonColor = UIColor.unauthorizedColor() 62 | permissions.headerLabel.textColor = UIColor.textColor() 63 | permissions.bodyLabel.textColor = UIColor.textColor() 64 | permissions.permissionLabelColor = UIColor.textColor() 65 | 66 | tunerView = TunerView(frame: view.frame) 67 | tunerView?.actionButton.addTarget(self, action: #selector(MainViewController.didTouchUpInsideButton(_:)), for: .touchUpInside) 68 | view.addSubview(tunerView!) 69 | 70 | infoButton = BFPaperButton(frame: CGRect(x: (view.bounds).width - 54, y: 30, width: 44, height: 44), raised: true) 71 | infoButton?.addTarget(self, action: #selector(MainViewController.didTouchUpInsideButton(_:)), for: .touchUpInside) 72 | infoButton?.cornerRadius = (infoButton!.bounds).width / 2.0 73 | infoButton?.setTitleColor(UIColor.white, for: .normal) 74 | infoButton?.backgroundColor = UIColor.partitaDarkBlueColor() 75 | infoButton?.setTitle("i", for: .normal) 76 | infoButton?.rippleBeyondBounds = true 77 | view.addSubview(infoButton!) 78 | 79 | tuner = Tuner() 80 | tuner?.delegate = self 81 | } 82 | 83 | // MARK: Tuner Controls 84 | 85 | func startTuner() { 86 | if !running { 87 | running = true 88 | tuner?.start() 89 | tunerView?.actionButton.setTitle("Stop", for: .normal) 90 | tunerView?.actionButton.backgroundColor = UIColor.partitaDarkBlueColor() 91 | } 92 | } 93 | 94 | func stopTuner() { 95 | if running { 96 | running = false 97 | tuner?.stop() 98 | tunerView?.gaugeView.value = 0.0 99 | tunerView?.pitchLabel.text = "--" 100 | tunerView?.actionButton.setTitle("Start", for: .normal) 101 | tunerView?.actionButton.backgroundColor = UIColor.actionButtonColor() 102 | } 103 | } 104 | 105 | // MARK: TunerDelegate 106 | 107 | func tunerDidUpdate(_ tuner: Tuner, output: TunerOutput) { 108 | if output.amplitude < 0.01 { 109 | tunerView?.gaugeView.value = 0.0 110 | tunerView?.pitchLabel.text = "--" 111 | } else { 112 | tunerView?.pitchLabel.text = output.pitch + "\(output.octave)" 113 | tunerView?.gaugeView.value = Float(output.distance) 114 | } 115 | } 116 | 117 | // MARK: UIButton 118 | 119 | func didTouchUpInsideButton(_ button: UIButton) { 120 | if button == tunerView?.actionButton { 121 | if running { 122 | stopTuner() 123 | } else { 124 | if permissions.statusMicrophone() == .authorized { 125 | self.startTuner() 126 | } else { 127 | permissions.show({ (finished, results) -> Void in 128 | let result = results.filter({ $0.type == .microphone })[0] 129 | if result.status != .authorized { 130 | self.showMicrophoneAccessAlert() 131 | } 132 | }, cancelled: { (results) -> Void in 133 | self.showMicrophoneAccessAlert() 134 | }) 135 | } 136 | } 137 | } else if button == infoButton { 138 | infoViewController = InfoViewController() 139 | infoViewController?.transitioningDelegate = self 140 | infoViewController?.modalPresentationStyle = .custom 141 | self.present(infoViewController!, animated: true, completion: nil) 142 | } 143 | } 144 | 145 | // MARK: UIViewControllerTransitioningDelegate 146 | 147 | func animationController(forPresented presented: UIViewController, presenting: UIViewController, source: UIViewController) -> UIViewControllerAnimatedTransitioning? { 148 | transition.duration = 0.3 149 | transition.transitionMode = .present 150 | transition.startingPoint = infoButton!.center 151 | transition.bubbleColor = UIColor.infoBackgroundColor() 152 | return transition 153 | } 154 | 155 | func animationController(forDismissed dismissed: UIViewController) -> UIViewControllerAnimatedTransitioning? { 156 | transition.duration = 0.3 157 | transition.transitionMode = .dismiss 158 | transition.startingPoint = infoButton!.center 159 | transition.bubbleColor = UIColor.infoBackgroundColor() 160 | return transition 161 | } 162 | 163 | override var preferredStatusBarStyle : UIStatusBarStyle { 164 | return .default 165 | } 166 | 167 | // MARK: Private 168 | 169 | fileprivate func showMicrophoneAccessAlert() { 170 | let alert = UIAlertController(title: "Microphone Access", message: "Partita requires access to your microphone; please enable access in your device's settings.", preferredStyle: .alert) 171 | alert.addAction(UIAlertAction(title: "Ok", style: .default, handler: nil)) 172 | self.present(alert, animated: true, completion: nil) 173 | } 174 | } 175 | -------------------------------------------------------------------------------- /Partita/InfoViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // InfoViewController.swift 3 | // Partita 4 | // 5 | // Copyright (c) 2015 Comyar Zaheri. All rights reserved. 6 | // 7 | // Permission is hereby granted, free of charge, to any person obtaining a copy 8 | // of this software and associated documentation files (the "Software"), to 9 | // deal in the Software without restriction, including without limitation the 10 | // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or 11 | // sell copies of the Software, and to permit persons to whom the Software is 12 | // furnished to do so, subject to the following conditions: 13 | // 14 | // The above copyright notice and this permission notice shall be included in 15 | // all copies or substantial portions of the Software. 16 | // 17 | // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 20 | // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 21 | // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 22 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS 23 | // IN THE SOFTWARE. 24 | // 25 | 26 | 27 | // MARK:- Imports 28 | 29 | import UIKit 30 | import BFPaperButton 31 | import AMWaveTransition 32 | import PodsLicenseReader 33 | 34 | 35 | // MARK:- LicenseViewController 36 | 37 | private class LicenseViewController: UIViewController { 38 | 39 | var license: License? 40 | 41 | fileprivate var textView: UITextView? 42 | 43 | override func viewDidLoad() { 44 | super.viewDidLoad() 45 | textView = UITextView(frame: CGRect(x: 0.0, y: 82.0, width: view.bounds.width, height: view.bounds.height - 82)) 46 | textView?.font = UIFont.systemFont(ofSize: 16, weight: UIFontWeightLight) 47 | textView?.textContainerInset = UIEdgeInsets(top: 0.0, left: 8.0, bottom: 8.0, right: 8.0) 48 | textView?.backgroundColor = UIColor.clear 49 | textView?.textColor = UIColor.white 50 | textView?.isSelectable = false 51 | textView?.isScrollEnabled = true 52 | textView?.showsHorizontalScrollIndicator = false 53 | textView?.showsVerticalScrollIndicator = false 54 | textView?.allowsEditingTextAttributes = false 55 | textView?.alwaysBounceHorizontal = false 56 | 57 | view.addSubview(textView!) 58 | } 59 | 60 | override func viewWillAppear(_ animated: Bool) { 61 | super.viewWillAppear(animated) 62 | if let l = license { 63 | textView?.text = l.text 64 | } 65 | textView?.contentOffset = CGPoint.zero 66 | } 67 | } 68 | 69 | 70 | // MARK:- InfoTableViewController 71 | 72 | private class InfoTableViewController: AMWaveViewController, UITableViewDelegate, UITableViewDataSource { 73 | 74 | // MARK: - InfoHeaderView 75 | 76 | fileprivate class InfoHeaderView: UITableViewHeaderFooterView { 77 | 78 | let label = UILabel() 79 | 80 | override init(reuseIdentifier: String?) { 81 | label.textColor = UIColor(white: 1.0, alpha: 0.5) 82 | label.backgroundColor = UIColor.clear 83 | super.init(reuseIdentifier: reuseIdentifier) 84 | contentView.backgroundColor = UIColor.clear 85 | addSubview(label) 86 | } 87 | 88 | required init?(coder aDecoder: NSCoder) { 89 | fatalError("init(coder:) has not been implemented") 90 | } 91 | 92 | fileprivate override func layoutSubviews() { 93 | super.layoutSubviews() 94 | label.frame = bounds 95 | } 96 | } 97 | 98 | // MARK: Properties 99 | 100 | fileprivate static let licenses = PodsLicenseReader(path: Bundle.main.path(forResource: "Pods-Partita-acknowledgements", ofType: "plist")).getLicenses() 101 | fileprivate static let licenseViewController = LicenseViewController() 102 | 103 | fileprivate let tableView = UITableView(frame: CGRect.zero, style: .grouped) 104 | 105 | // MARK: UIViewController 106 | 107 | override func viewDidLoad() { 108 | super.viewDidLoad() 109 | automaticallyAdjustsScrollViewInsets = false 110 | view.backgroundColor = UIColor.clear 111 | tableView.frame = CGRect(x: 0.0, y: 80.0, width: (view.bounds).width, height: (view.bounds).height - 80) 112 | tableView.register(InfoHeaderView.self, forHeaderFooterViewReuseIdentifier: "headerFooterView") 113 | tableView.separatorStyle = .none 114 | tableView.backgroundColor = UIColor.clear 115 | tableView.dataSource = self 116 | tableView.delegate = self 117 | view.addSubview(tableView) 118 | } 119 | 120 | // MARK: AMWaveTransion 121 | 122 | @objc override func visibleCells() -> [Any]! { 123 | var cells: [AnyObject] = tableView.visibleCells 124 | if let header = tableView.headerView(forSection: 0) { 125 | cells.insert(header, at: 0) 126 | } 127 | if let header = tableView.headerView(forSection: 1) { 128 | cells.insert(header, at: 2) 129 | } 130 | return cells 131 | } 132 | 133 | // MARK: UITableViewDataSource 134 | 135 | @objc func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { 136 | var cell: UITableViewCell? = nil 137 | if indexPath.section == 0 { 138 | cell = tableView.dequeueReusableCell(withIdentifier: "creditCell") 139 | if cell == nil { 140 | cell = UITableViewCell(style: .default, reuseIdentifier: "creditCell") 141 | cell?.textLabel?.textColor = UIColor.white 142 | cell?.backgroundColor = UIColor.clear 143 | cell?.textLabel?.text = "Created by Comyar Zaheri" 144 | cell?.selectionStyle = .none 145 | } 146 | } else { 147 | cell = tableView.dequeueReusableCell(withIdentifier: "licenseCell") 148 | if cell == nil { 149 | cell = UITableViewCell(style: .default, reuseIdentifier: "licenseCell") 150 | cell?.textLabel?.textColor = UIColor.white 151 | cell?.backgroundColor = UIColor.clear 152 | cell?.accessoryType = .disclosureIndicator 153 | } 154 | let license = InfoTableViewController.licenses[indexPath.row] 155 | cell?.textLabel?.text = license.name 156 | } 157 | return cell! 158 | } 159 | 160 | @objc func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat { 161 | return 50.0 162 | } 163 | 164 | @objc func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat { 165 | return 50.0 166 | } 167 | 168 | @objc func numberOfSections(in tableView: UITableView) -> Int { 169 | return 2 170 | } 171 | 172 | @objc func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { 173 | return section == 0 ? 1 : InfoTableViewController.licenses.count 174 | } 175 | 176 | // MARK: UITableViewDelegate 177 | 178 | @objc func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) { 179 | if indexPath.section > 0 { 180 | if let cell = tableView.cellForRow(at: indexPath) { 181 | cell.setSelected(false, animated: true) 182 | InfoTableViewController.licenseViewController.license = InfoTableViewController.licenses[indexPath.row] 183 | self.navigationController?.pushViewController(InfoTableViewController.licenseViewController, animated: true) 184 | } 185 | } 186 | } 187 | 188 | @objc func tableView(_ tableView: UITableView, didUnhighlightRowAt indexPath: IndexPath) { 189 | if indexPath.section > 0 { 190 | if let cell = tableView.cellForRow(at: indexPath) { 191 | cell.setSelected(false, animated: true) 192 | } 193 | } 194 | } 195 | 196 | @objc func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView? { 197 | var header = tableView.dequeueReusableHeaderFooterView(withIdentifier: "infoHeaderView") 198 | if header == nil { 199 | header = InfoHeaderView(reuseIdentifier: "infoHeaderView") 200 | (header as! InfoHeaderView).label.text = section == 0 ? " CREDITS" : " LICENSES" 201 | } 202 | return header 203 | } 204 | } 205 | 206 | 207 | // MARK:- InfoViewController 208 | 209 | class InfoViewController: UIViewController { 210 | 211 | // MARK: Properties 212 | 213 | fileprivate let closeButton: BFPaperButton 214 | fileprivate let infoTableViewController: InfoTableViewController 215 | fileprivate let navigationViewController: UINavigationController 216 | 217 | // MARK: Creating an InfoViewController 218 | 219 | override init(nibName nibNameOrNil: String?, bundle nibBundleOrNil: Bundle?) { 220 | closeButton = BFPaperButton(raised: true) 221 | infoTableViewController = InfoTableViewController() 222 | navigationViewController = UINavigationController(rootViewController: infoTableViewController) 223 | super.init(nibName: nibNameOrNil, bundle: nibBundleOrNil) 224 | } 225 | 226 | required init?(coder aDecoder: NSCoder) { 227 | fatalError("init(coder:) has not been implemented") 228 | } 229 | 230 | // MARK: UIViewController 231 | 232 | override func viewDidLoad() { 233 | super.viewDidLoad() 234 | navigationViewController.navigationBar.titleTextAttributes = [NSFontAttributeName: UIFont.systemFont(ofSize: 32.0, weight: UIFontWeightLight), NSForegroundColorAttributeName: UIColor.white] 235 | navigationViewController.navigationBar.setBackgroundImage(UIImage(), for: .default) 236 | navigationViewController.navigationBar.tintColor = UIColor.white 237 | navigationViewController.navigationBar.backgroundColor = UIColor.clear 238 | navigationViewController.automaticallyAdjustsScrollViewInsets = false 239 | navigationViewController.view.backgroundColor = UIColor.clear 240 | navigationViewController.navigationBar.shadowImage = UIImage() 241 | navigationViewController.navigationBar.isTranslucent = true 242 | addChildViewController(navigationViewController) 243 | view.addSubview(navigationViewController.view) 244 | 245 | closeButton.frame = CGRect(x: (view.bounds).width - 54, y: 30, width: 44, height: 44) 246 | closeButton.addTarget(self, action: #selector(InfoViewController.didTouchUpInsideButton(_:)), for: .touchUpInside) 247 | closeButton.cornerRadius = (closeButton.bounds).width / 2.0 248 | closeButton.setTitleColor(UIColor.textColor(), for: .normal) 249 | closeButton.backgroundColor = UIColor.white 250 | closeButton.setTitle("X", for: .normal) 251 | closeButton.rippleBeyondBounds = true 252 | view.addSubview(closeButton) 253 | 254 | let navigationLineView = UIView(frame: CGRect(x: 0.0, y: 80.0, width: view.bounds.width, height: 0.5)) 255 | navigationLineView.backgroundColor = UIColor(white: 1.0, alpha: 0.75) 256 | view.addSubview(navigationLineView) 257 | } 258 | 259 | override var preferredStatusBarStyle : UIStatusBarStyle { 260 | return .lightContent 261 | } 262 | 263 | // MARK: UIButton 264 | 265 | func didTouchUpInsideButton(_ button: UIButton) { 266 | if (button == closeButton) { 267 | dismiss(animated: true, completion: nil) 268 | } 269 | } 270 | } 271 | -------------------------------------------------------------------------------- /Partita.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 767A609EFDD30B528B7D2099 /* Pods_Partita.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = CDA06606BF7D7AC02AA1DABE /* Pods_Partita.framework */; }; 11 | DD28D2A11BD3BD1E00A96149 /* InfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD28D2A01BD3BD1E00A96149 /* InfoViewController.swift */; }; 12 | DD28EAFE1BD0C58000DA041C /* UIColorExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD28EAFD1BD0C58000DA041C /* UIColorExtension.swift */; }; 13 | DD355BE21BC783810044C19E /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD355BE11BC783810044C19E /* AppDelegate.swift */; }; 14 | DD355BE41BC783810044C19E /* MainViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD355BE31BC783810044C19E /* MainViewController.swift */; }; 15 | DD355BE91BC783810044C19E /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = DD355BE81BC783810044C19E /* Assets.xcassets */; }; 16 | DD84F8F71BD353060021186E /* Launch Screen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = DD84F8F61BD353060021186E /* Launch Screen.storyboard */; }; 17 | DD84F8FF1BD386FD0021186E /* TunerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = DD84F8FE1BD386FD0021186E /* TunerView.swift */; }; 18 | DD8544551DD90EA800043114 /* Pods-Partita-acknowledgements.plist in Resources */ = {isa = PBXBuildFile; fileRef = DD8544541DD90EA800043114 /* Pods-Partita-acknowledgements.plist */; }; 19 | /* End PBXBuildFile section */ 20 | 21 | /* Begin PBXFileReference section */ 22 | 1C6A156C1A57D46CEA06B837 /* Pods-Partita.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Partita.release.xcconfig"; path = "Pods/Target Support Files/Pods-Partita/Pods-Partita.release.xcconfig"; sourceTree = ""; }; 23 | 20BE7C56084CD9E5016CDB66 /* Pods-Partita.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Partita.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Partita/Pods-Partita.debug.xcconfig"; sourceTree = ""; }; 24 | CDA06606BF7D7AC02AA1DABE /* Pods_Partita.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Partita.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 25 | CFE4E490E1BDCF825B7A8050 /* Pods.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 26 | DD28D2A01BD3BD1E00A96149 /* InfoViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = InfoViewController.swift; sourceTree = ""; }; 27 | DD28EAFD1BD0C58000DA041C /* UIColorExtension.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIColorExtension.swift; sourceTree = ""; }; 28 | DD355BDE1BC783810044C19E /* Partita.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Partita.app; sourceTree = BUILT_PRODUCTS_DIR; }; 29 | DD355BE11BC783810044C19E /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 30 | DD355BE31BC783810044C19E /* MainViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MainViewController.swift; sourceTree = ""; }; 31 | DD355BE81BC783810044C19E /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 32 | DD355BED1BC783810044C19E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 33 | DD355C171BC796990044C19E /* MetalPerformanceShaders.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MetalPerformanceShaders.framework; path = System/Library/Frameworks/MetalPerformanceShaders.framework; sourceTree = SDKROOT; }; 34 | DD355C1F1BC7974C0044C19E /* Metal.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Metal.framework; path = System/Library/Frameworks/Metal.framework; sourceTree = SDKROOT; }; 35 | DD355C201BC7974C0044C19E /* MetalKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MetalKit.framework; path = System/Library/Frameworks/MetalKit.framework; sourceTree = SDKROOT; }; 36 | DD84F8F61BD353060021186E /* Launch Screen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = "Launch Screen.storyboard"; sourceTree = ""; }; 37 | DD84F8FE1BD386FD0021186E /* TunerView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TunerView.swift; sourceTree = ""; }; 38 | DD8544541DD90EA800043114 /* Pods-Partita-acknowledgements.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = "Pods-Partita-acknowledgements.plist"; path = "../Pods/Target Support Files/Pods-Partita/Pods-Partita-acknowledgements.plist"; sourceTree = ""; }; 39 | DDF8193E1BD47156002D7C20 /* Pods-acknowledgements.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "Pods-acknowledgements.plist"; path = "../Pods/Target Support Files/Pods/Pods-acknowledgements.plist"; sourceTree = ""; }; 40 | /* End PBXFileReference section */ 41 | 42 | /* Begin PBXFrameworksBuildPhase section */ 43 | DD355BDB1BC783810044C19E /* Frameworks */ = { 44 | isa = PBXFrameworksBuildPhase; 45 | buildActionMask = 2147483647; 46 | files = ( 47 | 767A609EFDD30B528B7D2099 /* Pods_Partita.framework in Frameworks */, 48 | ); 49 | runOnlyForDeploymentPostprocessing = 0; 50 | }; 51 | /* End PBXFrameworksBuildPhase section */ 52 | 53 | /* Begin PBXGroup section */ 54 | 5FD764D94FF8C90715C92547 /* Frameworks */ = { 55 | isa = PBXGroup; 56 | children = ( 57 | DD355C1F1BC7974C0044C19E /* Metal.framework */, 58 | DD355C201BC7974C0044C19E /* MetalKit.framework */, 59 | DD355C171BC796990044C19E /* MetalPerformanceShaders.framework */, 60 | CFE4E490E1BDCF825B7A8050 /* Pods.framework */, 61 | CDA06606BF7D7AC02AA1DABE /* Pods_Partita.framework */, 62 | ); 63 | name = Frameworks; 64 | sourceTree = ""; 65 | }; 66 | C946D45462A5562FF071BB92 /* Pods */ = { 67 | isa = PBXGroup; 68 | children = ( 69 | 20BE7C56084CD9E5016CDB66 /* Pods-Partita.debug.xcconfig */, 70 | 1C6A156C1A57D46CEA06B837 /* Pods-Partita.release.xcconfig */, 71 | ); 72 | name = Pods; 73 | sourceTree = ""; 74 | }; 75 | DD28EAFC1BD0C57400DA041C /* Extensions */ = { 76 | isa = PBXGroup; 77 | children = ( 78 | DD28EAFD1BD0C58000DA041C /* UIColorExtension.swift */, 79 | ); 80 | name = Extensions; 81 | sourceTree = ""; 82 | }; 83 | DD355BD51BC783810044C19E = { 84 | isa = PBXGroup; 85 | children = ( 86 | DD355BE01BC783810044C19E /* Partita */, 87 | DD355BDF1BC783810044C19E /* Products */, 88 | 5FD764D94FF8C90715C92547 /* Frameworks */, 89 | C946D45462A5562FF071BB92 /* Pods */, 90 | ); 91 | sourceTree = ""; 92 | }; 93 | DD355BDF1BC783810044C19E /* Products */ = { 94 | isa = PBXGroup; 95 | children = ( 96 | DD355BDE1BC783810044C19E /* Partita.app */, 97 | ); 98 | name = Products; 99 | sourceTree = ""; 100 | }; 101 | DD355BE01BC783810044C19E /* Partita */ = { 102 | isa = PBXGroup; 103 | children = ( 104 | DD28EAFC1BD0C57400DA041C /* Extensions */, 105 | DD355C111BC784000044C19E /* Classes */, 106 | DD355C101BC783FA0044C19E /* Resources */, 107 | DD355C0F1BC783F00044C19E /* Supporting Files */, 108 | ); 109 | path = Partita; 110 | sourceTree = ""; 111 | }; 112 | DD355C0F1BC783F00044C19E /* Supporting Files */ = { 113 | isa = PBXGroup; 114 | children = ( 115 | DD8544541DD90EA800043114 /* Pods-Partita-acknowledgements.plist */, 116 | DD355BED1BC783810044C19E /* Info.plist */, 117 | ); 118 | name = "Supporting Files"; 119 | sourceTree = ""; 120 | }; 121 | DD355C101BC783FA0044C19E /* Resources */ = { 122 | isa = PBXGroup; 123 | children = ( 124 | DDF8193E1BD47156002D7C20 /* Pods-acknowledgements.plist */, 125 | DD355BE81BC783810044C19E /* Assets.xcassets */, 126 | DD84F8F61BD353060021186E /* Launch Screen.storyboard */, 127 | ); 128 | name = Resources; 129 | sourceTree = ""; 130 | }; 131 | DD355C111BC784000044C19E /* Classes */ = { 132 | isa = PBXGroup; 133 | children = ( 134 | DD355BE11BC783810044C19E /* AppDelegate.swift */, 135 | DD84F8FD1BD386F10021186E /* Views */, 136 | DD46A1561BCA4ADE003817B8 /* View Controllers */, 137 | ); 138 | name = Classes; 139 | sourceTree = ""; 140 | }; 141 | DD46A1561BCA4ADE003817B8 /* View Controllers */ = { 142 | isa = PBXGroup; 143 | children = ( 144 | DD355BE31BC783810044C19E /* MainViewController.swift */, 145 | DD28D2A01BD3BD1E00A96149 /* InfoViewController.swift */, 146 | ); 147 | name = "View Controllers"; 148 | sourceTree = ""; 149 | }; 150 | DD84F8FD1BD386F10021186E /* Views */ = { 151 | isa = PBXGroup; 152 | children = ( 153 | DD84F8FE1BD386FD0021186E /* TunerView.swift */, 154 | ); 155 | name = Views; 156 | sourceTree = ""; 157 | }; 158 | /* End PBXGroup section */ 159 | 160 | /* Begin PBXNativeTarget section */ 161 | DD355BDD1BC783810044C19E /* Partita */ = { 162 | isa = PBXNativeTarget; 163 | buildConfigurationList = DD355C061BC783810044C19E /* Build configuration list for PBXNativeTarget "Partita" */; 164 | buildPhases = ( 165 | BD5B37192951AD403696C110 /* [CP] Check Pods Manifest.lock */, 166 | DD355BDA1BC783810044C19E /* Sources */, 167 | DD355BDB1BC783810044C19E /* Frameworks */, 168 | DD355BDC1BC783810044C19E /* Resources */, 169 | AE5FF25AE667F49D91A75A53 /* [CP] Embed Pods Frameworks */, 170 | 6D172C5B4373329FBCE09C21 /* [CP] Copy Pods Resources */, 171 | ); 172 | buildRules = ( 173 | ); 174 | dependencies = ( 175 | ); 176 | name = Partita; 177 | productName = Partita; 178 | productReference = DD355BDE1BC783810044C19E /* Partita.app */; 179 | productType = "com.apple.product-type.application"; 180 | }; 181 | /* End PBXNativeTarget section */ 182 | 183 | /* Begin PBXProject section */ 184 | DD355BD61BC783810044C19E /* Project object */ = { 185 | isa = PBXProject; 186 | attributes = { 187 | LastUpgradeCheck = 0810; 188 | ORGANIZATIONNAME = "Comyar Zaheri"; 189 | TargetAttributes = { 190 | DD355BDD1BC783810044C19E = { 191 | CreatedOnToolsVersion = 7.0.1; 192 | LastSwiftMigration = 0810; 193 | }; 194 | }; 195 | }; 196 | buildConfigurationList = DD355BD91BC783810044C19E /* Build configuration list for PBXProject "Partita" */; 197 | compatibilityVersion = "Xcode 3.2"; 198 | developmentRegion = English; 199 | hasScannedForEncodings = 0; 200 | knownRegions = ( 201 | en, 202 | Base, 203 | ); 204 | mainGroup = DD355BD51BC783810044C19E; 205 | productRefGroup = DD355BDF1BC783810044C19E /* Products */; 206 | projectDirPath = ""; 207 | projectRoot = ""; 208 | targets = ( 209 | DD355BDD1BC783810044C19E /* Partita */, 210 | ); 211 | }; 212 | /* End PBXProject section */ 213 | 214 | /* Begin PBXResourcesBuildPhase section */ 215 | DD355BDC1BC783810044C19E /* Resources */ = { 216 | isa = PBXResourcesBuildPhase; 217 | buildActionMask = 2147483647; 218 | files = ( 219 | DD8544551DD90EA800043114 /* Pods-Partita-acknowledgements.plist in Resources */, 220 | DD84F8F71BD353060021186E /* Launch Screen.storyboard in Resources */, 221 | DD355BE91BC783810044C19E /* Assets.xcassets in Resources */, 222 | ); 223 | runOnlyForDeploymentPostprocessing = 0; 224 | }; 225 | /* End PBXResourcesBuildPhase section */ 226 | 227 | /* Begin PBXShellScriptBuildPhase section */ 228 | 6D172C5B4373329FBCE09C21 /* [CP] Copy Pods Resources */ = { 229 | isa = PBXShellScriptBuildPhase; 230 | buildActionMask = 2147483647; 231 | files = ( 232 | ); 233 | inputPaths = ( 234 | ); 235 | name = "[CP] Copy Pods Resources"; 236 | outputPaths = ( 237 | ); 238 | runOnlyForDeploymentPostprocessing = 0; 239 | shellPath = /bin/sh; 240 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-Partita/Pods-Partita-resources.sh\"\n"; 241 | showEnvVarsInLog = 0; 242 | }; 243 | AE5FF25AE667F49D91A75A53 /* [CP] Embed Pods Frameworks */ = { 244 | isa = PBXShellScriptBuildPhase; 245 | buildActionMask = 2147483647; 246 | files = ( 247 | ); 248 | inputPaths = ( 249 | ); 250 | name = "[CP] Embed Pods Frameworks"; 251 | outputPaths = ( 252 | ); 253 | runOnlyForDeploymentPostprocessing = 0; 254 | shellPath = /bin/sh; 255 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-Partita/Pods-Partita-frameworks.sh\"\n"; 256 | showEnvVarsInLog = 0; 257 | }; 258 | BD5B37192951AD403696C110 /* [CP] Check Pods Manifest.lock */ = { 259 | isa = PBXShellScriptBuildPhase; 260 | buildActionMask = 2147483647; 261 | files = ( 262 | ); 263 | inputPaths = ( 264 | ); 265 | name = "[CP] Check Pods Manifest.lock"; 266 | outputPaths = ( 267 | ); 268 | runOnlyForDeploymentPostprocessing = 0; 269 | shellPath = /bin/sh; 270 | shellScript = "diff \"${PODS_ROOT}/../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"; 271 | showEnvVarsInLog = 0; 272 | }; 273 | /* End PBXShellScriptBuildPhase section */ 274 | 275 | /* Begin PBXSourcesBuildPhase section */ 276 | DD355BDA1BC783810044C19E /* Sources */ = { 277 | isa = PBXSourcesBuildPhase; 278 | buildActionMask = 2147483647; 279 | files = ( 280 | DD355BE41BC783810044C19E /* MainViewController.swift in Sources */, 281 | DD28EAFE1BD0C58000DA041C /* UIColorExtension.swift in Sources */, 282 | DD84F8FF1BD386FD0021186E /* TunerView.swift in Sources */, 283 | DD355BE21BC783810044C19E /* AppDelegate.swift in Sources */, 284 | DD28D2A11BD3BD1E00A96149 /* InfoViewController.swift in Sources */, 285 | ); 286 | runOnlyForDeploymentPostprocessing = 0; 287 | }; 288 | /* End PBXSourcesBuildPhase section */ 289 | 290 | /* Begin XCBuildConfiguration section */ 291 | DD355C041BC783810044C19E /* Debug */ = { 292 | isa = XCBuildConfiguration; 293 | buildSettings = { 294 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = "$(inherited)"; 295 | ALWAYS_SEARCH_USER_PATHS = NO; 296 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 297 | CLANG_CXX_LIBRARY = "libc++"; 298 | CLANG_ENABLE_MODULES = YES; 299 | CLANG_ENABLE_OBJC_ARC = YES; 300 | CLANG_WARN_BOOL_CONVERSION = YES; 301 | CLANG_WARN_CONSTANT_CONVERSION = YES; 302 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 303 | CLANG_WARN_EMPTY_BODY = YES; 304 | CLANG_WARN_ENUM_CONVERSION = YES; 305 | CLANG_WARN_INFINITE_RECURSION = YES; 306 | CLANG_WARN_INT_CONVERSION = YES; 307 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 308 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 309 | CLANG_WARN_UNREACHABLE_CODE = YES; 310 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 311 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 312 | COPY_PHASE_STRIP = NO; 313 | DEBUG_INFORMATION_FORMAT = dwarf; 314 | ENABLE_BITCODE = NO; 315 | ENABLE_STRICT_OBJC_MSGSEND = YES; 316 | ENABLE_TESTABILITY = YES; 317 | GCC_C_LANGUAGE_STANDARD = gnu99; 318 | GCC_DYNAMIC_NO_PIC = NO; 319 | GCC_NO_COMMON_BLOCKS = YES; 320 | GCC_OPTIMIZATION_LEVEL = 0; 321 | GCC_PREPROCESSOR_DEFINITIONS = ( 322 | "DEBUG=1", 323 | "$(inherited)", 324 | ); 325 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 326 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 327 | GCC_WARN_UNDECLARED_SELECTOR = YES; 328 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 329 | GCC_WARN_UNUSED_FUNCTION = YES; 330 | GCC_WARN_UNUSED_VARIABLE = YES; 331 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 332 | MTL_ENABLE_DEBUG_INFO = YES; 333 | ONLY_ACTIVE_ARCH = YES; 334 | SDKROOT = iphoneos; 335 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 336 | TARGETED_DEVICE_FAMILY = "1,2"; 337 | }; 338 | name = Debug; 339 | }; 340 | DD355C051BC783810044C19E /* Release */ = { 341 | isa = XCBuildConfiguration; 342 | buildSettings = { 343 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = "$(inherited)"; 344 | ALWAYS_SEARCH_USER_PATHS = NO; 345 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 346 | CLANG_CXX_LIBRARY = "libc++"; 347 | CLANG_ENABLE_MODULES = YES; 348 | CLANG_ENABLE_OBJC_ARC = YES; 349 | CLANG_WARN_BOOL_CONVERSION = YES; 350 | CLANG_WARN_CONSTANT_CONVERSION = YES; 351 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 352 | CLANG_WARN_EMPTY_BODY = YES; 353 | CLANG_WARN_ENUM_CONVERSION = YES; 354 | CLANG_WARN_INFINITE_RECURSION = YES; 355 | CLANG_WARN_INT_CONVERSION = YES; 356 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 357 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 358 | CLANG_WARN_UNREACHABLE_CODE = YES; 359 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 360 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 361 | COPY_PHASE_STRIP = NO; 362 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 363 | ENABLE_BITCODE = NO; 364 | ENABLE_NS_ASSERTIONS = NO; 365 | ENABLE_STRICT_OBJC_MSGSEND = YES; 366 | GCC_C_LANGUAGE_STANDARD = gnu99; 367 | GCC_NO_COMMON_BLOCKS = YES; 368 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 369 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 370 | GCC_WARN_UNDECLARED_SELECTOR = YES; 371 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 372 | GCC_WARN_UNUSED_FUNCTION = YES; 373 | GCC_WARN_UNUSED_VARIABLE = YES; 374 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 375 | MTL_ENABLE_DEBUG_INFO = NO; 376 | SDKROOT = iphoneos; 377 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 378 | TARGETED_DEVICE_FAMILY = "1,2"; 379 | VALIDATE_PRODUCT = YES; 380 | }; 381 | name = Release; 382 | }; 383 | DD355C071BC783810044C19E /* Debug */ = { 384 | isa = XCBuildConfiguration; 385 | baseConfigurationReference = 20BE7C56084CD9E5016CDB66 /* Pods-Partita.debug.xcconfig */; 386 | buildSettings = { 387 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = "$(inherited)"; 388 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 389 | CODE_SIGN_IDENTITY = "iPhone Developer"; 390 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 391 | ENABLE_BITCODE = NO; 392 | FRAMEWORK_SEARCH_PATHS = "$(inherited)"; 393 | INFOPLIST_FILE = Partita/Info.plist; 394 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 395 | PRODUCT_BUNDLE_IDENTIFIER = com.comyarzaheri.Partita; 396 | PRODUCT_NAME = "$(TARGET_NAME)"; 397 | PROVISIONING_PROFILE = ""; 398 | SWIFT_OBJC_BRIDGING_HEADER = ""; 399 | SWIFT_VERSION = 3.0; 400 | }; 401 | name = Debug; 402 | }; 403 | DD355C081BC783810044C19E /* Release */ = { 404 | isa = XCBuildConfiguration; 405 | baseConfigurationReference = 1C6A156C1A57D46CEA06B837 /* Pods-Partita.release.xcconfig */; 406 | buildSettings = { 407 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = "$(inherited)"; 408 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 409 | CODE_SIGN_IDENTITY = "iPhone Developer"; 410 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 411 | ENABLE_BITCODE = NO; 412 | FRAMEWORK_SEARCH_PATHS = "$(inherited)"; 413 | INFOPLIST_FILE = Partita/Info.plist; 414 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 415 | PRODUCT_BUNDLE_IDENTIFIER = com.comyarzaheri.Partita; 416 | PRODUCT_NAME = "$(TARGET_NAME)"; 417 | PROVISIONING_PROFILE = ""; 418 | SWIFT_OBJC_BRIDGING_HEADER = ""; 419 | SWIFT_VERSION = 3.0; 420 | }; 421 | name = Release; 422 | }; 423 | /* End XCBuildConfiguration section */ 424 | 425 | /* Begin XCConfigurationList section */ 426 | DD355BD91BC783810044C19E /* Build configuration list for PBXProject "Partita" */ = { 427 | isa = XCConfigurationList; 428 | buildConfigurations = ( 429 | DD355C041BC783810044C19E /* Debug */, 430 | DD355C051BC783810044C19E /* Release */, 431 | ); 432 | defaultConfigurationIsVisible = 0; 433 | defaultConfigurationName = Release; 434 | }; 435 | DD355C061BC783810044C19E /* Build configuration list for PBXNativeTarget "Partita" */ = { 436 | isa = XCConfigurationList; 437 | buildConfigurations = ( 438 | DD355C071BC783810044C19E /* Debug */, 439 | DD355C081BC783810044C19E /* Release */, 440 | ); 441 | defaultConfigurationIsVisible = 0; 442 | defaultConfigurationName = Release; 443 | }; 444 | /* End XCConfigurationList section */ 445 | }; 446 | rootObject = DD355BD61BC783810044C19E /* Project object */; 447 | } 448 | --------------------------------------------------------------------------------