├── .gitignore ├── .swift-version ├── .travis.yml ├── Example ├── ForceTouchImageViewExample.xcodeproj │ ├── project.pbxproj │ └── project.xcworkspace │ │ └── contents.xcworkspacedata ├── ForceTouchImageViewExample.xcworkspace │ └── contents.xcworkspacedata ├── ForceTouchImageViewExample │ ├── AppDelegate.swift │ ├── Assets.xcassets │ │ ├── AppIcon.appiconset │ │ │ └── Contents.json │ │ ├── Contents.json │ │ └── bird.imageset │ │ │ ├── Contents.json │ │ │ └── bird.jpg │ ├── Base.lproj │ │ ├── LaunchScreen.storyboard │ │ └── Main.storyboard │ ├── Info.plist │ └── ViewController.swift ├── Podfile ├── Podfile.lock └── Pods │ ├── ForceTouchImageView │ ├── LICENSE │ ├── README.md │ └── Source │ │ └── ForceTouchImageView.swift │ ├── Manifest.lock │ ├── Pods.xcodeproj │ └── project.pbxproj │ └── Target Support Files │ ├── ForceTouchImageView │ ├── ForceTouchImageView-dummy.m │ ├── ForceTouchImageView-prefix.pch │ ├── ForceTouchImageView-umbrella.h │ ├── ForceTouchImageView.modulemap │ ├── ForceTouchImageView.xcconfig │ └── Info.plist │ └── Pods-ForceTouchImageViewExample │ ├── Info.plist │ ├── Pods-ForceTouchImageViewExample-acknowledgements.markdown │ ├── Pods-ForceTouchImageViewExample-acknowledgements.plist │ ├── Pods-ForceTouchImageViewExample-dummy.m │ ├── Pods-ForceTouchImageViewExample-frameworks.sh │ ├── Pods-ForceTouchImageViewExample-resources.sh │ ├── Pods-ForceTouchImageViewExample-umbrella.h │ ├── Pods-ForceTouchImageViewExample.debug.xcconfig │ ├── Pods-ForceTouchImageViewExample.modulemap │ └── Pods-ForceTouchImageViewExample.release.xcconfig ├── ForceTouchImageView.podspec ├── ForceTouchImageView.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ └── contents.xcworkspacedata └── xcshareddata │ └── xcschemes │ └── ForceTouchImageView.xcscheme ├── ForceTouchImageView.xcworkspace └── contents.xcworkspacedata ├── ForceTouchImageViewTests ├── ForceTouchImageViewTests.swift └── Info.plist ├── LICENSE ├── README.md ├── Source ├── ForceTouchImageView.h ├── ForceTouchImageView.swift └── Info.plist ├── build.sh └── debug-time-function-bodies.sh /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore 4 | 5 | ## Build generated 6 | build/ 7 | DerivedData/ 8 | 9 | ## Various settings 10 | *.pbxuser 11 | !default.pbxuser 12 | *.mode1v3 13 | !default.mode1v3 14 | *.mode2v3 15 | !default.mode2v3 16 | *.perspectivev3 17 | !default.perspectivev3 18 | xcuserdata/ 19 | 20 | ## Other 21 | *.moved-aside 22 | *.xcuserstate 23 | 24 | ## Obj-C/Swift specific 25 | *.hmap 26 | *.ipa 27 | *.dSYM.zip 28 | *.dSYM 29 | 30 | ## Playgrounds 31 | timeline.xctimeline 32 | playground.xcworkspace 33 | 34 | # Swift Package Manager 35 | # 36 | # Add this line if you want to avoid checking in source code from Swift Package Manager dependencies. 37 | # Packages/ 38 | .build/ 39 | 40 | # CocoaPods 41 | # 42 | # We recommend against adding the Pods directory to your .gitignore. However 43 | # you should judge for yourself, the pros and cons are mentioned at: 44 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control 45 | # 46 | # Pods/ 47 | 48 | # Carthage 49 | # 50 | # Add this line if you want to avoid checking in source code from Carthage dependencies. 51 | # Carthage/Checkouts 52 | 53 | Carthage/Build 54 | 55 | # fastlane 56 | # 57 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the 58 | # screenshots whenever they are needed. 59 | # For more information about the recommended setup visit: 60 | # https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Gitignore.md 61 | 62 | fastlane/report.xml 63 | fastlane/Preview.html 64 | fastlane/screenshots 65 | fastlane/test_output 66 | -------------------------------------------------------------------------------- /.swift-version: -------------------------------------------------------------------------------- 1 | 3.0 2 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | osx_image: xcode8.2 2 | language: objective-c 3 | before_install: 4 | - gem install xcpretty 5 | script: sh build.sh /tmp/ForceTouchImageView 6 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 04796DABF7F6D9E88E6FCC04 /* Pods_ForceTouchImageViewExample.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 797BDB1E1C3A3820246C0111 /* Pods_ForceTouchImageViewExample.framework */; }; 11 | 07E4E0911E9AF29400BF71FB /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 07E4E0901E9AF29400BF71FB /* AppDelegate.swift */; }; 12 | 07E4E0931E9AF29400BF71FB /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 07E4E0921E9AF29400BF71FB /* ViewController.swift */; }; 13 | 07E4E0961E9AF29400BF71FB /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 07E4E0941E9AF29400BF71FB /* Main.storyboard */; }; 14 | 07E4E0981E9AF29400BF71FB /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 07E4E0971E9AF29400BF71FB /* Assets.xcassets */; }; 15 | 07E4E09B1E9AF29400BF71FB /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 07E4E0991E9AF29400BF71FB /* LaunchScreen.storyboard */; }; 16 | /* End PBXBuildFile section */ 17 | 18 | /* Begin PBXFileReference section */ 19 | 07E4E08D1E9AF29400BF71FB /* ForceTouchImageViewExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ForceTouchImageViewExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; 20 | 07E4E0901E9AF29400BF71FB /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 21 | 07E4E0921E9AF29400BF71FB /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; 22 | 07E4E0951E9AF29400BF71FB /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 23 | 07E4E0971E9AF29400BF71FB /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 24 | 07E4E09A1E9AF29400BF71FB /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 25 | 07E4E09C1E9AF29400BF71FB /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 26 | 4EE826B4BCBCB3DC73C7DD7E /* Pods-ForceTouchImageViewExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ForceTouchImageViewExample.release.xcconfig"; path = "Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.release.xcconfig"; sourceTree = ""; }; 27 | 654ABDE04E6BA67A652605A3 /* Pods-ForceTouchImageViewExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ForceTouchImageViewExample.debug.xcconfig"; path = "Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.debug.xcconfig"; sourceTree = ""; }; 28 | 797BDB1E1C3A3820246C0111 /* Pods_ForceTouchImageViewExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_ForceTouchImageViewExample.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 29 | /* End PBXFileReference section */ 30 | 31 | /* Begin PBXFrameworksBuildPhase section */ 32 | 07E4E08A1E9AF29400BF71FB /* Frameworks */ = { 33 | isa = PBXFrameworksBuildPhase; 34 | buildActionMask = 2147483647; 35 | files = ( 36 | 04796DABF7F6D9E88E6FCC04 /* Pods_ForceTouchImageViewExample.framework in Frameworks */, 37 | ); 38 | runOnlyForDeploymentPostprocessing = 0; 39 | }; 40 | /* End PBXFrameworksBuildPhase section */ 41 | 42 | /* Begin PBXGroup section */ 43 | 07E4E0841E9AF29400BF71FB = { 44 | isa = PBXGroup; 45 | children = ( 46 | 07E4E08F1E9AF29400BF71FB /* ForceTouchImageViewExample */, 47 | 07E4E08E1E9AF29400BF71FB /* Products */, 48 | E1BACDB5C4001CCC0CD9568D /* Pods */, 49 | F8CED92D6BBC41E94A66BD18 /* Frameworks */, 50 | ); 51 | sourceTree = ""; 52 | }; 53 | 07E4E08E1E9AF29400BF71FB /* Products */ = { 54 | isa = PBXGroup; 55 | children = ( 56 | 07E4E08D1E9AF29400BF71FB /* ForceTouchImageViewExample.app */, 57 | ); 58 | name = Products; 59 | sourceTree = ""; 60 | }; 61 | 07E4E08F1E9AF29400BF71FB /* ForceTouchImageViewExample */ = { 62 | isa = PBXGroup; 63 | children = ( 64 | 07E4E0901E9AF29400BF71FB /* AppDelegate.swift */, 65 | 07E4E0921E9AF29400BF71FB /* ViewController.swift */, 66 | 07E4E0941E9AF29400BF71FB /* Main.storyboard */, 67 | 07E4E0971E9AF29400BF71FB /* Assets.xcassets */, 68 | 07E4E0991E9AF29400BF71FB /* LaunchScreen.storyboard */, 69 | 07E4E09C1E9AF29400BF71FB /* Info.plist */, 70 | ); 71 | path = ForceTouchImageViewExample; 72 | sourceTree = ""; 73 | }; 74 | E1BACDB5C4001CCC0CD9568D /* Pods */ = { 75 | isa = PBXGroup; 76 | children = ( 77 | 654ABDE04E6BA67A652605A3 /* Pods-ForceTouchImageViewExample.debug.xcconfig */, 78 | 4EE826B4BCBCB3DC73C7DD7E /* Pods-ForceTouchImageViewExample.release.xcconfig */, 79 | ); 80 | name = Pods; 81 | sourceTree = ""; 82 | }; 83 | F8CED92D6BBC41E94A66BD18 /* Frameworks */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | 797BDB1E1C3A3820246C0111 /* Pods_ForceTouchImageViewExample.framework */, 87 | ); 88 | name = Frameworks; 89 | sourceTree = ""; 90 | }; 91 | /* End PBXGroup section */ 92 | 93 | /* Begin PBXNativeTarget section */ 94 | 07E4E08C1E9AF29400BF71FB /* ForceTouchImageViewExample */ = { 95 | isa = PBXNativeTarget; 96 | buildConfigurationList = 07E4E09F1E9AF29400BF71FB /* Build configuration list for PBXNativeTarget "ForceTouchImageViewExample" */; 97 | buildPhases = ( 98 | 9385DC806D19A779B8C56556 /* [CP] Check Pods Manifest.lock */, 99 | 07E4E0891E9AF29400BF71FB /* Sources */, 100 | 07E4E08A1E9AF29400BF71FB /* Frameworks */, 101 | 07E4E08B1E9AF29400BF71FB /* Resources */, 102 | 8E2774A80661264FEC887B85 /* [CP] Embed Pods Frameworks */, 103 | E4327B803A472B975E09B1CE /* [CP] Copy Pods Resources */, 104 | ); 105 | buildRules = ( 106 | ); 107 | dependencies = ( 108 | ); 109 | name = ForceTouchImageViewExample; 110 | productName = ForceTouchImageViewExample; 111 | productReference = 07E4E08D1E9AF29400BF71FB /* ForceTouchImageViewExample.app */; 112 | productType = "com.apple.product-type.application"; 113 | }; 114 | /* End PBXNativeTarget section */ 115 | 116 | /* Begin PBXProject section */ 117 | 07E4E0851E9AF29400BF71FB /* Project object */ = { 118 | isa = PBXProject; 119 | attributes = { 120 | LastSwiftUpdateCheck = 0830; 121 | LastUpgradeCheck = 0830; 122 | ORGANIZATIONNAME = "Omar Albeik"; 123 | TargetAttributes = { 124 | 07E4E08C1E9AF29400BF71FB = { 125 | CreatedOnToolsVersion = 8.3.1; 126 | DevelopmentTeam = C3VKVFB3SA; 127 | ProvisioningStyle = Automatic; 128 | }; 129 | }; 130 | }; 131 | buildConfigurationList = 07E4E0881E9AF29400BF71FB /* Build configuration list for PBXProject "ForceTouchImageViewExample" */; 132 | compatibilityVersion = "Xcode 3.2"; 133 | developmentRegion = English; 134 | hasScannedForEncodings = 0; 135 | knownRegions = ( 136 | en, 137 | Base, 138 | ); 139 | mainGroup = 07E4E0841E9AF29400BF71FB; 140 | productRefGroup = 07E4E08E1E9AF29400BF71FB /* Products */; 141 | projectDirPath = ""; 142 | projectRoot = ""; 143 | targets = ( 144 | 07E4E08C1E9AF29400BF71FB /* ForceTouchImageViewExample */, 145 | ); 146 | }; 147 | /* End PBXProject section */ 148 | 149 | /* Begin PBXResourcesBuildPhase section */ 150 | 07E4E08B1E9AF29400BF71FB /* Resources */ = { 151 | isa = PBXResourcesBuildPhase; 152 | buildActionMask = 2147483647; 153 | files = ( 154 | 07E4E09B1E9AF29400BF71FB /* LaunchScreen.storyboard in Resources */, 155 | 07E4E0981E9AF29400BF71FB /* Assets.xcassets in Resources */, 156 | 07E4E0961E9AF29400BF71FB /* Main.storyboard in Resources */, 157 | ); 158 | runOnlyForDeploymentPostprocessing = 0; 159 | }; 160 | /* End PBXResourcesBuildPhase section */ 161 | 162 | /* Begin PBXShellScriptBuildPhase section */ 163 | 8E2774A80661264FEC887B85 /* [CP] Embed Pods Frameworks */ = { 164 | isa = PBXShellScriptBuildPhase; 165 | buildActionMask = 2147483647; 166 | files = ( 167 | ); 168 | inputPaths = ( 169 | ); 170 | name = "[CP] Embed Pods Frameworks"; 171 | outputPaths = ( 172 | ); 173 | runOnlyForDeploymentPostprocessing = 0; 174 | shellPath = /bin/sh; 175 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-frameworks.sh\"\n"; 176 | showEnvVarsInLog = 0; 177 | }; 178 | 9385DC806D19A779B8C56556 /* [CP] Check Pods Manifest.lock */ = { 179 | isa = PBXShellScriptBuildPhase; 180 | buildActionMask = 2147483647; 181 | files = ( 182 | ); 183 | inputPaths = ( 184 | ); 185 | name = "[CP] Check Pods Manifest.lock"; 186 | outputPaths = ( 187 | ); 188 | runOnlyForDeploymentPostprocessing = 0; 189 | shellPath = /bin/sh; 190 | 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"; 191 | showEnvVarsInLog = 0; 192 | }; 193 | E4327B803A472B975E09B1CE /* [CP] Copy Pods Resources */ = { 194 | isa = PBXShellScriptBuildPhase; 195 | buildActionMask = 2147483647; 196 | files = ( 197 | ); 198 | inputPaths = ( 199 | ); 200 | name = "[CP] Copy Pods Resources"; 201 | outputPaths = ( 202 | ); 203 | runOnlyForDeploymentPostprocessing = 0; 204 | shellPath = /bin/sh; 205 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-resources.sh\"\n"; 206 | showEnvVarsInLog = 0; 207 | }; 208 | /* End PBXShellScriptBuildPhase section */ 209 | 210 | /* Begin PBXSourcesBuildPhase section */ 211 | 07E4E0891E9AF29400BF71FB /* Sources */ = { 212 | isa = PBXSourcesBuildPhase; 213 | buildActionMask = 2147483647; 214 | files = ( 215 | 07E4E0931E9AF29400BF71FB /* ViewController.swift in Sources */, 216 | 07E4E0911E9AF29400BF71FB /* AppDelegate.swift in Sources */, 217 | ); 218 | runOnlyForDeploymentPostprocessing = 0; 219 | }; 220 | /* End PBXSourcesBuildPhase section */ 221 | 222 | /* Begin PBXVariantGroup section */ 223 | 07E4E0941E9AF29400BF71FB /* Main.storyboard */ = { 224 | isa = PBXVariantGroup; 225 | children = ( 226 | 07E4E0951E9AF29400BF71FB /* Base */, 227 | ); 228 | name = Main.storyboard; 229 | sourceTree = ""; 230 | }; 231 | 07E4E0991E9AF29400BF71FB /* LaunchScreen.storyboard */ = { 232 | isa = PBXVariantGroup; 233 | children = ( 234 | 07E4E09A1E9AF29400BF71FB /* Base */, 235 | ); 236 | name = LaunchScreen.storyboard; 237 | sourceTree = ""; 238 | }; 239 | /* End PBXVariantGroup section */ 240 | 241 | /* Begin XCBuildConfiguration section */ 242 | 07E4E09D1E9AF29400BF71FB /* Debug */ = { 243 | isa = XCBuildConfiguration; 244 | buildSettings = { 245 | ALWAYS_SEARCH_USER_PATHS = NO; 246 | CLANG_ANALYZER_NONNULL = YES; 247 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 248 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 249 | CLANG_CXX_LIBRARY = "libc++"; 250 | CLANG_ENABLE_MODULES = YES; 251 | CLANG_ENABLE_OBJC_ARC = YES; 252 | CLANG_WARN_BOOL_CONVERSION = YES; 253 | CLANG_WARN_CONSTANT_CONVERSION = YES; 254 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 255 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 256 | CLANG_WARN_EMPTY_BODY = YES; 257 | CLANG_WARN_ENUM_CONVERSION = YES; 258 | CLANG_WARN_INFINITE_RECURSION = YES; 259 | CLANG_WARN_INT_CONVERSION = YES; 260 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 261 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 262 | CLANG_WARN_UNREACHABLE_CODE = YES; 263 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 264 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 265 | COPY_PHASE_STRIP = NO; 266 | DEBUG_INFORMATION_FORMAT = dwarf; 267 | ENABLE_STRICT_OBJC_MSGSEND = YES; 268 | ENABLE_TESTABILITY = YES; 269 | GCC_C_LANGUAGE_STANDARD = gnu99; 270 | GCC_DYNAMIC_NO_PIC = NO; 271 | GCC_NO_COMMON_BLOCKS = YES; 272 | GCC_OPTIMIZATION_LEVEL = 0; 273 | GCC_PREPROCESSOR_DEFINITIONS = ( 274 | "DEBUG=1", 275 | "$(inherited)", 276 | ); 277 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 278 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 279 | GCC_WARN_UNDECLARED_SELECTOR = YES; 280 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 281 | GCC_WARN_UNUSED_FUNCTION = YES; 282 | GCC_WARN_UNUSED_VARIABLE = YES; 283 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 284 | MTL_ENABLE_DEBUG_INFO = YES; 285 | ONLY_ACTIVE_ARCH = YES; 286 | SDKROOT = iphoneos; 287 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 288 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 289 | TARGETED_DEVICE_FAMILY = "1,2"; 290 | }; 291 | name = Debug; 292 | }; 293 | 07E4E09E1E9AF29400BF71FB /* Release */ = { 294 | isa = XCBuildConfiguration; 295 | buildSettings = { 296 | ALWAYS_SEARCH_USER_PATHS = NO; 297 | CLANG_ANALYZER_NONNULL = YES; 298 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 299 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 300 | CLANG_CXX_LIBRARY = "libc++"; 301 | CLANG_ENABLE_MODULES = YES; 302 | CLANG_ENABLE_OBJC_ARC = YES; 303 | CLANG_WARN_BOOL_CONVERSION = YES; 304 | CLANG_WARN_CONSTANT_CONVERSION = YES; 305 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 306 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 307 | CLANG_WARN_EMPTY_BODY = YES; 308 | CLANG_WARN_ENUM_CONVERSION = YES; 309 | CLANG_WARN_INFINITE_RECURSION = YES; 310 | CLANG_WARN_INT_CONVERSION = YES; 311 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 312 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 313 | CLANG_WARN_UNREACHABLE_CODE = YES; 314 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 315 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 316 | COPY_PHASE_STRIP = NO; 317 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 318 | ENABLE_NS_ASSERTIONS = NO; 319 | ENABLE_STRICT_OBJC_MSGSEND = YES; 320 | GCC_C_LANGUAGE_STANDARD = gnu99; 321 | GCC_NO_COMMON_BLOCKS = YES; 322 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 323 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 324 | GCC_WARN_UNDECLARED_SELECTOR = YES; 325 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 326 | GCC_WARN_UNUSED_FUNCTION = YES; 327 | GCC_WARN_UNUSED_VARIABLE = YES; 328 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 329 | MTL_ENABLE_DEBUG_INFO = NO; 330 | SDKROOT = iphoneos; 331 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 332 | TARGETED_DEVICE_FAMILY = "1,2"; 333 | VALIDATE_PRODUCT = YES; 334 | }; 335 | name = Release; 336 | }; 337 | 07E4E0A01E9AF29400BF71FB /* Debug */ = { 338 | isa = XCBuildConfiguration; 339 | baseConfigurationReference = 654ABDE04E6BA67A652605A3 /* Pods-ForceTouchImageViewExample.debug.xcconfig */; 340 | buildSettings = { 341 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 342 | DEVELOPMENT_TEAM = C3VKVFB3SA; 343 | INFOPLIST_FILE = ForceTouchImageViewExample/Info.plist; 344 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 345 | PRODUCT_BUNDLE_IDENTIFIER = com.omaralbeik.ForceTouchImageViewExample; 346 | PRODUCT_NAME = "$(TARGET_NAME)"; 347 | SWIFT_VERSION = 3.0; 348 | }; 349 | name = Debug; 350 | }; 351 | 07E4E0A11E9AF29400BF71FB /* Release */ = { 352 | isa = XCBuildConfiguration; 353 | baseConfigurationReference = 4EE826B4BCBCB3DC73C7DD7E /* Pods-ForceTouchImageViewExample.release.xcconfig */; 354 | buildSettings = { 355 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 356 | DEVELOPMENT_TEAM = C3VKVFB3SA; 357 | INFOPLIST_FILE = ForceTouchImageViewExample/Info.plist; 358 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 359 | PRODUCT_BUNDLE_IDENTIFIER = com.omaralbeik.ForceTouchImageViewExample; 360 | PRODUCT_NAME = "$(TARGET_NAME)"; 361 | SWIFT_VERSION = 3.0; 362 | }; 363 | name = Release; 364 | }; 365 | /* End XCBuildConfiguration section */ 366 | 367 | /* Begin XCConfigurationList section */ 368 | 07E4E0881E9AF29400BF71FB /* Build configuration list for PBXProject "ForceTouchImageViewExample" */ = { 369 | isa = XCConfigurationList; 370 | buildConfigurations = ( 371 | 07E4E09D1E9AF29400BF71FB /* Debug */, 372 | 07E4E09E1E9AF29400BF71FB /* Release */, 373 | ); 374 | defaultConfigurationIsVisible = 0; 375 | defaultConfigurationName = Release; 376 | }; 377 | 07E4E09F1E9AF29400BF71FB /* Build configuration list for PBXNativeTarget "ForceTouchImageViewExample" */ = { 378 | isa = XCConfigurationList; 379 | buildConfigurations = ( 380 | 07E4E0A01E9AF29400BF71FB /* Debug */, 381 | 07E4E0A11E9AF29400BF71FB /* Release */, 382 | ); 383 | defaultConfigurationIsVisible = 0; 384 | defaultConfigurationName = Release; 385 | }; 386 | /* End XCConfigurationList section */ 387 | }; 388 | rootObject = 07E4E0851E9AF29400BF71FB /* Project object */; 389 | } 390 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // ForceTouchImageViewExample 4 | // 5 | // Created by Omar Albeik on 4/9/17. 6 | // Copyright © 2017 Omar Albeik. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | @UIApplicationMain 12 | class AppDelegate: UIResponder, UIApplicationDelegate { 13 | 14 | var window: UIWindow? 15 | 16 | 17 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { 18 | // Override point for customization after application launch. 19 | return true 20 | } 21 | 22 | func applicationWillResignActive(_ application: UIApplication) { 23 | // 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. 24 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. 25 | } 26 | 27 | func applicationDidEnterBackground(_ application: UIApplication) { 28 | // 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. 29 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. 30 | } 31 | 32 | func applicationWillEnterForeground(_ application: UIApplication) { 33 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. 34 | } 35 | 36 | func applicationDidBecomeActive(_ application: UIApplication) { 37 | // 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. 38 | } 39 | 40 | func applicationWillTerminate(_ application: UIApplication) { 41 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. 42 | } 43 | 44 | 45 | } 46 | 47 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/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 | "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 | "info" : { 90 | "version" : 1, 91 | "author" : "xcode" 92 | } 93 | } -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/Assets.xcassets/bird.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "bird.jpg", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "scale" : "2x" 11 | }, 12 | { 13 | "idiom" : "universal", 14 | "scale" : "3x" 15 | } 16 | ], 17 | "info" : { 18 | "version" : 1, 19 | "author" : "xcode" 20 | } 21 | } -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/Assets.xcassets/bird.imageset/bird.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/omaralbeik/ForceTouchImageView/a20bd8d3346c849160b1df2b75fa8c3f1f92eeda/Example/ForceTouchImageViewExample/Assets.xcassets/bird.imageset/bird.jpg -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/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 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/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 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/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 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | UILaunchStoryboardName 24 | LaunchScreen 25 | UIMainStoryboardFile 26 | Main 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /Example/ForceTouchImageViewExample/ViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.swift 3 | // ForceTouchImageViewExample 4 | // 5 | // Created by Omar Albeik on 4/9/17. 6 | // Copyright © 2017 Omar Albeik. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import ForceTouchImageView 11 | 12 | class ViewController: UIViewController { 13 | 14 | @IBOutlet weak var imageView: ForceTouchImageView! 15 | @IBOutlet weak var forceProgressView: UIProgressView! 16 | 17 | override func viewDidLoad() { 18 | super.viewDidLoad() 19 | imageView.forceTouchDelegate = self 20 | imageView.layer.cornerRadius = 25 21 | 22 | } 23 | 24 | } 25 | 26 | 27 | extension ViewController: ForceTouchImageViewDelegate { 28 | 29 | func forceTouchImageView(_ view: ForceTouchImageView, touchForceDidChange force: CGFloat) { 30 | forceProgressView.progress = Float(force/6.6) 31 | } 32 | 33 | } 34 | 35 | -------------------------------------------------------------------------------- /Example/Podfile: -------------------------------------------------------------------------------- 1 | # Uncomment the next line to define a global platform for your project 2 | # platform :ios, '9.0' 3 | 4 | target 'ForceTouchImageViewExample' do 5 | # Comment the next line if you're not using Swift and don't want to use dynamic frameworks 6 | use_frameworks! 7 | 8 | # Pods for ForceTouchImageViewExample 9 | pod 'ForceTouchImageView' 10 | 11 | end 12 | -------------------------------------------------------------------------------- /Example/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - ForceTouchImageView (0.1) 3 | 4 | DEPENDENCIES: 5 | - ForceTouchImageView 6 | 7 | SPEC CHECKSUMS: 8 | ForceTouchImageView: cfd431fabe39d559add1c91d2b0acb0b18366b3c 9 | 10 | PODFILE CHECKSUM: 7db90458478b1c93d72ffcb060960855370b0a20 11 | 12 | COCOAPODS: 1.2.0 13 | -------------------------------------------------------------------------------- /Example/Pods/ForceTouchImageView/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Omar Albeik 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 | -------------------------------------------------------------------------------- /Example/Pods/ForceTouchImageView/README.md: -------------------------------------------------------------------------------- 1 | # ForceTouchImageView 2 | Why pinch to zoom when your have 3D Touch 🤔 3 | -------------------------------------------------------------------------------- /Example/Pods/ForceTouchImageView/Source/ForceTouchImageView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ForceTouchImageView.swift 3 | // ForceTouchImageView 4 | // 5 | // Created by Omar Albeik on 4/9/17. 6 | // Copyright © 2017 Omar Albeik. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | public protocol ForceTouchImageViewDelegate: class { 12 | func forceTouchImageView(_ view: ForceTouchImageView, touchForceDidChange force: CGFloat) 13 | } 14 | 15 | extension ForceTouchImageViewDelegate { 16 | func forceTouchImageView(_ view: ForceTouchImageView, touchForceDidChange force: CGFloat) {} 17 | } 18 | 19 | 20 | @IBDesignable 21 | public class ForceTouchImageView: UIScrollView { 22 | 23 | public weak var forceTouchDelegate: ForceTouchImageViewDelegate? 24 | public var maximumPossibleForce: CGFloat = 0 25 | 26 | 27 | fileprivate var imageView: UIImageView! 28 | 29 | override init(frame: CGRect) { 30 | super.init(frame: frame) 31 | setupView() 32 | 33 | } 34 | 35 | required public init?(coder aDecoder: NSCoder) { 36 | super.init(coder: aDecoder) 37 | setupView() 38 | } 39 | 40 | @IBInspectable 41 | public var image: UIImage? { 42 | get { 43 | return imageView.image 44 | } 45 | set { 46 | imageView.image = newValue 47 | } 48 | } 49 | 50 | @IBInspectable 51 | public var highlightedImage: UIImage? { 52 | get { 53 | return imageView.highlightedImage 54 | } 55 | set { 56 | imageView.highlightedImage = newValue 57 | } 58 | } 59 | 60 | } 61 | 62 | 63 | // MARK: - Touch methdos 64 | public extension ForceTouchImageView { 65 | 66 | override func touchesMoved(_ touches: Set, with event: UIEvent?) { 67 | 68 | guard let touch = touches.first else { return } 69 | 70 | guard #available(iOS 9.0, *) else { 71 | debugPrint("ForceTouchImageView: Device does not support ForchTouch") 72 | return 73 | } 74 | 75 | guard traitCollection.forceTouchCapability == UIForceTouchCapability.available else { 76 | debugPrint("ForceTouchImageView: Device does not support ForchTouch") 77 | return 78 | } 79 | 80 | forceTouchDelegate?.forceTouchImageView(self, touchForceDidChange: touch.force) 81 | 82 | let scale = (touch.force*maximumZoomScale)/touch.maximumPossibleForce 83 | setZoomScale(scale, animated: true) 84 | 85 | } 86 | 87 | override func touchesEnded(_ touches: Set, with event: UIEvent?) { 88 | forceTouchDelegate?.forceTouchImageView(self, touchForceDidChange: 0) 89 | setZoomScale(1.0, animated: true) 90 | } 91 | 92 | } 93 | 94 | 95 | // MARK: - UIScrollViewDelegate 96 | extension ForceTouchImageView: UIScrollViewDelegate { 97 | 98 | public func viewForZooming(in scrollView: UIScrollView) -> UIView? { 99 | return imageView 100 | } 101 | 102 | } 103 | 104 | 105 | // MARK: - Helpers 106 | extension ForceTouchImageView { 107 | 108 | func setupView() { 109 | 110 | clipsToBounds = true 111 | bounces = false 112 | 113 | if imageView == nil { 114 | imageView = UIImageView(frame: self.bounds) 115 | } 116 | 117 | imageView.autoresizingMask = [.flexibleWidth, .flexibleHeight] 118 | imageView.contentMode = .scaleAspectFill 119 | imageView.isUserInteractionEnabled = true 120 | addSubview(imageView) 121 | 122 | minimumZoomScale = 1.0 123 | maximumZoomScale = 4.0 124 | 125 | delegate = self 126 | setupGestureRecognizers() 127 | } 128 | 129 | func setupGestureRecognizers() { 130 | let tap = UITapGestureRecognizer(target: self, action: #selector(respondToTap(sender:))) 131 | tap.numberOfTapsRequired = 2 132 | addGestureRecognizer(tap) 133 | } 134 | 135 | func respondToTap(sender: UITapGestureRecognizer) { 136 | let rect = zoomRect(for: 3.0, center: sender.location(in: self)) 137 | zoom(to: rect, animated: true) 138 | } 139 | 140 | func zoomRect(for scale: CGFloat, center: CGPoint) -> CGRect { 141 | var zoomRect = CGRect.zero 142 | zoomRect.size.height = frame.size.height / scale 143 | zoomRect.size.width = frame.size.width / scale 144 | let newCenter = imageView.convert(center, from: self) 145 | zoomRect.origin.x = newCenter.x - (zoomRect.size.width / 2.0) 146 | zoomRect.origin.y = newCenter.y - (zoomRect.size.height / 2.0) 147 | return zoomRect 148 | } 149 | 150 | var midiumZoomScale: CGFloat { 151 | return (maximumZoomScale-minimumZoomScale)/2.0 152 | } 153 | } 154 | 155 | -------------------------------------------------------------------------------- /Example/Pods/Manifest.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - ForceTouchImageView (0.1) 3 | 4 | DEPENDENCIES: 5 | - ForceTouchImageView 6 | 7 | SPEC CHECKSUMS: 8 | ForceTouchImageView: cfd431fabe39d559add1c91d2b0acb0b18366b3c 9 | 10 | PODFILE CHECKSUM: 7db90458478b1c93d72ffcb060960855370b0a20 11 | 12 | COCOAPODS: 1.2.0 13 | -------------------------------------------------------------------------------- /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 | 08D3E12BE6050FA64AD1AF5FB382AA05 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; }; 11 | 36643FA5A7CC4E78787A3E8A7FD765C0 /* ForceTouchImageView-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = E8CD913FC801EF4450173F2762A7E76A /* ForceTouchImageView-dummy.m */; }; 12 | 61AB9F9F784F72653122DC0D579C0200 /* Pods-ForceTouchImageViewExample-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 45E80C72E7E8B200AA7CF98205C82BAD /* Pods-ForceTouchImageViewExample-dummy.m */; }; 13 | 7AAED49888A5A7355CFCC5E4EAF0C17F /* Pods-ForceTouchImageViewExample-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = C4DFFB450C74473D120A10D50F6ABA54 /* Pods-ForceTouchImageViewExample-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 14 | B554608FCED2E778CE2A96A8D3CA01CA /* ForceTouchImageView.swift in Sources */ = {isa = PBXBuildFile; fileRef = F3426198341F03E8A27EA6D2BE347D94 /* ForceTouchImageView.swift */; }; 15 | D8D0E2C2DCAD363AD00A20EAF30DAC02 /* ForceTouchImageView-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 260F249011806A6ECC6CBA243DC39E38 /* ForceTouchImageView-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 16 | DFEA0B888B9AB9ED898A690281F223F9 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; }; 17 | /* End PBXBuildFile section */ 18 | 19 | /* Begin PBXContainerItemProxy section */ 20 | B080B57DAA56CF82760EE22C6841B033 /* PBXContainerItemProxy */ = { 21 | isa = PBXContainerItemProxy; 22 | containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; 23 | proxyType = 1; 24 | remoteGlobalIDString = 2F0435C021420387EAB7537E8193E840; 25 | remoteInfo = ForceTouchImageView; 26 | }; 27 | /* End PBXContainerItemProxy section */ 28 | 29 | /* Begin PBXFileReference section */ 30 | 212E7B82120ABC125948051F8054E3B1 /* Pods-ForceTouchImageViewExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-ForceTouchImageViewExample.debug.xcconfig"; sourceTree = ""; }; 31 | 260F249011806A6ECC6CBA243DC39E38 /* ForceTouchImageView-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "ForceTouchImageView-umbrella.h"; sourceTree = ""; }; 32 | 45E80C72E7E8B200AA7CF98205C82BAD /* Pods-ForceTouchImageViewExample-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-ForceTouchImageViewExample-dummy.m"; sourceTree = ""; }; 33 | 4803DA6352BA88369A90F56EC2795921 /* Pods_ForceTouchImageViewExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = Pods_ForceTouchImageViewExample.framework; path = "Pods-ForceTouchImageViewExample.framework"; sourceTree = BUILT_PRODUCTS_DIR; }; 34 | 5F3A54306ABD5F0405435C28ED505B1C /* Pods-ForceTouchImageViewExample-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-ForceTouchImageViewExample-frameworks.sh"; sourceTree = ""; }; 35 | 62D5FB9955CEA84DA65BE2BBCBD8531C /* ForceTouchImageView.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = ForceTouchImageView.framework; path = ForceTouchImageView.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 36 | 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; }; 37 | 78285DE34664F4CEF013EA5972F3E6E0 /* Pods-ForceTouchImageViewExample.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = "Pods-ForceTouchImageViewExample.modulemap"; sourceTree = ""; }; 38 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; lastKnownFileType = text; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; }; 39 | AF2BED6B408A0883D99C8BD7E9F9D896 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 40 | C4964DC5E542EF3CFF008F87DADBD2B5 /* Pods-ForceTouchImageViewExample-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-ForceTouchImageViewExample-resources.sh"; sourceTree = ""; }; 41 | C4DFFB450C74473D120A10D50F6ABA54 /* Pods-ForceTouchImageViewExample-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-ForceTouchImageViewExample-umbrella.h"; sourceTree = ""; }; 42 | D19CC678545AA600ED599DAECD0D0E57 /* Pods-ForceTouchImageViewExample-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-ForceTouchImageViewExample-acknowledgements.plist"; sourceTree = ""; }; 43 | D637B077147DFE6FD3016C72BFB15137 /* Pods-ForceTouchImageViewExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-ForceTouchImageViewExample.release.xcconfig"; sourceTree = ""; }; 44 | D9397CC941E089A6152F752DE7970748 /* Pods-ForceTouchImageViewExample-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-ForceTouchImageViewExample-acknowledgements.markdown"; sourceTree = ""; }; 45 | E282F3CF160F8CBB8528FB30A905EB1E /* ForceTouchImageView-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "ForceTouchImageView-prefix.pch"; sourceTree = ""; }; 46 | E7C19A318C77B7A39AE2FDA5FE785128 /* ForceTouchImageView.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = ForceTouchImageView.xcconfig; sourceTree = ""; }; 47 | E887ADD96E8777E8A550CF5175AD6161 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 48 | E8B09D1BD00DD3B917219E221A1F1886 /* ForceTouchImageView.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = ForceTouchImageView.modulemap; sourceTree = ""; }; 49 | E8CD913FC801EF4450173F2762A7E76A /* ForceTouchImageView-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "ForceTouchImageView-dummy.m"; sourceTree = ""; }; 50 | F3426198341F03E8A27EA6D2BE347D94 /* ForceTouchImageView.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; name = ForceTouchImageView.swift; path = Source/ForceTouchImageView.swift; sourceTree = ""; }; 51 | /* End PBXFileReference section */ 52 | 53 | /* Begin PBXFrameworksBuildPhase section */ 54 | 6AEEF74BA8788F8ECF8F6FB3DD546E97 /* Frameworks */ = { 55 | isa = PBXFrameworksBuildPhase; 56 | buildActionMask = 2147483647; 57 | files = ( 58 | DFEA0B888B9AB9ED898A690281F223F9 /* Foundation.framework in Frameworks */, 59 | ); 60 | runOnlyForDeploymentPostprocessing = 0; 61 | }; 62 | A958590CE8D8E46B0C460D2ED4E89FC4 /* Frameworks */ = { 63 | isa = PBXFrameworksBuildPhase; 64 | buildActionMask = 2147483647; 65 | files = ( 66 | 08D3E12BE6050FA64AD1AF5FB382AA05 /* Foundation.framework in Frameworks */, 67 | ); 68 | runOnlyForDeploymentPostprocessing = 0; 69 | }; 70 | /* End PBXFrameworksBuildPhase section */ 71 | 72 | /* Begin PBXGroup section */ 73 | 056EA62C7E93F93984C9093162DEC80D /* Products */ = { 74 | isa = PBXGroup; 75 | children = ( 76 | 62D5FB9955CEA84DA65BE2BBCBD8531C /* ForceTouchImageView.framework */, 77 | 4803DA6352BA88369A90F56EC2795921 /* Pods_ForceTouchImageViewExample.framework */, 78 | ); 79 | name = Products; 80 | sourceTree = ""; 81 | }; 82 | 4B80E2BA052183BDFF1C5092EBB4335F /* Targets Support Files */ = { 83 | isa = PBXGroup; 84 | children = ( 85 | 911A94F7C6FE9E46EFDC557EC4F0D096 /* Pods-ForceTouchImageViewExample */, 86 | ); 87 | name = "Targets Support Files"; 88 | sourceTree = ""; 89 | }; 90 | 7DB346D0F39D3F0E887471402A8071AB = { 91 | isa = PBXGroup; 92 | children = ( 93 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */, 94 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */, 95 | EC0A291237D5A86D78C21AF759846D7F /* Pods */, 96 | 056EA62C7E93F93984C9093162DEC80D /* Products */, 97 | 4B80E2BA052183BDFF1C5092EBB4335F /* Targets Support Files */, 98 | ); 99 | sourceTree = ""; 100 | }; 101 | 899D27FE1CFABECEF960E7CE8BEB63E2 /* ForceTouchImageView */ = { 102 | isa = PBXGroup; 103 | children = ( 104 | F3426198341F03E8A27EA6D2BE347D94 /* ForceTouchImageView.swift */, 105 | B3B4612BC7A4C7B039E9F3C2F2EECB2B /* Support Files */, 106 | ); 107 | name = ForceTouchImageView; 108 | path = ForceTouchImageView; 109 | sourceTree = ""; 110 | }; 111 | 911A94F7C6FE9E46EFDC557EC4F0D096 /* Pods-ForceTouchImageViewExample */ = { 112 | isa = PBXGroup; 113 | children = ( 114 | E887ADD96E8777E8A550CF5175AD6161 /* Info.plist */, 115 | 78285DE34664F4CEF013EA5972F3E6E0 /* Pods-ForceTouchImageViewExample.modulemap */, 116 | D9397CC941E089A6152F752DE7970748 /* Pods-ForceTouchImageViewExample-acknowledgements.markdown */, 117 | D19CC678545AA600ED599DAECD0D0E57 /* Pods-ForceTouchImageViewExample-acknowledgements.plist */, 118 | 45E80C72E7E8B200AA7CF98205C82BAD /* Pods-ForceTouchImageViewExample-dummy.m */, 119 | 5F3A54306ABD5F0405435C28ED505B1C /* Pods-ForceTouchImageViewExample-frameworks.sh */, 120 | C4964DC5E542EF3CFF008F87DADBD2B5 /* Pods-ForceTouchImageViewExample-resources.sh */, 121 | C4DFFB450C74473D120A10D50F6ABA54 /* Pods-ForceTouchImageViewExample-umbrella.h */, 122 | 212E7B82120ABC125948051F8054E3B1 /* Pods-ForceTouchImageViewExample.debug.xcconfig */, 123 | D637B077147DFE6FD3016C72BFB15137 /* Pods-ForceTouchImageViewExample.release.xcconfig */, 124 | ); 125 | name = "Pods-ForceTouchImageViewExample"; 126 | path = "Target Support Files/Pods-ForceTouchImageViewExample"; 127 | sourceTree = ""; 128 | }; 129 | B3B4612BC7A4C7B039E9F3C2F2EECB2B /* Support Files */ = { 130 | isa = PBXGroup; 131 | children = ( 132 | E8B09D1BD00DD3B917219E221A1F1886 /* ForceTouchImageView.modulemap */, 133 | E7C19A318C77B7A39AE2FDA5FE785128 /* ForceTouchImageView.xcconfig */, 134 | E8CD913FC801EF4450173F2762A7E76A /* ForceTouchImageView-dummy.m */, 135 | E282F3CF160F8CBB8528FB30A905EB1E /* ForceTouchImageView-prefix.pch */, 136 | 260F249011806A6ECC6CBA243DC39E38 /* ForceTouchImageView-umbrella.h */, 137 | AF2BED6B408A0883D99C8BD7E9F9D896 /* Info.plist */, 138 | ); 139 | name = "Support Files"; 140 | path = "../Target Support Files/ForceTouchImageView"; 141 | sourceTree = ""; 142 | }; 143 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */ = { 144 | isa = PBXGroup; 145 | children = ( 146 | D35AF013A5F0BAD4F32504907A52519E /* iOS */, 147 | ); 148 | name = Frameworks; 149 | sourceTree = ""; 150 | }; 151 | D35AF013A5F0BAD4F32504907A52519E /* iOS */ = { 152 | isa = PBXGroup; 153 | children = ( 154 | 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */, 155 | ); 156 | name = iOS; 157 | sourceTree = ""; 158 | }; 159 | EC0A291237D5A86D78C21AF759846D7F /* Pods */ = { 160 | isa = PBXGroup; 161 | children = ( 162 | 899D27FE1CFABECEF960E7CE8BEB63E2 /* ForceTouchImageView */, 163 | ); 164 | name = Pods; 165 | sourceTree = ""; 166 | }; 167 | /* End PBXGroup section */ 168 | 169 | /* Begin PBXHeadersBuildPhase section */ 170 | 69D218FC6379C1DF1B64FB9CC879AD60 /* Headers */ = { 171 | isa = PBXHeadersBuildPhase; 172 | buildActionMask = 2147483647; 173 | files = ( 174 | 7AAED49888A5A7355CFCC5E4EAF0C17F /* Pods-ForceTouchImageViewExample-umbrella.h in Headers */, 175 | ); 176 | runOnlyForDeploymentPostprocessing = 0; 177 | }; 178 | AF2154EF01C06450FADFDF14CE082F54 /* Headers */ = { 179 | isa = PBXHeadersBuildPhase; 180 | buildActionMask = 2147483647; 181 | files = ( 182 | D8D0E2C2DCAD363AD00A20EAF30DAC02 /* ForceTouchImageView-umbrella.h in Headers */, 183 | ); 184 | runOnlyForDeploymentPostprocessing = 0; 185 | }; 186 | /* End PBXHeadersBuildPhase section */ 187 | 188 | /* Begin PBXNativeTarget section */ 189 | 150EAF2ED709E81B77697DF90A2325CE /* Pods-ForceTouchImageViewExample */ = { 190 | isa = PBXNativeTarget; 191 | buildConfigurationList = E317E81A0A6C0047D829823D1CD6865C /* Build configuration list for PBXNativeTarget "Pods-ForceTouchImageViewExample" */; 192 | buildPhases = ( 193 | 605B32581747E5F2CC4214ED0A7263F9 /* Sources */, 194 | A958590CE8D8E46B0C460D2ED4E89FC4 /* Frameworks */, 195 | 69D218FC6379C1DF1B64FB9CC879AD60 /* Headers */, 196 | ); 197 | buildRules = ( 198 | ); 199 | dependencies = ( 200 | 019169BEDFBFFAF4547FB80B1B26AF7A /* PBXTargetDependency */, 201 | ); 202 | name = "Pods-ForceTouchImageViewExample"; 203 | productName = "Pods-ForceTouchImageViewExample"; 204 | productReference = 4803DA6352BA88369A90F56EC2795921 /* Pods_ForceTouchImageViewExample.framework */; 205 | productType = "com.apple.product-type.framework"; 206 | }; 207 | 2F0435C021420387EAB7537E8193E840 /* ForceTouchImageView */ = { 208 | isa = PBXNativeTarget; 209 | buildConfigurationList = AF4ABFCC58C296281FE92AF77662B509 /* Build configuration list for PBXNativeTarget "ForceTouchImageView" */; 210 | buildPhases = ( 211 | 0852E1EDAB2DEF6143212E07495C2857 /* Sources */, 212 | 6AEEF74BA8788F8ECF8F6FB3DD546E97 /* Frameworks */, 213 | AF2154EF01C06450FADFDF14CE082F54 /* Headers */, 214 | ); 215 | buildRules = ( 216 | ); 217 | dependencies = ( 218 | ); 219 | name = ForceTouchImageView; 220 | productName = ForceTouchImageView; 221 | productReference = 62D5FB9955CEA84DA65BE2BBCBD8531C /* ForceTouchImageView.framework */; 222 | productType = "com.apple.product-type.framework"; 223 | }; 224 | /* End PBXNativeTarget section */ 225 | 226 | /* Begin PBXProject section */ 227 | D41D8CD98F00B204E9800998ECF8427E /* Project object */ = { 228 | isa = PBXProject; 229 | attributes = { 230 | LastSwiftUpdateCheck = 0830; 231 | LastUpgradeCheck = 0700; 232 | }; 233 | buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */; 234 | compatibilityVersion = "Xcode 3.2"; 235 | developmentRegion = English; 236 | hasScannedForEncodings = 0; 237 | knownRegions = ( 238 | en, 239 | ); 240 | mainGroup = 7DB346D0F39D3F0E887471402A8071AB; 241 | productRefGroup = 056EA62C7E93F93984C9093162DEC80D /* Products */; 242 | projectDirPath = ""; 243 | projectRoot = ""; 244 | targets = ( 245 | 2F0435C021420387EAB7537E8193E840 /* ForceTouchImageView */, 246 | 150EAF2ED709E81B77697DF90A2325CE /* Pods-ForceTouchImageViewExample */, 247 | ); 248 | }; 249 | /* End PBXProject section */ 250 | 251 | /* Begin PBXSourcesBuildPhase section */ 252 | 0852E1EDAB2DEF6143212E07495C2857 /* Sources */ = { 253 | isa = PBXSourcesBuildPhase; 254 | buildActionMask = 2147483647; 255 | files = ( 256 | 36643FA5A7CC4E78787A3E8A7FD765C0 /* ForceTouchImageView-dummy.m in Sources */, 257 | B554608FCED2E778CE2A96A8D3CA01CA /* ForceTouchImageView.swift in Sources */, 258 | ); 259 | runOnlyForDeploymentPostprocessing = 0; 260 | }; 261 | 605B32581747E5F2CC4214ED0A7263F9 /* Sources */ = { 262 | isa = PBXSourcesBuildPhase; 263 | buildActionMask = 2147483647; 264 | files = ( 265 | 61AB9F9F784F72653122DC0D579C0200 /* Pods-ForceTouchImageViewExample-dummy.m in Sources */, 266 | ); 267 | runOnlyForDeploymentPostprocessing = 0; 268 | }; 269 | /* End PBXSourcesBuildPhase section */ 270 | 271 | /* Begin PBXTargetDependency section */ 272 | 019169BEDFBFFAF4547FB80B1B26AF7A /* PBXTargetDependency */ = { 273 | isa = PBXTargetDependency; 274 | name = ForceTouchImageView; 275 | target = 2F0435C021420387EAB7537E8193E840 /* ForceTouchImageView */; 276 | targetProxy = B080B57DAA56CF82760EE22C6841B033 /* PBXContainerItemProxy */; 277 | }; 278 | /* End PBXTargetDependency section */ 279 | 280 | /* Begin XCBuildConfiguration section */ 281 | 00412E824F0BA4B0A4B08AA796B010E2 /* Debug */ = { 282 | isa = XCBuildConfiguration; 283 | baseConfigurationReference = 212E7B82120ABC125948051F8054E3B1 /* Pods-ForceTouchImageViewExample.debug.xcconfig */; 284 | buildSettings = { 285 | CODE_SIGN_IDENTITY = ""; 286 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 287 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 288 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 289 | CURRENT_PROJECT_VERSION = 1; 290 | DEBUG_INFORMATION_FORMAT = dwarf; 291 | DEFINES_MODULE = YES; 292 | DYLIB_COMPATIBILITY_VERSION = 1; 293 | DYLIB_CURRENT_VERSION = 1; 294 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 295 | ENABLE_STRICT_OBJC_MSGSEND = YES; 296 | GCC_NO_COMMON_BLOCKS = YES; 297 | INFOPLIST_FILE = "Target Support Files/Pods-ForceTouchImageViewExample/Info.plist"; 298 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 299 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 300 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 301 | MACH_O_TYPE = staticlib; 302 | MODULEMAP_FILE = "Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.modulemap"; 303 | MTL_ENABLE_DEBUG_INFO = YES; 304 | OTHER_LDFLAGS = ""; 305 | OTHER_LIBTOOLFLAGS = ""; 306 | PODS_ROOT = "$(SRCROOT)"; 307 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; 308 | PRODUCT_NAME = Pods_ForceTouchImageViewExample; 309 | SDKROOT = iphoneos; 310 | SKIP_INSTALL = YES; 311 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 312 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 313 | SWIFT_VERSION = 3.0; 314 | TARGETED_DEVICE_FAMILY = "1,2"; 315 | VERSIONING_SYSTEM = "apple-generic"; 316 | VERSION_INFO_PREFIX = ""; 317 | }; 318 | name = Debug; 319 | }; 320 | 163D87BE96A63549B0EACF1CC31A2E90 /* Debug */ = { 321 | isa = XCBuildConfiguration; 322 | buildSettings = { 323 | ALWAYS_SEARCH_USER_PATHS = NO; 324 | CLANG_ANALYZER_NONNULL = YES; 325 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES; 326 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 327 | CLANG_CXX_LIBRARY = "libc++"; 328 | CLANG_ENABLE_MODULES = YES; 329 | CLANG_ENABLE_OBJC_ARC = YES; 330 | CLANG_WARN_BOOL_CONVERSION = YES; 331 | CLANG_WARN_CONSTANT_CONVERSION = YES; 332 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; 333 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 334 | CLANG_WARN_EMPTY_BODY = YES; 335 | CLANG_WARN_ENUM_CONVERSION = YES; 336 | CLANG_WARN_INFINITE_RECURSION = YES; 337 | CLANG_WARN_INT_CONVERSION = YES; 338 | CLANG_WARN_OBJC_ROOT_CLASS = YES; 339 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 340 | CLANG_WARN_UNREACHABLE_CODE = YES; 341 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 342 | CODE_SIGNING_REQUIRED = NO; 343 | COPY_PHASE_STRIP = NO; 344 | ENABLE_TESTABILITY = YES; 345 | GCC_C_LANGUAGE_STANDARD = gnu99; 346 | GCC_DYNAMIC_NO_PIC = NO; 347 | GCC_OPTIMIZATION_LEVEL = 0; 348 | GCC_PREPROCESSOR_DEFINITIONS = ( 349 | "POD_CONFIGURATION_DEBUG=1", 350 | "DEBUG=1", 351 | "$(inherited)", 352 | ); 353 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 354 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 355 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 356 | GCC_WARN_UNDECLARED_SELECTOR = YES; 357 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 358 | GCC_WARN_UNUSED_FUNCTION = YES; 359 | GCC_WARN_UNUSED_VARIABLE = YES; 360 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 361 | ONLY_ACTIVE_ARCH = YES; 362 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; 363 | STRIP_INSTALLED_PRODUCT = NO; 364 | SYMROOT = "${SRCROOT}/../build"; 365 | }; 366 | name = Debug; 367 | }; 368 | 35BC99495D3E1680BD15521FBE8C71C8 /* Release */ = { 369 | isa = XCBuildConfiguration; 370 | baseConfigurationReference = E7C19A318C77B7A39AE2FDA5FE785128 /* ForceTouchImageView.xcconfig */; 371 | buildSettings = { 372 | CODE_SIGN_IDENTITY = ""; 373 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 374 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 375 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 376 | CURRENT_PROJECT_VERSION = 1; 377 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 378 | DEFINES_MODULE = YES; 379 | DYLIB_COMPATIBILITY_VERSION = 1; 380 | DYLIB_CURRENT_VERSION = 1; 381 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 382 | ENABLE_STRICT_OBJC_MSGSEND = YES; 383 | GCC_NO_COMMON_BLOCKS = YES; 384 | GCC_PREFIX_HEADER = "Target Support Files/ForceTouchImageView/ForceTouchImageView-prefix.pch"; 385 | INFOPLIST_FILE = "Target Support Files/ForceTouchImageView/Info.plist"; 386 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 387 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 388 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 389 | MODULEMAP_FILE = "Target Support Files/ForceTouchImageView/ForceTouchImageView.modulemap"; 390 | MTL_ENABLE_DEBUG_INFO = NO; 391 | PRODUCT_NAME = ForceTouchImageView; 392 | SDKROOT = iphoneos; 393 | SKIP_INSTALL = YES; 394 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 395 | SWIFT_VERSION = 3.0; 396 | TARGETED_DEVICE_FAMILY = "1,2"; 397 | VERSIONING_SYSTEM = "apple-generic"; 398 | VERSION_INFO_PREFIX = ""; 399 | }; 400 | name = Release; 401 | }; 402 | 42E335F602809E76BDC668B729B8FE6C /* Debug */ = { 403 | isa = XCBuildConfiguration; 404 | baseConfigurationReference = E7C19A318C77B7A39AE2FDA5FE785128 /* ForceTouchImageView.xcconfig */; 405 | buildSettings = { 406 | CODE_SIGN_IDENTITY = ""; 407 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 408 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 409 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 410 | CURRENT_PROJECT_VERSION = 1; 411 | DEBUG_INFORMATION_FORMAT = dwarf; 412 | DEFINES_MODULE = YES; 413 | DYLIB_COMPATIBILITY_VERSION = 1; 414 | DYLIB_CURRENT_VERSION = 1; 415 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 416 | ENABLE_STRICT_OBJC_MSGSEND = YES; 417 | GCC_NO_COMMON_BLOCKS = YES; 418 | GCC_PREFIX_HEADER = "Target Support Files/ForceTouchImageView/ForceTouchImageView-prefix.pch"; 419 | INFOPLIST_FILE = "Target Support Files/ForceTouchImageView/Info.plist"; 420 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 421 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 422 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 423 | MODULEMAP_FILE = "Target Support Files/ForceTouchImageView/ForceTouchImageView.modulemap"; 424 | MTL_ENABLE_DEBUG_INFO = YES; 425 | PRODUCT_NAME = ForceTouchImageView; 426 | SDKROOT = iphoneos; 427 | SKIP_INSTALL = YES; 428 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 429 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 430 | SWIFT_VERSION = 3.0; 431 | TARGETED_DEVICE_FAMILY = "1,2"; 432 | VERSIONING_SYSTEM = "apple-generic"; 433 | VERSION_INFO_PREFIX = ""; 434 | }; 435 | name = Debug; 436 | }; 437 | 707B86CFB21B645E37109F39754D4051 /* Release */ = { 438 | isa = XCBuildConfiguration; 439 | buildSettings = { 440 | ALWAYS_SEARCH_USER_PATHS = NO; 441 | CLANG_ANALYZER_NONNULL = YES; 442 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES; 443 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 444 | CLANG_CXX_LIBRARY = "libc++"; 445 | CLANG_ENABLE_MODULES = YES; 446 | CLANG_ENABLE_OBJC_ARC = YES; 447 | CLANG_WARN_BOOL_CONVERSION = YES; 448 | CLANG_WARN_CONSTANT_CONVERSION = YES; 449 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; 450 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 451 | CLANG_WARN_EMPTY_BODY = YES; 452 | CLANG_WARN_ENUM_CONVERSION = YES; 453 | CLANG_WARN_INFINITE_RECURSION = YES; 454 | CLANG_WARN_INT_CONVERSION = YES; 455 | CLANG_WARN_OBJC_ROOT_CLASS = YES; 456 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 457 | CLANG_WARN_UNREACHABLE_CODE = YES; 458 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 459 | CODE_SIGNING_REQUIRED = NO; 460 | COPY_PHASE_STRIP = YES; 461 | ENABLE_NS_ASSERTIONS = NO; 462 | GCC_C_LANGUAGE_STANDARD = gnu99; 463 | GCC_PREPROCESSOR_DEFINITIONS = ( 464 | "POD_CONFIGURATION_RELEASE=1", 465 | "$(inherited)", 466 | ); 467 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 468 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 469 | GCC_WARN_UNDECLARED_SELECTOR = YES; 470 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 471 | GCC_WARN_UNUSED_FUNCTION = YES; 472 | GCC_WARN_UNUSED_VARIABLE = YES; 473 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 474 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; 475 | STRIP_INSTALLED_PRODUCT = NO; 476 | SYMROOT = "${SRCROOT}/../build"; 477 | VALIDATE_PRODUCT = YES; 478 | }; 479 | name = Release; 480 | }; 481 | E17077673B8736D95AE282B8E0142B4C /* Release */ = { 482 | isa = XCBuildConfiguration; 483 | baseConfigurationReference = D637B077147DFE6FD3016C72BFB15137 /* Pods-ForceTouchImageViewExample.release.xcconfig */; 484 | buildSettings = { 485 | CODE_SIGN_IDENTITY = ""; 486 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 487 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 488 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 489 | CURRENT_PROJECT_VERSION = 1; 490 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 491 | DEFINES_MODULE = YES; 492 | DYLIB_COMPATIBILITY_VERSION = 1; 493 | DYLIB_CURRENT_VERSION = 1; 494 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 495 | ENABLE_STRICT_OBJC_MSGSEND = YES; 496 | GCC_NO_COMMON_BLOCKS = YES; 497 | INFOPLIST_FILE = "Target Support Files/Pods-ForceTouchImageViewExample/Info.plist"; 498 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 499 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 500 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 501 | MACH_O_TYPE = staticlib; 502 | MODULEMAP_FILE = "Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.modulemap"; 503 | MTL_ENABLE_DEBUG_INFO = NO; 504 | OTHER_LDFLAGS = ""; 505 | OTHER_LIBTOOLFLAGS = ""; 506 | PODS_ROOT = "$(SRCROOT)"; 507 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; 508 | PRODUCT_NAME = Pods_ForceTouchImageViewExample; 509 | SDKROOT = iphoneos; 510 | SKIP_INSTALL = YES; 511 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 512 | SWIFT_VERSION = 3.0; 513 | TARGETED_DEVICE_FAMILY = "1,2"; 514 | VERSIONING_SYSTEM = "apple-generic"; 515 | VERSION_INFO_PREFIX = ""; 516 | }; 517 | name = Release; 518 | }; 519 | /* End XCBuildConfiguration section */ 520 | 521 | /* Begin XCConfigurationList section */ 522 | 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */ = { 523 | isa = XCConfigurationList; 524 | buildConfigurations = ( 525 | 163D87BE96A63549B0EACF1CC31A2E90 /* Debug */, 526 | 707B86CFB21B645E37109F39754D4051 /* Release */, 527 | ); 528 | defaultConfigurationIsVisible = 0; 529 | defaultConfigurationName = Release; 530 | }; 531 | AF4ABFCC58C296281FE92AF77662B509 /* Build configuration list for PBXNativeTarget "ForceTouchImageView" */ = { 532 | isa = XCConfigurationList; 533 | buildConfigurations = ( 534 | 42E335F602809E76BDC668B729B8FE6C /* Debug */, 535 | 35BC99495D3E1680BD15521FBE8C71C8 /* Release */, 536 | ); 537 | defaultConfigurationIsVisible = 0; 538 | defaultConfigurationName = Release; 539 | }; 540 | E317E81A0A6C0047D829823D1CD6865C /* Build configuration list for PBXNativeTarget "Pods-ForceTouchImageViewExample" */ = { 541 | isa = XCConfigurationList; 542 | buildConfigurations = ( 543 | 00412E824F0BA4B0A4B08AA796B010E2 /* Debug */, 544 | E17077673B8736D95AE282B8E0142B4C /* Release */, 545 | ); 546 | defaultConfigurationIsVisible = 0; 547 | defaultConfigurationName = Release; 548 | }; 549 | /* End XCConfigurationList section */ 550 | }; 551 | rootObject = D41D8CD98F00B204E9800998ECF8427E /* Project object */; 552 | } 553 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/ForceTouchImageView/ForceTouchImageView-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_ForceTouchImageView : NSObject 3 | @end 4 | @implementation PodsDummy_ForceTouchImageView 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/ForceTouchImageView/ForceTouchImageView-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/Pods/Target Support Files/ForceTouchImageView/ForceTouchImageView-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 ForceTouchImageViewVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char ForceTouchImageViewVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/ForceTouchImageView/ForceTouchImageView.modulemap: -------------------------------------------------------------------------------- 1 | framework module ForceTouchImageView { 2 | umbrella header "ForceTouchImageView-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/ForceTouchImageView/ForceTouchImageView.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/ForceTouchImageView 2 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 3 | HEADER_SEARCH_PATHS = "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Public" 4 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 5 | PODS_BUILD_DIR = $BUILD_DIR 6 | PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 7 | PODS_ROOT = ${SRCROOT} 8 | PODS_TARGET_SRCROOT = ${PODS_ROOT}/ForceTouchImageView 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | SWIFT_VERSION = 3.0 12 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/ForceTouchImageView/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-ForceTouchImageViewExample/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-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## ForceTouchImageView 5 | 6 | MIT License 7 | 8 | Copyright (c) 2017 Omar Albeik 9 | 10 | Permission is hereby granted, free of charge, to any person obtaining a copy 11 | of this software and associated documentation files (the "Software"), to deal 12 | in the Software without restriction, including without limitation the rights 13 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 14 | copies of the Software, and to permit persons to whom the Software is 15 | furnished to do so, subject to the following conditions: 16 | 17 | The above copyright notice and this permission notice shall be included in all 18 | copies or substantial portions of the Software. 19 | 20 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 21 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 22 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 23 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 24 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 25 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 26 | SOFTWARE. 27 | 28 | Generated by CocoaPods - https://cocoapods.org 29 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-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 | MIT License 18 | 19 | Copyright (c) 2017 Omar Albeik 20 | 21 | Permission is hereby granted, free of charge, to any person obtaining a copy 22 | of this software and associated documentation files (the "Software"), to deal 23 | in the Software without restriction, including without limitation the rights 24 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 25 | copies of the Software, and to permit persons to whom the Software is 26 | furnished to do so, subject to the following conditions: 27 | 28 | The above copyright notice and this permission notice shall be included in all 29 | copies or substantial portions of the Software. 30 | 31 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 32 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 33 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 34 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 35 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 36 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 37 | SOFTWARE. 38 | 39 | License 40 | MIT 41 | Title 42 | ForceTouchImageView 43 | Type 44 | PSGroupSpecifier 45 | 46 | 47 | FooterText 48 | Generated by CocoaPods - https://cocoapods.org 49 | Title 50 | 51 | Type 52 | PSGroupSpecifier 53 | 54 | 55 | StringsTable 56 | Acknowledgements 57 | Title 58 | Acknowledgements 59 | 60 | 61 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_ForceTouchImageViewExample : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_ForceTouchImageViewExample 5 | @end 6 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-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 | install_framework() 10 | { 11 | if [ -r "${BUILT_PRODUCTS_DIR}/$1" ]; then 12 | local source="${BUILT_PRODUCTS_DIR}/$1" 13 | elif [ -r "${BUILT_PRODUCTS_DIR}/$(basename "$1")" ]; then 14 | local source="${BUILT_PRODUCTS_DIR}/$(basename "$1")" 15 | elif [ -r "$1" ]; then 16 | local source="$1" 17 | fi 18 | 19 | local destination="${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 20 | 21 | if [ -L "${source}" ]; then 22 | echo "Symlinked..." 23 | source="$(readlink "${source}")" 24 | fi 25 | 26 | # use filter instead of exclude so missing patterns dont' throw errors 27 | echo "rsync -av --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" --filter \"- Headers\" --filter \"- PrivateHeaders\" --filter \"- Modules\" \"${source}\" \"${destination}\"" 28 | rsync -av --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules" "${source}" "${destination}" 29 | 30 | local basename 31 | basename="$(basename -s .framework "$1")" 32 | binary="${destination}/${basename}.framework/${basename}" 33 | if ! [ -r "$binary" ]; then 34 | binary="${destination}/${basename}" 35 | fi 36 | 37 | # Strip invalid architectures so "fat" simulator / device frameworks work on device 38 | if [[ "$(file "$binary")" == *"dynamically linked shared library"* ]]; then 39 | strip_invalid_archs "$binary" 40 | fi 41 | 42 | # Resign the code if required by the build settings to avoid unstable apps 43 | code_sign_if_enabled "${destination}/$(basename "$1")" 44 | 45 | # Embed linked Swift runtime libraries. No longer necessary as of Xcode 7. 46 | if [ "${XCODE_VERSION_MAJOR}" -lt 7 ]; then 47 | local swift_runtime_libs 48 | swift_runtime_libs=$(xcrun otool -LX "$binary" | grep --color=never @rpath/libswift | sed -E s/@rpath\\/\(.+dylib\).*/\\1/g | uniq -u && exit ${PIPESTATUS[0]}) 49 | for lib in $swift_runtime_libs; do 50 | echo "rsync -auv \"${SWIFT_STDLIB_PATH}/${lib}\" \"${destination}\"" 51 | rsync -auv "${SWIFT_STDLIB_PATH}/${lib}" "${destination}" 52 | code_sign_if_enabled "${destination}/${lib}" 53 | done 54 | fi 55 | } 56 | 57 | # Signs a framework with the provided identity 58 | code_sign_if_enabled() { 59 | if [ -n "${EXPANDED_CODE_SIGN_IDENTITY}" -a "${CODE_SIGNING_REQUIRED}" != "NO" -a "${CODE_SIGNING_ALLOWED}" != "NO" ]; then 60 | # Use the current code_sign_identitiy 61 | echo "Code Signing $1 with Identity ${EXPANDED_CODE_SIGN_IDENTITY_NAME}" 62 | local code_sign_cmd="/usr/bin/codesign --force --sign ${EXPANDED_CODE_SIGN_IDENTITY} ${OTHER_CODE_SIGN_FLAGS} --preserve-metadata=identifier,entitlements '$1'" 63 | 64 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 65 | code_sign_cmd="$code_sign_cmd &" 66 | fi 67 | echo "$code_sign_cmd" 68 | eval "$code_sign_cmd" 69 | fi 70 | } 71 | 72 | # Strip invalid architectures 73 | strip_invalid_archs() { 74 | binary="$1" 75 | # Get architectures for current file 76 | archs="$(lipo -info "$binary" | rev | cut -d ':' -f1 | rev)" 77 | stripped="" 78 | for arch in $archs; do 79 | if ! [[ "${VALID_ARCHS}" == *"$arch"* ]]; then 80 | # Strip non-valid architectures in-place 81 | lipo -remove "$arch" -output "$binary" "$binary" || exit 1 82 | stripped="$stripped $arch" 83 | fi 84 | done 85 | if [[ "$stripped" ]]; then 86 | echo "Stripped $binary of architectures:$stripped" 87 | fi 88 | } 89 | 90 | 91 | if [[ "$CONFIGURATION" == "Debug" ]]; then 92 | install_framework "$BUILT_PRODUCTS_DIR/ForceTouchImageView/ForceTouchImageView.framework" 93 | fi 94 | if [[ "$CONFIGURATION" == "Release" ]]; then 95 | install_framework "$BUILT_PRODUCTS_DIR/ForceTouchImageView/ForceTouchImageView.framework" 96 | fi 97 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 98 | wait 99 | fi 100 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-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 | case "${TARGETED_DEVICE_FAMILY}" in 12 | 1,2) 13 | TARGET_DEVICE_ARGS="--target-device ipad --target-device iphone" 14 | ;; 15 | 1) 16 | TARGET_DEVICE_ARGS="--target-device iphone" 17 | ;; 18 | 2) 19 | TARGET_DEVICE_ARGS="--target-device ipad" 20 | ;; 21 | 3) 22 | TARGET_DEVICE_ARGS="--target-device tv" 23 | ;; 24 | *) 25 | TARGET_DEVICE_ARGS="--target-device mac" 26 | ;; 27 | esac 28 | 29 | install_resource() 30 | { 31 | if [[ "$1" = /* ]] ; then 32 | RESOURCE_PATH="$1" 33 | else 34 | RESOURCE_PATH="${PODS_ROOT}/$1" 35 | fi 36 | if [[ ! -e "$RESOURCE_PATH" ]] ; then 37 | cat << EOM 38 | error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. 39 | EOM 40 | exit 1 41 | fi 42 | case $RESOURCE_PATH in 43 | *.storyboard) 44 | 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}" 45 | 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} 46 | ;; 47 | *.xib) 48 | 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}" 49 | 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} 50 | ;; 51 | *.framework) 52 | echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 53 | mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 54 | echo "rsync -av $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 55 | rsync -av "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 56 | ;; 57 | *.xcdatamodel) 58 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" 59 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" 60 | ;; 61 | *.xcdatamodeld) 62 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" 63 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" 64 | ;; 65 | *.xcmappingmodel) 66 | echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" 67 | xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" 68 | ;; 69 | *.xcassets) 70 | ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" 71 | XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") 72 | ;; 73 | *) 74 | echo "$RESOURCE_PATH" 75 | echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" 76 | ;; 77 | esac 78 | } 79 | 80 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 81 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 82 | if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then 83 | mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 84 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 85 | fi 86 | rm -f "$RESOURCES_TO_COPY" 87 | 88 | if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ] 89 | then 90 | # Find all other xcassets (this unfortunately includes those of path pods and other targets). 91 | OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) 92 | while read line; do 93 | if [[ $line != "${PODS_ROOT}*" ]]; then 94 | XCASSET_FILES+=("$line") 95 | fi 96 | done <<<"$OTHER_XCASSETS" 97 | 98 | 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}" 99 | fi 100 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample-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_ForceTouchImageViewExampleVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char Pods_ForceTouchImageViewExampleVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.debug.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/ForceTouchImageView" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 5 | OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/ForceTouchImageView/ForceTouchImageView.framework/Headers" 6 | OTHER_LDFLAGS = $(inherited) -framework "ForceTouchImageView" 7 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 8 | PODS_BUILD_DIR = $BUILD_DIR 9 | PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_ROOT = ${SRCROOT}/Pods 11 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_ForceTouchImageViewExample { 2 | umbrella header "Pods-ForceTouchImageViewExample-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /Example/Pods/Target Support Files/Pods-ForceTouchImageViewExample/Pods-ForceTouchImageViewExample.release.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/ForceTouchImageView" 3 | GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1 4 | LD_RUNPATH_SEARCH_PATHS = $(inherited) '@executable_path/Frameworks' '@loader_path/Frameworks' 5 | OTHER_CFLAGS = $(inherited) -iquote "$PODS_CONFIGURATION_BUILD_DIR/ForceTouchImageView/ForceTouchImageView.framework/Headers" 6 | OTHER_LDFLAGS = $(inherited) -framework "ForceTouchImageView" 7 | OTHER_SWIFT_FLAGS = $(inherited) "-D" "COCOAPODS" 8 | PODS_BUILD_DIR = $BUILD_DIR 9 | PODS_CONFIGURATION_BUILD_DIR = $PODS_BUILD_DIR/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME) 10 | PODS_ROOT = ${SRCROOT}/Pods 11 | -------------------------------------------------------------------------------- /ForceTouchImageView.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | s.name = "ForceTouchImageView" 3 | s.version = "0.2" 4 | s.summary = "Why pinch to zoom when you have 3D Touch 🤔" 5 | s.description = "A tiny open source library to supoort zooming in UIScrollView using Force Touch" 6 | s.homepage = "https://github.com/omaralbeik/ForceTouchImageView" 7 | s.license = { type: 'MIT', file: 'LICENSE' } 8 | s.authors = { "Omar Albeik" => 'omaralbeik@gmail.com' } 9 | s.social_media_url = "http://twitter.com/omaralbeik" 10 | s.ios.deployment_target = '9.0' 11 | s.requires_arc = true 12 | s.source = { git: "https://github.com/omaralbeik/ForceTouchImageView.git", tag: "#{s.version}" } 13 | s.source_files = "Source/**/*.swift" 14 | s.pod_target_xcconfig = { 15 | 'SWIFT_VERSION' => '3.0', 16 | } 17 | end 18 | -------------------------------------------------------------------------------- /ForceTouchImageView.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 07A8C7741E9B1B190056B19A /* ForceTouchImageView.h in Headers */ = {isa = PBXBuildFile; fileRef = 07A8C7711E9B1B190056B19A /* ForceTouchImageView.h */; settings = {ATTRIBUTES = (Public, ); }; }; 11 | 07A8C7751E9B1B190056B19A /* ForceTouchImageView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 07A8C7721E9B1B190056B19A /* ForceTouchImageView.swift */; }; 12 | 07EEB5401E9C968800E8536C /* ForceTouchImageViewTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 07EEB53F1E9C968800E8536C /* ForceTouchImageViewTests.swift */; }; 13 | 07EEB5421E9C968800E8536C /* ForceTouchImageView.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 07A8C7641E9B1A880056B19A /* ForceTouchImageView.framework */; }; 14 | /* End PBXBuildFile section */ 15 | 16 | /* Begin PBXContainerItemProxy section */ 17 | 07EEB5431E9C968800E8536C /* PBXContainerItemProxy */ = { 18 | isa = PBXContainerItemProxy; 19 | containerPortal = 07A8C75B1E9B1A880056B19A /* Project object */; 20 | proxyType = 1; 21 | remoteGlobalIDString = 07A8C7631E9B1A880056B19A; 22 | remoteInfo = ForceTouchImageView; 23 | }; 24 | /* End PBXContainerItemProxy section */ 25 | 26 | /* Begin PBXFileReference section */ 27 | 07A8C7641E9B1A880056B19A /* ForceTouchImageView.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = ForceTouchImageView.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 28 | 07A8C7711E9B1B190056B19A /* ForceTouchImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ForceTouchImageView.h; path = Source/ForceTouchImageView.h; sourceTree = SOURCE_ROOT; }; 29 | 07A8C7721E9B1B190056B19A /* ForceTouchImageView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = ForceTouchImageView.swift; path = Source/ForceTouchImageView.swift; sourceTree = SOURCE_ROOT; }; 30 | 07A8C7731E9B1B190056B19A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = Source/Info.plist; sourceTree = SOURCE_ROOT; }; 31 | 07EEB53D1E9C968800E8536C /* ForceTouchImageViewTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ForceTouchImageViewTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 32 | 07EEB53F1E9C968800E8536C /* ForceTouchImageViewTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ForceTouchImageViewTests.swift; sourceTree = ""; }; 33 | 07EEB5411E9C968800E8536C /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 34 | /* End PBXFileReference section */ 35 | 36 | /* Begin PBXFrameworksBuildPhase section */ 37 | 07A8C7601E9B1A880056B19A /* Frameworks */ = { 38 | isa = PBXFrameworksBuildPhase; 39 | buildActionMask = 2147483647; 40 | files = ( 41 | ); 42 | runOnlyForDeploymentPostprocessing = 0; 43 | }; 44 | 07EEB53A1E9C968800E8536C /* Frameworks */ = { 45 | isa = PBXFrameworksBuildPhase; 46 | buildActionMask = 2147483647; 47 | files = ( 48 | 07EEB5421E9C968800E8536C /* ForceTouchImageView.framework in Frameworks */, 49 | ); 50 | runOnlyForDeploymentPostprocessing = 0; 51 | }; 52 | /* End PBXFrameworksBuildPhase section */ 53 | 54 | /* Begin PBXGroup section */ 55 | 07A8C75A1E9B1A880056B19A = { 56 | isa = PBXGroup; 57 | children = ( 58 | 07A8C7661E9B1A880056B19A /* ForceTouchImageView */, 59 | 07EEB53E1E9C968800E8536C /* ForceTouchImageViewTests */, 60 | 07A8C7651E9B1A880056B19A /* Products */, 61 | ); 62 | sourceTree = ""; 63 | }; 64 | 07A8C7651E9B1A880056B19A /* Products */ = { 65 | isa = PBXGroup; 66 | children = ( 67 | 07A8C7641E9B1A880056B19A /* ForceTouchImageView.framework */, 68 | 07EEB53D1E9C968800E8536C /* ForceTouchImageViewTests.xctest */, 69 | ); 70 | name = Products; 71 | sourceTree = ""; 72 | }; 73 | 07A8C7661E9B1A880056B19A /* ForceTouchImageView */ = { 74 | isa = PBXGroup; 75 | children = ( 76 | 07A8C7711E9B1B190056B19A /* ForceTouchImageView.h */, 77 | 07A8C7721E9B1B190056B19A /* ForceTouchImageView.swift */, 78 | 07A8C7731E9B1B190056B19A /* Info.plist */, 79 | ); 80 | path = ForceTouchImageView; 81 | sourceTree = ""; 82 | }; 83 | 07EEB53E1E9C968800E8536C /* ForceTouchImageViewTests */ = { 84 | isa = PBXGroup; 85 | children = ( 86 | 07EEB53F1E9C968800E8536C /* ForceTouchImageViewTests.swift */, 87 | 07EEB5411E9C968800E8536C /* Info.plist */, 88 | ); 89 | path = ForceTouchImageViewTests; 90 | sourceTree = ""; 91 | }; 92 | /* End PBXGroup section */ 93 | 94 | /* Begin PBXHeadersBuildPhase section */ 95 | 07A8C7611E9B1A880056B19A /* Headers */ = { 96 | isa = PBXHeadersBuildPhase; 97 | buildActionMask = 2147483647; 98 | files = ( 99 | 07A8C7741E9B1B190056B19A /* ForceTouchImageView.h in Headers */, 100 | ); 101 | runOnlyForDeploymentPostprocessing = 0; 102 | }; 103 | /* End PBXHeadersBuildPhase section */ 104 | 105 | /* Begin PBXNativeTarget section */ 106 | 07A8C7631E9B1A880056B19A /* ForceTouchImageView */ = { 107 | isa = PBXNativeTarget; 108 | buildConfigurationList = 07A8C76C1E9B1A880056B19A /* Build configuration list for PBXNativeTarget "ForceTouchImageView" */; 109 | buildPhases = ( 110 | 07A8C75F1E9B1A880056B19A /* Sources */, 111 | 07A8C7601E9B1A880056B19A /* Frameworks */, 112 | 07A8C7611E9B1A880056B19A /* Headers */, 113 | 07A8C7621E9B1A880056B19A /* Resources */, 114 | ); 115 | buildRules = ( 116 | ); 117 | dependencies = ( 118 | ); 119 | name = ForceTouchImageView; 120 | productName = ForceTouchImageView; 121 | productReference = 07A8C7641E9B1A880056B19A /* ForceTouchImageView.framework */; 122 | productType = "com.apple.product-type.framework"; 123 | }; 124 | 07EEB53C1E9C968800E8536C /* ForceTouchImageViewTests */ = { 125 | isa = PBXNativeTarget; 126 | buildConfigurationList = 07EEB5451E9C968800E8536C /* Build configuration list for PBXNativeTarget "ForceTouchImageViewTests" */; 127 | buildPhases = ( 128 | 07EEB5391E9C968800E8536C /* Sources */, 129 | 07EEB53A1E9C968800E8536C /* Frameworks */, 130 | 07EEB53B1E9C968800E8536C /* Resources */, 131 | ); 132 | buildRules = ( 133 | ); 134 | dependencies = ( 135 | 07EEB5441E9C968800E8536C /* PBXTargetDependency */, 136 | ); 137 | name = ForceTouchImageViewTests; 138 | productName = ForceTouchImageViewTests; 139 | productReference = 07EEB53D1E9C968800E8536C /* ForceTouchImageViewTests.xctest */; 140 | productType = "com.apple.product-type.bundle.unit-test"; 141 | }; 142 | /* End PBXNativeTarget section */ 143 | 144 | /* Begin PBXProject section */ 145 | 07A8C75B1E9B1A880056B19A /* Project object */ = { 146 | isa = PBXProject; 147 | attributes = { 148 | LastSwiftUpdateCheck = 0830; 149 | LastUpgradeCheck = 0830; 150 | ORGANIZATIONNAME = "Omar Albeik"; 151 | TargetAttributes = { 152 | 07A8C7631E9B1A880056B19A = { 153 | CreatedOnToolsVersion = 8.3.1; 154 | DevelopmentTeam = C3VKVFB3SA; 155 | LastSwiftMigration = 0830; 156 | ProvisioningStyle = Automatic; 157 | }; 158 | 07EEB53C1E9C968800E8536C = { 159 | CreatedOnToolsVersion = 8.3.1; 160 | DevelopmentTeam = C3VKVFB3SA; 161 | ProvisioningStyle = Automatic; 162 | }; 163 | }; 164 | }; 165 | buildConfigurationList = 07A8C75E1E9B1A880056B19A /* Build configuration list for PBXProject "ForceTouchImageView" */; 166 | compatibilityVersion = "Xcode 3.2"; 167 | developmentRegion = English; 168 | hasScannedForEncodings = 0; 169 | knownRegions = ( 170 | en, 171 | ); 172 | mainGroup = 07A8C75A1E9B1A880056B19A; 173 | productRefGroup = 07A8C7651E9B1A880056B19A /* Products */; 174 | projectDirPath = ""; 175 | projectRoot = ""; 176 | targets = ( 177 | 07A8C7631E9B1A880056B19A /* ForceTouchImageView */, 178 | 07EEB53C1E9C968800E8536C /* ForceTouchImageViewTests */, 179 | ); 180 | }; 181 | /* End PBXProject section */ 182 | 183 | /* Begin PBXResourcesBuildPhase section */ 184 | 07A8C7621E9B1A880056B19A /* Resources */ = { 185 | isa = PBXResourcesBuildPhase; 186 | buildActionMask = 2147483647; 187 | files = ( 188 | ); 189 | runOnlyForDeploymentPostprocessing = 0; 190 | }; 191 | 07EEB53B1E9C968800E8536C /* Resources */ = { 192 | isa = PBXResourcesBuildPhase; 193 | buildActionMask = 2147483647; 194 | files = ( 195 | ); 196 | runOnlyForDeploymentPostprocessing = 0; 197 | }; 198 | /* End PBXResourcesBuildPhase section */ 199 | 200 | /* Begin PBXSourcesBuildPhase section */ 201 | 07A8C75F1E9B1A880056B19A /* Sources */ = { 202 | isa = PBXSourcesBuildPhase; 203 | buildActionMask = 2147483647; 204 | files = ( 205 | 07A8C7751E9B1B190056B19A /* ForceTouchImageView.swift in Sources */, 206 | ); 207 | runOnlyForDeploymentPostprocessing = 0; 208 | }; 209 | 07EEB5391E9C968800E8536C /* Sources */ = { 210 | isa = PBXSourcesBuildPhase; 211 | buildActionMask = 2147483647; 212 | files = ( 213 | 07EEB5401E9C968800E8536C /* ForceTouchImageViewTests.swift in Sources */, 214 | ); 215 | runOnlyForDeploymentPostprocessing = 0; 216 | }; 217 | /* End PBXSourcesBuildPhase section */ 218 | 219 | /* Begin PBXTargetDependency section */ 220 | 07EEB5441E9C968800E8536C /* PBXTargetDependency */ = { 221 | isa = PBXTargetDependency; 222 | target = 07A8C7631E9B1A880056B19A /* ForceTouchImageView */; 223 | targetProxy = 07EEB5431E9C968800E8536C /* PBXContainerItemProxy */; 224 | }; 225 | /* End PBXTargetDependency section */ 226 | 227 | /* Begin XCBuildConfiguration section */ 228 | 07A8C76A1E9B1A880056B19A /* Debug */ = { 229 | isa = XCBuildConfiguration; 230 | buildSettings = { 231 | ALWAYS_SEARCH_USER_PATHS = NO; 232 | CLANG_ANALYZER_NONNULL = YES; 233 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 234 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 235 | CLANG_CXX_LIBRARY = "libc++"; 236 | CLANG_ENABLE_MODULES = YES; 237 | CLANG_ENABLE_OBJC_ARC = YES; 238 | CLANG_WARN_BOOL_CONVERSION = YES; 239 | CLANG_WARN_CONSTANT_CONVERSION = YES; 240 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 241 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 242 | CLANG_WARN_EMPTY_BODY = YES; 243 | CLANG_WARN_ENUM_CONVERSION = YES; 244 | CLANG_WARN_INFINITE_RECURSION = YES; 245 | CLANG_WARN_INT_CONVERSION = YES; 246 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 247 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 248 | CLANG_WARN_UNREACHABLE_CODE = YES; 249 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 250 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 251 | COPY_PHASE_STRIP = NO; 252 | CURRENT_PROJECT_VERSION = 1; 253 | DEBUG_INFORMATION_FORMAT = dwarf; 254 | ENABLE_STRICT_OBJC_MSGSEND = YES; 255 | ENABLE_TESTABILITY = YES; 256 | GCC_C_LANGUAGE_STANDARD = gnu99; 257 | GCC_DYNAMIC_NO_PIC = NO; 258 | GCC_NO_COMMON_BLOCKS = YES; 259 | GCC_OPTIMIZATION_LEVEL = 0; 260 | GCC_PREPROCESSOR_DEFINITIONS = ( 261 | "DEBUG=1", 262 | "$(inherited)", 263 | ); 264 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 265 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 266 | GCC_WARN_UNDECLARED_SELECTOR = YES; 267 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 268 | GCC_WARN_UNUSED_FUNCTION = YES; 269 | GCC_WARN_UNUSED_VARIABLE = YES; 270 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 271 | MTL_ENABLE_DEBUG_INFO = YES; 272 | ONLY_ACTIVE_ARCH = YES; 273 | SDKROOT = iphoneos; 274 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 275 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 276 | TARGETED_DEVICE_FAMILY = "1,2"; 277 | VERSIONING_SYSTEM = "apple-generic"; 278 | VERSION_INFO_PREFIX = ""; 279 | }; 280 | name = Debug; 281 | }; 282 | 07A8C76B1E9B1A880056B19A /* Release */ = { 283 | isa = XCBuildConfiguration; 284 | buildSettings = { 285 | ALWAYS_SEARCH_USER_PATHS = NO; 286 | CLANG_ANALYZER_NONNULL = YES; 287 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 288 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 289 | CLANG_CXX_LIBRARY = "libc++"; 290 | CLANG_ENABLE_MODULES = YES; 291 | CLANG_ENABLE_OBJC_ARC = YES; 292 | CLANG_WARN_BOOL_CONVERSION = YES; 293 | CLANG_WARN_CONSTANT_CONVERSION = YES; 294 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 295 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 296 | CLANG_WARN_EMPTY_BODY = YES; 297 | CLANG_WARN_ENUM_CONVERSION = YES; 298 | CLANG_WARN_INFINITE_RECURSION = YES; 299 | CLANG_WARN_INT_CONVERSION = YES; 300 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 301 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 302 | CLANG_WARN_UNREACHABLE_CODE = YES; 303 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 304 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 305 | COPY_PHASE_STRIP = NO; 306 | CURRENT_PROJECT_VERSION = 1; 307 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 308 | ENABLE_NS_ASSERTIONS = NO; 309 | ENABLE_STRICT_OBJC_MSGSEND = YES; 310 | GCC_C_LANGUAGE_STANDARD = gnu99; 311 | GCC_NO_COMMON_BLOCKS = YES; 312 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 313 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 314 | GCC_WARN_UNDECLARED_SELECTOR = YES; 315 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 316 | GCC_WARN_UNUSED_FUNCTION = YES; 317 | GCC_WARN_UNUSED_VARIABLE = YES; 318 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 319 | MTL_ENABLE_DEBUG_INFO = NO; 320 | SDKROOT = iphoneos; 321 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 322 | TARGETED_DEVICE_FAMILY = "1,2"; 323 | VALIDATE_PRODUCT = YES; 324 | VERSIONING_SYSTEM = "apple-generic"; 325 | VERSION_INFO_PREFIX = ""; 326 | }; 327 | name = Release; 328 | }; 329 | 07A8C76D1E9B1A880056B19A /* Debug */ = { 330 | isa = XCBuildConfiguration; 331 | buildSettings = { 332 | CLANG_ENABLE_MODULES = YES; 333 | CODE_SIGN_IDENTITY = ""; 334 | DEFINES_MODULE = YES; 335 | DEVELOPMENT_TEAM = C3VKVFB3SA; 336 | DYLIB_COMPATIBILITY_VERSION = 1; 337 | DYLIB_CURRENT_VERSION = 1; 338 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 339 | INFOPLIST_FILE = "$(SRCROOT)/Source/Info.plist"; 340 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 341 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 342 | PRODUCT_BUNDLE_IDENTIFIER = com.omaralbeik.ForceTouchImageView; 343 | PRODUCT_NAME = "$(TARGET_NAME)"; 344 | SKIP_INSTALL = YES; 345 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 346 | SWIFT_VERSION = 3.0; 347 | }; 348 | name = Debug; 349 | }; 350 | 07A8C76E1E9B1A880056B19A /* Release */ = { 351 | isa = XCBuildConfiguration; 352 | buildSettings = { 353 | CLANG_ENABLE_MODULES = YES; 354 | CODE_SIGN_IDENTITY = ""; 355 | DEFINES_MODULE = YES; 356 | DEVELOPMENT_TEAM = C3VKVFB3SA; 357 | DYLIB_COMPATIBILITY_VERSION = 1; 358 | DYLIB_CURRENT_VERSION = 1; 359 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 360 | INFOPLIST_FILE = "$(SRCROOT)/Source/Info.plist"; 361 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 362 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 363 | PRODUCT_BUNDLE_IDENTIFIER = com.omaralbeik.ForceTouchImageView; 364 | PRODUCT_NAME = "$(TARGET_NAME)"; 365 | SKIP_INSTALL = YES; 366 | SWIFT_VERSION = 3.0; 367 | }; 368 | name = Release; 369 | }; 370 | 07EEB5461E9C968800E8536C /* Debug */ = { 371 | isa = XCBuildConfiguration; 372 | buildSettings = { 373 | DEVELOPMENT_TEAM = C3VKVFB3SA; 374 | INFOPLIST_FILE = ForceTouchImageViewTests/Info.plist; 375 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 376 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 377 | PRODUCT_BUNDLE_IDENTIFIER = com.omaralbeik.ForceTouchImageViewTests; 378 | PRODUCT_NAME = "$(TARGET_NAME)"; 379 | SWIFT_VERSION = 3.0; 380 | }; 381 | name = Debug; 382 | }; 383 | 07EEB5471E9C968800E8536C /* Release */ = { 384 | isa = XCBuildConfiguration; 385 | buildSettings = { 386 | DEVELOPMENT_TEAM = C3VKVFB3SA; 387 | INFOPLIST_FILE = ForceTouchImageViewTests/Info.plist; 388 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 389 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 390 | PRODUCT_BUNDLE_IDENTIFIER = com.omaralbeik.ForceTouchImageViewTests; 391 | PRODUCT_NAME = "$(TARGET_NAME)"; 392 | SWIFT_VERSION = 3.0; 393 | }; 394 | name = Release; 395 | }; 396 | /* End XCBuildConfiguration section */ 397 | 398 | /* Begin XCConfigurationList section */ 399 | 07A8C75E1E9B1A880056B19A /* Build configuration list for PBXProject "ForceTouchImageView" */ = { 400 | isa = XCConfigurationList; 401 | buildConfigurations = ( 402 | 07A8C76A1E9B1A880056B19A /* Debug */, 403 | 07A8C76B1E9B1A880056B19A /* Release */, 404 | ); 405 | defaultConfigurationIsVisible = 0; 406 | defaultConfigurationName = Release; 407 | }; 408 | 07A8C76C1E9B1A880056B19A /* Build configuration list for PBXNativeTarget "ForceTouchImageView" */ = { 409 | isa = XCConfigurationList; 410 | buildConfigurations = ( 411 | 07A8C76D1E9B1A880056B19A /* Debug */, 412 | 07A8C76E1E9B1A880056B19A /* Release */, 413 | ); 414 | defaultConfigurationIsVisible = 0; 415 | defaultConfigurationName = Release; 416 | }; 417 | 07EEB5451E9C968800E8536C /* Build configuration list for PBXNativeTarget "ForceTouchImageViewTests" */ = { 418 | isa = XCConfigurationList; 419 | buildConfigurations = ( 420 | 07EEB5461E9C968800E8536C /* Debug */, 421 | 07EEB5471E9C968800E8536C /* Release */, 422 | ); 423 | defaultConfigurationIsVisible = 0; 424 | defaultConfigurationName = Release; 425 | }; 426 | /* End XCConfigurationList section */ 427 | }; 428 | rootObject = 07A8C75B1E9B1A880056B19A /* Project object */; 429 | } 430 | -------------------------------------------------------------------------------- /ForceTouchImageView.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ForceTouchImageView.xcodeproj/xcshareddata/xcschemes/ForceTouchImageView.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 | 65 | 71 | 72 | 73 | 74 | 75 | 76 | 82 | 83 | 89 | 90 | 91 | 92 | 94 | 95 | 98 | 99 | 100 | -------------------------------------------------------------------------------- /ForceTouchImageView.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ForceTouchImageViewTests/ForceTouchImageViewTests.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ForceTouchImageViewTests.swift 3 | // ForceTouchImageViewTests 4 | // 5 | // Created by Omar Albeik on 4/10/17. 6 | // Copyright © 2017 Omar Albeik. All rights reserved. 7 | // 8 | 9 | import XCTest 10 | 11 | class ForceTouchImageViewTests: XCTestCase { 12 | 13 | override func setUp() { 14 | super.setUp() 15 | // Put setup code here. This method is called before the invocation of each test method in the class. 16 | } 17 | 18 | override func tearDown() { 19 | // Put teardown code here. This method is called after the invocation of each test method in the class. 20 | super.tearDown() 21 | } 22 | 23 | func testExample() { 24 | // This is an example of a functional test case. 25 | // Use XCTAssert and related functions to verify your tests produce the correct results. 26 | } 27 | 28 | func testPerformanceExample() { 29 | // This is an example of a performance test case. 30 | self.measure { 31 | // Put the code you want to measure the time of here. 32 | } 33 | } 34 | 35 | } 36 | -------------------------------------------------------------------------------- /ForceTouchImageViewTests/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 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | 22 | 23 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Omar Albeik 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 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ForceTouchImageView 2 | Why pinch to zoom when your have 3D Touch 🤔 3 | 4 | 5 | [![Build Status](https://api.travis-ci.org/omaralbeik/ForceTouchImageView.svg?branch=master)](https://travis-ci.org/omaralbeik/ForceTouchImageView) 6 | [![Cocoapods](https://img.shields.io/cocoapods/v/ForceTouchImageView.svg)](https://cocoapods.org/pods/ForceTouchImageView) 7 | [![Platform](https://img.shields.io/cocoapods/p/ForceTouchImageView.svg?style=flat)](https://github.com/omaralbeik/ForceTouchImageView) 8 | [![Swift](https://img.shields.io/badge/Swift-3.1-orange.svg)](https://swift.org) 9 | [![Xcode](https://img.shields.io/badge/Xcode-8.3-blue.svg)](https://developer.apple.com/xcode) 10 | [![MIT](https://img.shields.io/badge/License-MIT-red.svg)](https://opensource.org/licenses/MIT) 11 | 12 | 13 | # Requirements: 14 | - **iOS** 9.0+ 15 | - **Xcode** 8.0+ 16 | - **Swift** 3.0+ 17 | 18 | 19 | # Installation 20 | 21 | ### CocoaPods 22 | 23 | [CocoaPods](http://cocoapods.org) is a dependency manager for Cocoa projects. You can install it with the following command: 24 | 25 | ```bash 26 | $ gem install cocoapods 27 | ``` 28 | 29 | To integrate ForceTouchImageView into your Xcode project using CocoaPods, specify it in your `Podfile`: 30 | 31 | ```ruby 32 | source 'https://github.com/CocoaPods/Specs.git' 33 | platform :ios, '9.0' 34 | use_frameworks! 35 | 36 | target '' do 37 | pod 'ForceTouchImageView' 38 | end 39 | ``` 40 | 41 | Then, run the following command: 42 | 43 | ```bash 44 | $ pod install 45 | ``` 46 | 47 | 48 | ### Manually 49 | 50 | Add the [ForceTouchImageView](https://github.com/omaralbeik/ForceTouchImageView/blob/master/Source/ForceTouchImageView.swift) file to your Xcode project. 51 | -------------------------------------------------------------------------------- /Source/ForceTouchImageView.h: -------------------------------------------------------------------------------- 1 | // 2 | // ForceTouchImageView.h 3 | // ForceTouchImageView 4 | // 5 | // Created by Omar Albeik on 4/9/17. 6 | // Copyright © 2017 Omar Albeik. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | //! Project version number for ForceTouchImageView. 12 | FOUNDATION_EXPORT double ForceTouchImageViewVersionNumber; 13 | 14 | //! Project version string for ForceTouchImageView. 15 | FOUNDATION_EXPORT const unsigned char ForceTouchImageViewVersionString[]; 16 | 17 | // In this header, you should import all the public headers of your framework using statements like #import 18 | 19 | 20 | -------------------------------------------------------------------------------- /Source/ForceTouchImageView.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ForceTouchImageView.swift 3 | // ForceTouchImageView 4 | // 5 | // Created by Omar Albeik on 4/9/17. 6 | // Copyright © 2017 Omar Albeik. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | 11 | public protocol ForceTouchImageViewDelegate: class { 12 | func forceTouchImageView(_ view: ForceTouchImageView, touchForceDidChange force: CGFloat) 13 | } 14 | 15 | extension ForceTouchImageViewDelegate { 16 | func forceTouchImageView(_ view: ForceTouchImageView, touchForceDidChange force: CGFloat) {} 17 | } 18 | 19 | 20 | @IBDesignable 21 | public class ForceTouchImageView: UIScrollView { 22 | 23 | public weak var forceTouchDelegate: ForceTouchImageViewDelegate? 24 | public var maximumPossibleForce: CGFloat = 0 25 | 26 | 27 | fileprivate var imageView: UIImageView! 28 | 29 | override init(frame: CGRect) { 30 | super.init(frame: frame) 31 | setupView() 32 | 33 | } 34 | 35 | required public init?(coder aDecoder: NSCoder) { 36 | super.init(coder: aDecoder) 37 | setupView() 38 | } 39 | 40 | @IBInspectable 41 | public var image: UIImage? { 42 | get { 43 | return imageView.image 44 | } 45 | set { 46 | imageView.image = newValue 47 | } 48 | } 49 | 50 | @IBInspectable 51 | public var highlightedImage: UIImage? { 52 | get { 53 | return imageView.highlightedImage 54 | } 55 | set { 56 | imageView.highlightedImage = newValue 57 | } 58 | } 59 | 60 | } 61 | 62 | 63 | // MARK: - Touch methdos 64 | public extension ForceTouchImageView { 65 | 66 | override func touchesMoved(_ touches: Set, with event: UIEvent?) { 67 | 68 | guard let touch = touches.first else { return } 69 | 70 | guard #available(iOS 9.0, *) else { 71 | debugPrint("ForceTouchImageView: Device does not support ForchTouch") 72 | return 73 | } 74 | 75 | guard traitCollection.forceTouchCapability == UIForceTouchCapability.available else { 76 | debugPrint("ForceTouchImageView: Device does not support ForchTouch") 77 | return 78 | } 79 | 80 | forceTouchDelegate?.forceTouchImageView(self, touchForceDidChange: touch.force) 81 | 82 | let scale = (touch.force*maximumZoomScale)/touch.maximumPossibleForce 83 | setZoomScale(scale, animated: true) 84 | 85 | } 86 | 87 | override func touchesEnded(_ touches: Set, with event: UIEvent?) { 88 | forceTouchDelegate?.forceTouchImageView(self, touchForceDidChange: 0) 89 | setZoomScale(1.0, animated: true) 90 | } 91 | 92 | } 93 | 94 | 95 | // MARK: - UIScrollViewDelegate 96 | extension ForceTouchImageView: UIScrollViewDelegate { 97 | 98 | public func viewForZooming(in scrollView: UIScrollView) -> UIView? { 99 | return imageView 100 | } 101 | 102 | } 103 | 104 | 105 | // MARK: - Helpers 106 | extension ForceTouchImageView { 107 | 108 | func setupView() { 109 | 110 | clipsToBounds = true 111 | bounces = false 112 | 113 | if imageView == nil { 114 | imageView = UIImageView(frame: self.bounds) 115 | } 116 | 117 | imageView.autoresizingMask = [.flexibleWidth, .flexibleHeight] 118 | imageView.contentMode = .scaleAspectFill 119 | imageView.isUserInteractionEnabled = true 120 | addSubview(imageView) 121 | 122 | minimumZoomScale = 1.0 123 | maximumZoomScale = 4.0 124 | 125 | delegate = self 126 | setupGestureRecognizers() 127 | } 128 | 129 | func setupGestureRecognizers() { 130 | let tap = UITapGestureRecognizer(target: self, action: #selector(respondToTap(sender:))) 131 | tap.numberOfTapsRequired = 2 132 | addGestureRecognizer(tap) 133 | } 134 | 135 | func respondToTap(sender: UITapGestureRecognizer) { 136 | let rect = zoomRect(for: 3.0, center: sender.location(in: self)) 137 | zoom(to: rect, animated: true) 138 | } 139 | 140 | func zoomRect(for scale: CGFloat, center: CGPoint) -> CGRect { 141 | var zoomRect = CGRect.zero 142 | zoomRect.size.height = frame.size.height / scale 143 | zoomRect.size.width = frame.size.width / scale 144 | let newCenter = imageView.convert(center, from: self) 145 | zoomRect.origin.x = newCenter.x - (zoomRect.size.width / 2.0) 146 | zoomRect.origin.y = newCenter.y - (zoomRect.size.height / 2.0) 147 | return zoomRect 148 | } 149 | 150 | var midiumZoomScale: CGFloat { 151 | return (maximumZoomScale-minimumZoomScale)/2.0 152 | } 153 | } 154 | 155 | -------------------------------------------------------------------------------- /Source/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.2 19 | CFBundleVersion 20 | $(CURRENT_PROJECT_VERSION) 21 | NSPrincipalClass 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Builds all targets. 3 | 4 | DERIVED_DATA=${1:-/tmp/ForceTouchImageView} 5 | echo "Derived data location: $DERIVED_DATA"; 6 | 7 | set -o pipefail && 8 | rm -rf $DERIVED_DATA && 9 | time xcodebuild clean test \ 10 | -project ForceTouchImageView.xcodeproj \ 11 | -scheme 'ForceTouchImageView' \ 12 | -sdk iphonesimulator10.2 \ 13 | -derivedDataPath $DERIVED_DATA \ 14 | -destination 'platform=iOS Simulator,name=iPhone 7,OS=10.2' \ 15 | OTHER_SWIFT_FLAGS='-Xfrontend -debug-time-function-bodies' \ 16 | | tee build.log \ 17 | | xcpretty && 18 | cat build.log | sh debug-time-function-bodies.sh 19 | -------------------------------------------------------------------------------- /debug-time-function-bodies.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # Pipe the output of xcodebuild to this script to see the slowest 10 functions to compile. 4 | # Use this flag with xcodebuild: OTHER_SWIFT_FLAGS='-Xfrontend -debug-time-function-bodies' 5 | 6 | echo "\nSlowest functions to compile:\n" 7 | grep '^[0-9]\+\.[0-9]\+' | sed 's/\(^[0-9]*.[0-9]*\)\([a-z]*\)/\1 \2/' | sort -k2,2r -k1,1nr | sed 's/\(^[0-9]*.[0-9]*\) \([a-z]*\)/\1\2/' | head -n 10 | sed 's/^/ /' 8 | echo "\n" 9 | --------------------------------------------------------------------------------