├── .swift-version ├── LICENSE ├── PlaceholderViewExample ├── PlaceholderViewExample.xcodeproj │ ├── project.pbxproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcuserdata │ │ │ └── bruno.rocha.xcuserdatad │ │ │ └── UserInterfaceState.xcuserstate │ └── xcuserdata │ │ └── bruno.rocha.xcuserdatad │ │ └── xcschemes │ │ ├── PlaceholderViewExample.xcscheme │ │ └── xcschememanagement.plist ├── PlaceholderViewExample.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── bruno.rocha.xcuserdatad │ │ ├── UserInterfaceState.xcuserstate │ │ └── xcdebugger │ │ └── Breakpoints_v2.xcbkptlist ├── PlaceholderViewExample │ ├── AppDelegate.swift │ ├── Assets.xcassets │ │ ├── AppIcon.appiconset │ │ │ └── Contents.json │ │ ├── Contents.json │ │ └── placeholderEvents.imageset │ │ │ ├── Contents.json │ │ │ ├── placeholderEvents.png │ │ │ ├── placeholderEvents@2x.png │ │ │ └── placeholderEvents@3x.png │ ├── Base.lproj │ │ ├── LaunchScreen.storyboard │ │ └── Main.storyboard │ ├── Info.plist │ └── ViewController.swift ├── Podfile ├── Podfile.lock └── Pods │ ├── Local Podspecs │ └── SlidingGradientView.podspec.json │ ├── Manifest.lock │ ├── Pods.xcodeproj │ ├── project.pbxproj │ └── xcuserdata │ │ └── bruno.rocha.xcuserdatad │ │ └── xcschemes │ │ ├── Pods-PlaceholderViewExample.xcscheme │ │ ├── SlidingGradientView.xcscheme │ │ └── xcschememanagement.plist │ └── Target Support Files │ ├── Pods-PlaceholderViewExample │ ├── Info.plist │ ├── Pods-PlaceholderViewExample-acknowledgements.markdown │ ├── Pods-PlaceholderViewExample-acknowledgements.plist │ ├── Pods-PlaceholderViewExample-dummy.m │ ├── Pods-PlaceholderViewExample-frameworks.sh │ ├── Pods-PlaceholderViewExample-resources.sh │ ├── Pods-PlaceholderViewExample-umbrella.h │ ├── Pods-PlaceholderViewExample.debug.xcconfig │ ├── Pods-PlaceholderViewExample.modulemap │ └── Pods-PlaceholderViewExample.release.xcconfig │ └── SlidingGradientView │ ├── Info.plist │ ├── SlidingGradientView-dummy.m │ ├── SlidingGradientView-prefix.pch │ ├── SlidingGradientView-umbrella.h │ ├── SlidingGradientView.modulemap │ └── SlidingGradientView.xcconfig ├── README.md ├── SlidingGradientView.podspec ├── SlidingGradientView.xcodeproj ├── project.pbxproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcuserdata │ │ └── bruno.rocha.xcuserdatad │ │ └── UserInterfaceState.xcuserstate └── xcuserdata │ └── bruno.rocha.xcuserdatad │ └── xcschemes │ ├── SlidingGradientView.xcscheme │ └── xcschememanagement.plist └── SlidingGradientView ├── Info.plist └── Sources ├── GradientColor.swift ├── GradientProperties.swift ├── SlidingGradientView.swift └── SlidingProperties.swift /.swift-version: -------------------------------------------------------------------------------- 1 | 4.0 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2017 rockbruno 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 10A8BE20C8206A7989709435 /* Pods_PlaceholderViewExample.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A6BE2A00F76DE9B3AEB64507 /* Pods_PlaceholderViewExample.framework */; }; 11 | FD6A90611EC8963D00AFFA47 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD6A90601EC8963D00AFFA47 /* AppDelegate.swift */; }; 12 | FD6A90631EC8963D00AFFA47 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD6A90621EC8963D00AFFA47 /* ViewController.swift */; }; 13 | FD6A90661EC8963D00AFFA47 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = FD6A90641EC8963D00AFFA47 /* Main.storyboard */; }; 14 | FD6A90681EC8963D00AFFA47 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = FD6A90671EC8963D00AFFA47 /* Assets.xcassets */; }; 15 | FD6A906B1EC8963D00AFFA47 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = FD6A90691EC8963D00AFFA47 /* LaunchScreen.storyboard */; }; 16 | /* End PBXBuildFile section */ 17 | 18 | /* Begin PBXFileReference section */ 19 | 035140F05BD85A6AF9206694 /* Pods-PlaceholderViewExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PlaceholderViewExample.debug.xcconfig"; path = "Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.debug.xcconfig"; sourceTree = ""; }; 20 | 19A2F3116744B7F585DE74A8 /* Pods-PlaceholderViewExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-PlaceholderViewExample.release.xcconfig"; path = "Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.release.xcconfig"; sourceTree = ""; }; 21 | A6BE2A00F76DE9B3AEB64507 /* Pods_PlaceholderViewExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_PlaceholderViewExample.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 22 | FD6A905D1EC8963D00AFFA47 /* PlaceholderViewExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = PlaceholderViewExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; 23 | FD6A90601EC8963D00AFFA47 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 24 | FD6A90621EC8963D00AFFA47 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; 25 | FD6A90651EC8963D00AFFA47 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 26 | FD6A90671EC8963D00AFFA47 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 27 | FD6A906A1EC8963D00AFFA47 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 28 | FD6A906C1EC8963D00AFFA47 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 29 | /* End PBXFileReference section */ 30 | 31 | /* Begin PBXFrameworksBuildPhase section */ 32 | FD6A905A1EC8963D00AFFA47 /* Frameworks */ = { 33 | isa = PBXFrameworksBuildPhase; 34 | buildActionMask = 2147483647; 35 | files = ( 36 | 10A8BE20C8206A7989709435 /* Pods_PlaceholderViewExample.framework in Frameworks */, 37 | ); 38 | runOnlyForDeploymentPostprocessing = 0; 39 | }; 40 | /* End PBXFrameworksBuildPhase section */ 41 | 42 | /* Begin PBXGroup section */ 43 | 92243F1C03A95F52E1B4D716 /* Pods */ = { 44 | isa = PBXGroup; 45 | children = ( 46 | 035140F05BD85A6AF9206694 /* Pods-PlaceholderViewExample.debug.xcconfig */, 47 | 19A2F3116744B7F585DE74A8 /* Pods-PlaceholderViewExample.release.xcconfig */, 48 | ); 49 | name = Pods; 50 | sourceTree = ""; 51 | }; 52 | E0E702A3883023CFAF5760D8 /* Frameworks */ = { 53 | isa = PBXGroup; 54 | children = ( 55 | A6BE2A00F76DE9B3AEB64507 /* Pods_PlaceholderViewExample.framework */, 56 | ); 57 | name = Frameworks; 58 | sourceTree = ""; 59 | }; 60 | FD6A90541EC8963D00AFFA47 = { 61 | isa = PBXGroup; 62 | children = ( 63 | FD6A905F1EC8963D00AFFA47 /* PlaceholderViewExample */, 64 | FD6A905E1EC8963D00AFFA47 /* Products */, 65 | 92243F1C03A95F52E1B4D716 /* Pods */, 66 | E0E702A3883023CFAF5760D8 /* Frameworks */, 67 | ); 68 | sourceTree = ""; 69 | }; 70 | FD6A905E1EC8963D00AFFA47 /* Products */ = { 71 | isa = PBXGroup; 72 | children = ( 73 | FD6A905D1EC8963D00AFFA47 /* PlaceholderViewExample.app */, 74 | ); 75 | name = Products; 76 | sourceTree = ""; 77 | }; 78 | FD6A905F1EC8963D00AFFA47 /* PlaceholderViewExample */ = { 79 | isa = PBXGroup; 80 | children = ( 81 | FD6A90601EC8963D00AFFA47 /* AppDelegate.swift */, 82 | FD6A90621EC8963D00AFFA47 /* ViewController.swift */, 83 | FD6A90641EC8963D00AFFA47 /* Main.storyboard */, 84 | FD6A90671EC8963D00AFFA47 /* Assets.xcassets */, 85 | FD6A90691EC8963D00AFFA47 /* LaunchScreen.storyboard */, 86 | FD6A906C1EC8963D00AFFA47 /* Info.plist */, 87 | ); 88 | path = PlaceholderViewExample; 89 | sourceTree = ""; 90 | }; 91 | /* End PBXGroup section */ 92 | 93 | /* Begin PBXNativeTarget section */ 94 | FD6A905C1EC8963D00AFFA47 /* PlaceholderViewExample */ = { 95 | isa = PBXNativeTarget; 96 | buildConfigurationList = FD6A906F1EC8963D00AFFA47 /* Build configuration list for PBXNativeTarget "PlaceholderViewExample" */; 97 | buildPhases = ( 98 | AF72C97BC4DAE191299500BC /* [CP] Check Pods Manifest.lock */, 99 | FD6A90591EC8963D00AFFA47 /* Sources */, 100 | FD6A905A1EC8963D00AFFA47 /* Frameworks */, 101 | FD6A905B1EC8963D00AFFA47 /* Resources */, 102 | CA351904AB0C8BCCE44F365D /* [CP] Embed Pods Frameworks */, 103 | 4F6EF6EABC00B4E6B4E9C2DE /* [CP] Copy Pods Resources */, 104 | ); 105 | buildRules = ( 106 | ); 107 | dependencies = ( 108 | ); 109 | name = PlaceholderViewExample; 110 | productName = PlaceholderViewExample; 111 | productReference = FD6A905D1EC8963D00AFFA47 /* PlaceholderViewExample.app */; 112 | productType = "com.apple.product-type.application"; 113 | }; 114 | /* End PBXNativeTarget section */ 115 | 116 | /* Begin PBXProject section */ 117 | FD6A90551EC8963D00AFFA47 /* Project object */ = { 118 | isa = PBXProject; 119 | attributes = { 120 | LastSwiftUpdateCheck = 0830; 121 | LastUpgradeCheck = 0830; 122 | ORGANIZATIONNAME = "Bruno Rocha"; 123 | TargetAttributes = { 124 | FD6A905C1EC8963D00AFFA47 = { 125 | CreatedOnToolsVersion = 8.3; 126 | DevelopmentTeam = 3PG7SEBUB3; 127 | ProvisioningStyle = Automatic; 128 | }; 129 | }; 130 | }; 131 | buildConfigurationList = FD6A90581EC8963D00AFFA47 /* Build configuration list for PBXProject "PlaceholderViewExample" */; 132 | compatibilityVersion = "Xcode 3.2"; 133 | developmentRegion = English; 134 | hasScannedForEncodings = 0; 135 | knownRegions = ( 136 | en, 137 | Base, 138 | ); 139 | mainGroup = FD6A90541EC8963D00AFFA47; 140 | productRefGroup = FD6A905E1EC8963D00AFFA47 /* Products */; 141 | projectDirPath = ""; 142 | projectRoot = ""; 143 | targets = ( 144 | FD6A905C1EC8963D00AFFA47 /* PlaceholderViewExample */, 145 | ); 146 | }; 147 | /* End PBXProject section */ 148 | 149 | /* Begin PBXResourcesBuildPhase section */ 150 | FD6A905B1EC8963D00AFFA47 /* Resources */ = { 151 | isa = PBXResourcesBuildPhase; 152 | buildActionMask = 2147483647; 153 | files = ( 154 | FD6A906B1EC8963D00AFFA47 /* LaunchScreen.storyboard in Resources */, 155 | FD6A90681EC8963D00AFFA47 /* Assets.xcassets in Resources */, 156 | FD6A90661EC8963D00AFFA47 /* Main.storyboard in Resources */, 157 | ); 158 | runOnlyForDeploymentPostprocessing = 0; 159 | }; 160 | /* End PBXResourcesBuildPhase section */ 161 | 162 | /* Begin PBXShellScriptBuildPhase section */ 163 | 4F6EF6EABC00B4E6B4E9C2DE /* [CP] Copy Pods Resources */ = { 164 | isa = PBXShellScriptBuildPhase; 165 | buildActionMask = 2147483647; 166 | files = ( 167 | ); 168 | inputPaths = ( 169 | ); 170 | name = "[CP] Copy Pods Resources"; 171 | outputPaths = ( 172 | ); 173 | runOnlyForDeploymentPostprocessing = 0; 174 | shellPath = /bin/sh; 175 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-resources.sh\"\n"; 176 | showEnvVarsInLog = 0; 177 | }; 178 | AF72C97BC4DAE191299500BC /* [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_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n"; 191 | showEnvVarsInLog = 0; 192 | }; 193 | CA351904AB0C8BCCE44F365D /* [CP] Embed Pods Frameworks */ = { 194 | isa = PBXShellScriptBuildPhase; 195 | buildActionMask = 2147483647; 196 | files = ( 197 | ); 198 | inputPaths = ( 199 | ); 200 | name = "[CP] Embed Pods Frameworks"; 201 | outputPaths = ( 202 | ); 203 | runOnlyForDeploymentPostprocessing = 0; 204 | shellPath = /bin/sh; 205 | shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-frameworks.sh\"\n"; 206 | showEnvVarsInLog = 0; 207 | }; 208 | /* End PBXShellScriptBuildPhase section */ 209 | 210 | /* Begin PBXSourcesBuildPhase section */ 211 | FD6A90591EC8963D00AFFA47 /* Sources */ = { 212 | isa = PBXSourcesBuildPhase; 213 | buildActionMask = 2147483647; 214 | files = ( 215 | FD6A90631EC8963D00AFFA47 /* ViewController.swift in Sources */, 216 | FD6A90611EC8963D00AFFA47 /* AppDelegate.swift in Sources */, 217 | ); 218 | runOnlyForDeploymentPostprocessing = 0; 219 | }; 220 | /* End PBXSourcesBuildPhase section */ 221 | 222 | /* Begin PBXVariantGroup section */ 223 | FD6A90641EC8963D00AFFA47 /* Main.storyboard */ = { 224 | isa = PBXVariantGroup; 225 | children = ( 226 | FD6A90651EC8963D00AFFA47 /* Base */, 227 | ); 228 | name = Main.storyboard; 229 | sourceTree = ""; 230 | }; 231 | FD6A90691EC8963D00AFFA47 /* LaunchScreen.storyboard */ = { 232 | isa = PBXVariantGroup; 233 | children = ( 234 | FD6A906A1EC8963D00AFFA47 /* Base */, 235 | ); 236 | name = LaunchScreen.storyboard; 237 | sourceTree = ""; 238 | }; 239 | /* End PBXVariantGroup section */ 240 | 241 | /* Begin XCBuildConfiguration section */ 242 | FD6A906D1EC8963D00AFFA47 /* 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 | FD6A906E1EC8963D00AFFA47 /* 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 | FD6A90701EC8963D00AFFA47 /* Debug */ = { 338 | isa = XCBuildConfiguration; 339 | baseConfigurationReference = 035140F05BD85A6AF9206694 /* Pods-PlaceholderViewExample.debug.xcconfig */; 340 | buildSettings = { 341 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 342 | DEVELOPMENT_TEAM = 3PG7SEBUB3; 343 | INFOPLIST_FILE = PlaceholderViewExample/Info.plist; 344 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 345 | PRODUCT_BUNDLE_IDENTIFIER = com.rockbruno.PlaceholderViewExample; 346 | PRODUCT_NAME = "$(TARGET_NAME)"; 347 | SWIFT_VERSION = 3.0; 348 | }; 349 | name = Debug; 350 | }; 351 | FD6A90711EC8963D00AFFA47 /* Release */ = { 352 | isa = XCBuildConfiguration; 353 | baseConfigurationReference = 19A2F3116744B7F585DE74A8 /* Pods-PlaceholderViewExample.release.xcconfig */; 354 | buildSettings = { 355 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 356 | DEVELOPMENT_TEAM = 3PG7SEBUB3; 357 | INFOPLIST_FILE = PlaceholderViewExample/Info.plist; 358 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 359 | PRODUCT_BUNDLE_IDENTIFIER = com.rockbruno.PlaceholderViewExample; 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 | FD6A90581EC8963D00AFFA47 /* Build configuration list for PBXProject "PlaceholderViewExample" */ = { 369 | isa = XCConfigurationList; 370 | buildConfigurations = ( 371 | FD6A906D1EC8963D00AFFA47 /* Debug */, 372 | FD6A906E1EC8963D00AFFA47 /* Release */, 373 | ); 374 | defaultConfigurationIsVisible = 0; 375 | defaultConfigurationName = Release; 376 | }; 377 | FD6A906F1EC8963D00AFFA47 /* Build configuration list for PBXNativeTarget "PlaceholderViewExample" */ = { 378 | isa = XCConfigurationList; 379 | buildConfigurations = ( 380 | FD6A90701EC8963D00AFFA47 /* Debug */, 381 | FD6A90711EC8963D00AFFA47 /* Release */, 382 | ); 383 | defaultConfigurationIsVisible = 0; 384 | defaultConfigurationName = Release; 385 | }; 386 | /* End XCConfigurationList section */ 387 | }; 388 | rootObject = FD6A90551EC8963D00AFFA47 /* Project object */; 389 | } 390 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcodeproj/project.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rockbruno/SlidingGradientView/0557b6f7947bf7275064316e281a688053146cef/PlaceholderViewExample/PlaceholderViewExample.xcodeproj/project.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/PlaceholderViewExample.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 39 | 40 | 41 | 42 | 43 | 44 | 54 | 56 | 62 | 63 | 64 | 65 | 66 | 67 | 73 | 75 | 81 | 82 | 83 | 84 | 86 | 87 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | PlaceholderViewExample.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | FD6A905C1EC8963D00AFFA47 16 | 17 | primary 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rockbruno/SlidingGradientView/0557b6f7947bf7275064316e281a688053146cef/PlaceholderViewExample/PlaceholderViewExample.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 8 | 20 | 21 | 22 | 24 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | // 2 | // AppDelegate.swift 3 | // PlaceholderViewExample 4 | // 5 | // Created by Bruno Rocha on 5/14/17. 6 | // Copyright © 2017 Bruno Rocha. 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 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/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 | } -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "placeholderEvents.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "placeholderEvents@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "placeholderEvents@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/placeholderEvents.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rockbruno/SlidingGradientView/0557b6f7947bf7275064316e281a688053146cef/PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/placeholderEvents.png -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/placeholderEvents@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rockbruno/SlidingGradientView/0557b6f7947bf7275064316e281a688053146cef/PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/placeholderEvents@2x.png -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/placeholderEvents@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rockbruno/SlidingGradientView/0557b6f7947bf7275064316e281a688053146cef/PlaceholderViewExample/PlaceholderViewExample/Assets.xcassets/placeholderEvents.imageset/placeholderEvents@3x.png -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/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 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/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 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/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 | -------------------------------------------------------------------------------- /PlaceholderViewExample/PlaceholderViewExample/ViewController.swift: -------------------------------------------------------------------------------- 1 | // 2 | // ViewController.swift 3 | // PlaceholderViewExample 4 | // 5 | // Created by Bruno Rocha on 5/14/17. 6 | // Copyright © 2017 Bruno Rocha. All rights reserved. 7 | // 8 | 9 | import UIKit 10 | import SlidingGradientView 11 | 12 | class ViewController: UIViewController { 13 | 14 | override func viewDidLoad() { 15 | super.viewDidLoad() 16 | 17 | let placeHolder = SlidingGradientView(image: UIImage(named: "placeholderEvents")) 18 | view.addSubview(placeHolder) 19 | placeHolder.translatesAutoresizingMaskIntoConstraints = false 20 | NSLayoutConstraint.activate([ 21 | placeHolder.topAnchor.constraint(equalTo: view.topAnchor, constant: 48), 22 | placeHolder.leadingAnchor.constraint(equalTo: view.leadingAnchor, constant: 24), 23 | placeHolder.trailingAnchor.constraint(equalTo: view.trailingAnchor, constant: -24) 24 | ]) 25 | placeHolder.startAnimating() 26 | 27 | 28 | let slidingProperties = SlidingProperties(fromX: 0, toX: UIScreen.main.bounds.width, animationDuration: 3) 29 | let gradientColors = [GradientColor(color: UIColor.white.withAlphaComponent(0), location: 0), 30 | GradientColor(color: UIColor.red, location: 0.5), 31 | GradientColor(color: UIColor.white.withAlphaComponent(0), location: 1)] 32 | let properties = GradientProperties(gradientWidth: 300, gradientColors: gradientColors, slidingProperties: slidingProperties) 33 | 34 | let placeHolder2 = SlidingGradientView(image: UIImage(named: "placeholderEvents"), properties: properties) 35 | view.addSubview(placeHolder2) 36 | placeHolder2.translatesAutoresizingMaskIntoConstraints = false 37 | NSLayoutConstraint.activate([ 38 | placeHolder2.topAnchor.constraint(equalTo: placeHolder.bottomAnchor, constant: 16), 39 | placeHolder2.leadingAnchor.constraint(equalTo: view.leadingAnchor, constant: 24), 40 | placeHolder2.trailingAnchor.constraint(equalTo: view.trailingAnchor, constant: -24) 41 | ]) 42 | placeHolder2.startAnimating() 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Podfile: -------------------------------------------------------------------------------- 1 | use_frameworks! 2 | 3 | target ‘PlaceholderViewExample' do 4 | pod ‘SlidingGradientView’, :path => '../' 5 | end -------------------------------------------------------------------------------- /PlaceholderViewExample/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - SlidingGradientView (0.2.3) 3 | 4 | DEPENDENCIES: 5 | - SlidingGradientView (from `../`) 6 | 7 | EXTERNAL SOURCES: 8 | SlidingGradientView: 9 | :path: "../" 10 | 11 | SPEC CHECKSUMS: 12 | SlidingGradientView: 7e0c47a25189aa5c915b9f876397727a2e9589ca 13 | 14 | PODFILE CHECKSUM: 8e66b01b8d79c190fc1bee80fdad7493d5cf86d0 15 | 16 | COCOAPODS: 1.2.1 17 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Local Podspecs/SlidingGradientView.podspec.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "SlidingGradientView", 3 | "version": "0.2.3", 4 | "summary": "Easily add sliding gradient effects to images. Meant to be used as loading placeholder views.", 5 | "description": "TODO: Add long description of the pod here.", 6 | "homepage": "https://github.com/rockbruno/SlidingGradientView", 7 | "license": { 8 | "type": "MIT", 9 | "file": "LICENSE" 10 | }, 11 | "authors": { 12 | "rockbruno": "brunorochaesilva@gmail.com" 13 | }, 14 | "source": { 15 | "git": "https://github.com/rockbruno/SlidingGradientView.git", 16 | "branch": "master", 17 | "tag": "0.2.3" 18 | }, 19 | "platforms": { 20 | "ios": "9.0" 21 | }, 22 | "source_files": "SlidingGradientView/Sources/**/*" 23 | } 24 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Manifest.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - SlidingGradientView (0.2.3) 3 | 4 | DEPENDENCIES: 5 | - SlidingGradientView (from `../`) 6 | 7 | EXTERNAL SOURCES: 8 | SlidingGradientView: 9 | :path: "../" 10 | 11 | SPEC CHECKSUMS: 12 | SlidingGradientView: 7e0c47a25189aa5c915b9f876397727a2e9589ca 13 | 14 | PODFILE CHECKSUM: 8e66b01b8d79c190fc1bee80fdad7493d5cf86d0 15 | 16 | COCOAPODS: 1.2.1 17 | -------------------------------------------------------------------------------- /PlaceholderViewExample/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 | 18672892E7CF676514588658B99A1547 /* Pods-PlaceholderViewExample-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = 8C54901B7260F509AEDE24BDD013AFE0 /* Pods-PlaceholderViewExample-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 11 | 2C1287749061AEB8F528C0037E9A93FE /* SlidingGradientView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4F9E71375DB8B1CD7695F7DC7CBF1F71 /* SlidingGradientView.swift */; }; 12 | 4693D61E1477EF5C68C1E48CFAF5A3EB /* SlidingGradientView-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 7E8B2C14ABF030EF178B351BB7D59D8A /* SlidingGradientView-dummy.m */; }; 13 | 54A6908F4F48B942C080F5091A5F87A0 /* GradientProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = 06435B36C17A035C7DF50A1EFEBEA5E5 /* GradientProperties.swift */; }; 14 | 8586033DC957DBA0A2CC252B3510631F /* Pods-PlaceholderViewExample-dummy.m in Sources */ = {isa = PBXBuildFile; fileRef = 23782F9CBAEB074F14F92CFA6BFF19B7 /* Pods-PlaceholderViewExample-dummy.m */; }; 15 | A655A978E059096B767BC2F940E234A7 /* SlidingGradientView-umbrella.h in Headers */ = {isa = PBXBuildFile; fileRef = A55EBFD5AA75CBCD8B13EB02BE3BECF8 /* SlidingGradientView-umbrella.h */; settings = {ATTRIBUTES = (Public, ); }; }; 16 | D8119168C4BEC4889212422223DF3DAA /* SlidingProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = CA2A3F3492F4B7C00C8C9C5A4C1EEA3E /* SlidingProperties.swift */; }; 17 | DAB28A663519A1F1449977E081A3A360 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; }; 18 | DB97E90C63289ECD2F2A249BC9BFB91F /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */; }; 19 | E58C78C35985C061B388AD3F2E1DB7A8 /* GradientColor.swift in Sources */ = {isa = PBXBuildFile; fileRef = E04FE1F5A7CFF1236362D456B9B22B91 /* GradientColor.swift */; }; 20 | /* End PBXBuildFile section */ 21 | 22 | /* Begin PBXContainerItemProxy section */ 23 | FE737DBEF862374663124DBB03C12AEB /* PBXContainerItemProxy */ = { 24 | isa = PBXContainerItemProxy; 25 | containerPortal = D41D8CD98F00B204E9800998ECF8427E /* Project object */; 26 | proxyType = 1; 27 | remoteGlobalIDString = 0EE717FD1528C7EA51501F0A9EF8E19C; 28 | remoteInfo = SlidingGradientView; 29 | }; 30 | /* End PBXContainerItemProxy section */ 31 | 32 | /* Begin PBXFileReference section */ 33 | 06435B36C17A035C7DF50A1EFEBEA5E5 /* GradientProperties.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = GradientProperties.swift; sourceTree = ""; }; 34 | 10B07EE263D2F647B61F6D723183A8BC /* Pods-PlaceholderViewExample-resources.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PlaceholderViewExample-resources.sh"; sourceTree = ""; }; 35 | 161D72A2D72365C358863702D0348DBE /* Pods-PlaceholderViewExample-acknowledgements.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = "Pods-PlaceholderViewExample-acknowledgements.plist"; sourceTree = ""; }; 36 | 23782F9CBAEB074F14F92CFA6BFF19B7 /* Pods-PlaceholderViewExample-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "Pods-PlaceholderViewExample-dummy.m"; sourceTree = ""; }; 37 | 26273B376DD81763D26268341E432734 /* SlidingGradientView.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = SlidingGradientView.xcconfig; sourceTree = ""; }; 38 | 41A889844ED88A57D93818A028381865 /* Pods-PlaceholderViewExample.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = "Pods-PlaceholderViewExample.modulemap"; sourceTree = ""; }; 39 | 4F9E71375DB8B1CD7695F7DC7CBF1F71 /* SlidingGradientView.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = SlidingGradientView.swift; sourceTree = ""; }; 40 | 5B6E13FC7F1BD1F938B3595495D6C05D /* SlidingGradientView.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = SlidingGradientView.framework; path = SlidingGradientView.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 41 | 603D440B96C9A39D61624962C3177D0E /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 42 | 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; }; 43 | 7E8B2C14ABF030EF178B351BB7D59D8A /* SlidingGradientView-dummy.m */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.objc; path = "SlidingGradientView-dummy.m"; sourceTree = ""; }; 44 | 8B2BBA66EA265F49178F5881F033F6B9 /* SlidingGradientView.modulemap */ = {isa = PBXFileReference; includeInIndex = 1; path = SlidingGradientView.modulemap; sourceTree = ""; }; 45 | 8C54901B7260F509AEDE24BDD013AFE0 /* Pods-PlaceholderViewExample-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "Pods-PlaceholderViewExample-umbrella.h"; sourceTree = ""; }; 46 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */ = {isa = PBXFileReference; explicitFileType = text.script.ruby; includeInIndex = 1; lastKnownFileType = text; name = Podfile; path = ../Podfile; sourceTree = SOURCE_ROOT; xcLanguageSpecificationIdentifier = xcode.lang.ruby; }; 47 | 9B51230C8C9F89F7622C40FEC782F7F9 /* Pods-PlaceholderViewExample-frameworks.sh */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.script.sh; path = "Pods-PlaceholderViewExample-frameworks.sh"; sourceTree = ""; }; 48 | A55EBFD5AA75CBCD8B13EB02BE3BECF8 /* SlidingGradientView-umbrella.h */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "SlidingGradientView-umbrella.h"; sourceTree = ""; }; 49 | AE55AB97825E537C8C00A50F3C51D231 /* Info.plist */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 50 | C3A3A4D9B8CA32EB5D5B6D37A555F9B1 /* Pods_PlaceholderViewExample.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; name = Pods_PlaceholderViewExample.framework; path = "Pods-PlaceholderViewExample.framework"; sourceTree = BUILT_PRODUCTS_DIR; }; 51 | CA2A3F3492F4B7C00C8C9C5A4C1EEA3E /* SlidingProperties.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = SlidingProperties.swift; sourceTree = ""; }; 52 | CAE0C89F57B2C622706A6A814A0F5805 /* Pods-PlaceholderViewExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PlaceholderViewExample.release.xcconfig"; sourceTree = ""; }; 53 | CC07FD4CA2D5DBACB9905DED3B40E4D5 /* Pods-PlaceholderViewExample-acknowledgements.markdown */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text; path = "Pods-PlaceholderViewExample-acknowledgements.markdown"; sourceTree = ""; }; 54 | E04FE1F5A7CFF1236362D456B9B22B91 /* GradientColor.swift */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.swift; path = GradientColor.swift; sourceTree = ""; }; 55 | F89E35238A2BADBCFBA5F64E097DAD96 /* Pods-PlaceholderViewExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; path = "Pods-PlaceholderViewExample.debug.xcconfig"; sourceTree = ""; }; 56 | FD9B3D629E6E584D99C55663F9612A02 /* SlidingGradientView-prefix.pch */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = sourcecode.c.h; path = "SlidingGradientView-prefix.pch"; sourceTree = ""; }; 57 | /* End PBXFileReference section */ 58 | 59 | /* Begin PBXFrameworksBuildPhase section */ 60 | BB7C6FA5922BC9FF3A97BC216CED949E /* Frameworks */ = { 61 | isa = PBXFrameworksBuildPhase; 62 | buildActionMask = 2147483647; 63 | files = ( 64 | DB97E90C63289ECD2F2A249BC9BFB91F /* Foundation.framework in Frameworks */, 65 | ); 66 | runOnlyForDeploymentPostprocessing = 0; 67 | }; 68 | F387DE2D8D69FEB5306B914A725ADF74 /* Frameworks */ = { 69 | isa = PBXFrameworksBuildPhase; 70 | buildActionMask = 2147483647; 71 | files = ( 72 | DAB28A663519A1F1449977E081A3A360 /* Foundation.framework in Frameworks */, 73 | ); 74 | runOnlyForDeploymentPostprocessing = 0; 75 | }; 76 | /* End PBXFrameworksBuildPhase section */ 77 | 78 | /* Begin PBXGroup section */ 79 | 2BB6FF14D0D85CC648309002B21D0A7B /* SlidingGradientView */ = { 80 | isa = PBXGroup; 81 | children = ( 82 | A3FFBB76D65287C54499BE695F9666F8 /* SlidingGradientView */, 83 | 404C504149E52196DA0F5AF74BA50080 /* Support Files */, 84 | ); 85 | name = SlidingGradientView; 86 | path = ../..; 87 | sourceTree = ""; 88 | }; 89 | 404C504149E52196DA0F5AF74BA50080 /* Support Files */ = { 90 | isa = PBXGroup; 91 | children = ( 92 | 603D440B96C9A39D61624962C3177D0E /* Info.plist */, 93 | 8B2BBA66EA265F49178F5881F033F6B9 /* SlidingGradientView.modulemap */, 94 | 26273B376DD81763D26268341E432734 /* SlidingGradientView.xcconfig */, 95 | 7E8B2C14ABF030EF178B351BB7D59D8A /* SlidingGradientView-dummy.m */, 96 | FD9B3D629E6E584D99C55663F9612A02 /* SlidingGradientView-prefix.pch */, 97 | A55EBFD5AA75CBCD8B13EB02BE3BECF8 /* SlidingGradientView-umbrella.h */, 98 | ); 99 | name = "Support Files"; 100 | path = "PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView"; 101 | sourceTree = ""; 102 | }; 103 | 5F43A8DC5E4EDC543928E5A46B0CE169 /* Sources */ = { 104 | isa = PBXGroup; 105 | children = ( 106 | E04FE1F5A7CFF1236362D456B9B22B91 /* GradientColor.swift */, 107 | 06435B36C17A035C7DF50A1EFEBEA5E5 /* GradientProperties.swift */, 108 | 4F9E71375DB8B1CD7695F7DC7CBF1F71 /* SlidingGradientView.swift */, 109 | CA2A3F3492F4B7C00C8C9C5A4C1EEA3E /* SlidingProperties.swift */, 110 | ); 111 | name = Sources; 112 | path = Sources; 113 | sourceTree = ""; 114 | }; 115 | 77E5A62AD6A0768839F6BFDF107FB992 /* Development Pods */ = { 116 | isa = PBXGroup; 117 | children = ( 118 | 2BB6FF14D0D85CC648309002B21D0A7B /* SlidingGradientView */, 119 | ); 120 | name = "Development Pods"; 121 | sourceTree = ""; 122 | }; 123 | 7DB346D0F39D3F0E887471402A8071AB = { 124 | isa = PBXGroup; 125 | children = ( 126 | 93A4A3777CF96A4AAC1D13BA6DCCEA73 /* Podfile */, 127 | 77E5A62AD6A0768839F6BFDF107FB992 /* Development Pods */, 128 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */, 129 | C1DBA15E5D5A44B2037120ECE5ED2DFC /* Products */, 130 | 9740B202C69FA65F5F1426C6AAF8F5F3 /* Targets Support Files */, 131 | ); 132 | sourceTree = ""; 133 | }; 134 | 9740B202C69FA65F5F1426C6AAF8F5F3 /* Targets Support Files */ = { 135 | isa = PBXGroup; 136 | children = ( 137 | A3CD25964E55DC978FDA1C64D152D158 /* Pods-PlaceholderViewExample */, 138 | ); 139 | name = "Targets Support Files"; 140 | sourceTree = ""; 141 | }; 142 | A3CD25964E55DC978FDA1C64D152D158 /* Pods-PlaceholderViewExample */ = { 143 | isa = PBXGroup; 144 | children = ( 145 | AE55AB97825E537C8C00A50F3C51D231 /* Info.plist */, 146 | 41A889844ED88A57D93818A028381865 /* Pods-PlaceholderViewExample.modulemap */, 147 | CC07FD4CA2D5DBACB9905DED3B40E4D5 /* Pods-PlaceholderViewExample-acknowledgements.markdown */, 148 | 161D72A2D72365C358863702D0348DBE /* Pods-PlaceholderViewExample-acknowledgements.plist */, 149 | 23782F9CBAEB074F14F92CFA6BFF19B7 /* Pods-PlaceholderViewExample-dummy.m */, 150 | 9B51230C8C9F89F7622C40FEC782F7F9 /* Pods-PlaceholderViewExample-frameworks.sh */, 151 | 10B07EE263D2F647B61F6D723183A8BC /* Pods-PlaceholderViewExample-resources.sh */, 152 | 8C54901B7260F509AEDE24BDD013AFE0 /* Pods-PlaceholderViewExample-umbrella.h */, 153 | F89E35238A2BADBCFBA5F64E097DAD96 /* Pods-PlaceholderViewExample.debug.xcconfig */, 154 | CAE0C89F57B2C622706A6A814A0F5805 /* Pods-PlaceholderViewExample.release.xcconfig */, 155 | ); 156 | name = "Pods-PlaceholderViewExample"; 157 | path = "Target Support Files/Pods-PlaceholderViewExample"; 158 | sourceTree = ""; 159 | }; 160 | A3FFBB76D65287C54499BE695F9666F8 /* SlidingGradientView */ = { 161 | isa = PBXGroup; 162 | children = ( 163 | 5F43A8DC5E4EDC543928E5A46B0CE169 /* Sources */, 164 | ); 165 | name = SlidingGradientView; 166 | path = SlidingGradientView; 167 | sourceTree = ""; 168 | }; 169 | BC3CA7F9E30CC8F7E2DD044DD34432FC /* Frameworks */ = { 170 | isa = PBXGroup; 171 | children = ( 172 | D35AF013A5F0BAD4F32504907A52519E /* iOS */, 173 | ); 174 | name = Frameworks; 175 | sourceTree = ""; 176 | }; 177 | C1DBA15E5D5A44B2037120ECE5ED2DFC /* Products */ = { 178 | isa = PBXGroup; 179 | children = ( 180 | C3A3A4D9B8CA32EB5D5B6D37A555F9B1 /* Pods_PlaceholderViewExample.framework */, 181 | 5B6E13FC7F1BD1F938B3595495D6C05D /* SlidingGradientView.framework */, 182 | ); 183 | name = Products; 184 | sourceTree = ""; 185 | }; 186 | D35AF013A5F0BAD4F32504907A52519E /* iOS */ = { 187 | isa = PBXGroup; 188 | children = ( 189 | 6604A7D69453B4569E4E4827FB9155A9 /* Foundation.framework */, 190 | ); 191 | name = iOS; 192 | sourceTree = ""; 193 | }; 194 | /* End PBXGroup section */ 195 | 196 | /* Begin PBXHeadersBuildPhase section */ 197 | 712252FC97A240F86CD4A33886858BD0 /* Headers */ = { 198 | isa = PBXHeadersBuildPhase; 199 | buildActionMask = 2147483647; 200 | files = ( 201 | 18672892E7CF676514588658B99A1547 /* Pods-PlaceholderViewExample-umbrella.h in Headers */, 202 | ); 203 | runOnlyForDeploymentPostprocessing = 0; 204 | }; 205 | 9DCCC6534BACACB0D72097CEA121EBD8 /* Headers */ = { 206 | isa = PBXHeadersBuildPhase; 207 | buildActionMask = 2147483647; 208 | files = ( 209 | A655A978E059096B767BC2F940E234A7 /* SlidingGradientView-umbrella.h in Headers */, 210 | ); 211 | runOnlyForDeploymentPostprocessing = 0; 212 | }; 213 | /* End PBXHeadersBuildPhase section */ 214 | 215 | /* Begin PBXNativeTarget section */ 216 | 0EE717FD1528C7EA51501F0A9EF8E19C /* SlidingGradientView */ = { 217 | isa = PBXNativeTarget; 218 | buildConfigurationList = 508DE151B449A5F4C3EEB1CBCC1C3FB4 /* Build configuration list for PBXNativeTarget "SlidingGradientView" */; 219 | buildPhases = ( 220 | 2528377B1735C6D038F8187C5FBFAEB5 /* Sources */, 221 | BB7C6FA5922BC9FF3A97BC216CED949E /* Frameworks */, 222 | 9DCCC6534BACACB0D72097CEA121EBD8 /* Headers */, 223 | ); 224 | buildRules = ( 225 | ); 226 | dependencies = ( 227 | ); 228 | name = SlidingGradientView; 229 | productName = SlidingGradientView; 230 | productReference = 5B6E13FC7F1BD1F938B3595495D6C05D /* SlidingGradientView.framework */; 231 | productType = "com.apple.product-type.framework"; 232 | }; 233 | 76347100D6C484EA48BC121F62D24C44 /* Pods-PlaceholderViewExample */ = { 234 | isa = PBXNativeTarget; 235 | buildConfigurationList = 17B823C9BF4C175C4F088585C70FA022 /* Build configuration list for PBXNativeTarget "Pods-PlaceholderViewExample" */; 236 | buildPhases = ( 237 | 41FC297AA605DEED36CA0D165BA1BF7F /* Sources */, 238 | F387DE2D8D69FEB5306B914A725ADF74 /* Frameworks */, 239 | 712252FC97A240F86CD4A33886858BD0 /* Headers */, 240 | ); 241 | buildRules = ( 242 | ); 243 | dependencies = ( 244 | 2D8DFBB7ACF964EC0FD7FFB078136D34 /* PBXTargetDependency */, 245 | ); 246 | name = "Pods-PlaceholderViewExample"; 247 | productName = "Pods-PlaceholderViewExample"; 248 | productReference = C3A3A4D9B8CA32EB5D5B6D37A555F9B1 /* Pods_PlaceholderViewExample.framework */; 249 | productType = "com.apple.product-type.framework"; 250 | }; 251 | /* End PBXNativeTarget section */ 252 | 253 | /* Begin PBXProject section */ 254 | D41D8CD98F00B204E9800998ECF8427E /* Project object */ = { 255 | isa = PBXProject; 256 | attributes = { 257 | LastSwiftUpdateCheck = 0830; 258 | LastUpgradeCheck = 0700; 259 | }; 260 | buildConfigurationList = 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */; 261 | compatibilityVersion = "Xcode 3.2"; 262 | developmentRegion = English; 263 | hasScannedForEncodings = 0; 264 | knownRegions = ( 265 | en, 266 | ); 267 | mainGroup = 7DB346D0F39D3F0E887471402A8071AB; 268 | productRefGroup = C1DBA15E5D5A44B2037120ECE5ED2DFC /* Products */; 269 | projectDirPath = ""; 270 | projectRoot = ""; 271 | targets = ( 272 | 76347100D6C484EA48BC121F62D24C44 /* Pods-PlaceholderViewExample */, 273 | 0EE717FD1528C7EA51501F0A9EF8E19C /* SlidingGradientView */, 274 | ); 275 | }; 276 | /* End PBXProject section */ 277 | 278 | /* Begin PBXSourcesBuildPhase section */ 279 | 2528377B1735C6D038F8187C5FBFAEB5 /* Sources */ = { 280 | isa = PBXSourcesBuildPhase; 281 | buildActionMask = 2147483647; 282 | files = ( 283 | E58C78C35985C061B388AD3F2E1DB7A8 /* GradientColor.swift in Sources */, 284 | 54A6908F4F48B942C080F5091A5F87A0 /* GradientProperties.swift in Sources */, 285 | 4693D61E1477EF5C68C1E48CFAF5A3EB /* SlidingGradientView-dummy.m in Sources */, 286 | 2C1287749061AEB8F528C0037E9A93FE /* SlidingGradientView.swift in Sources */, 287 | D8119168C4BEC4889212422223DF3DAA /* SlidingProperties.swift in Sources */, 288 | ); 289 | runOnlyForDeploymentPostprocessing = 0; 290 | }; 291 | 41FC297AA605DEED36CA0D165BA1BF7F /* Sources */ = { 292 | isa = PBXSourcesBuildPhase; 293 | buildActionMask = 2147483647; 294 | files = ( 295 | 8586033DC957DBA0A2CC252B3510631F /* Pods-PlaceholderViewExample-dummy.m in Sources */, 296 | ); 297 | runOnlyForDeploymentPostprocessing = 0; 298 | }; 299 | /* End PBXSourcesBuildPhase section */ 300 | 301 | /* Begin PBXTargetDependency section */ 302 | 2D8DFBB7ACF964EC0FD7FFB078136D34 /* PBXTargetDependency */ = { 303 | isa = PBXTargetDependency; 304 | name = SlidingGradientView; 305 | target = 0EE717FD1528C7EA51501F0A9EF8E19C /* SlidingGradientView */; 306 | targetProxy = FE737DBEF862374663124DBB03C12AEB /* PBXContainerItemProxy */; 307 | }; 308 | /* End PBXTargetDependency section */ 309 | 310 | /* Begin XCBuildConfiguration section */ 311 | 067E071992EA6570D6F3B82AFB092998 /* Release */ = { 312 | isa = XCBuildConfiguration; 313 | baseConfigurationReference = CAE0C89F57B2C622706A6A814A0F5805 /* Pods-PlaceholderViewExample.release.xcconfig */; 314 | buildSettings = { 315 | CODE_SIGN_IDENTITY = ""; 316 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 317 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 318 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 319 | CURRENT_PROJECT_VERSION = 1; 320 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 321 | DEFINES_MODULE = YES; 322 | DYLIB_COMPATIBILITY_VERSION = 1; 323 | DYLIB_CURRENT_VERSION = 1; 324 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 325 | ENABLE_STRICT_OBJC_MSGSEND = YES; 326 | GCC_NO_COMMON_BLOCKS = YES; 327 | INFOPLIST_FILE = "Target Support Files/Pods-PlaceholderViewExample/Info.plist"; 328 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 329 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 330 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 331 | MACH_O_TYPE = staticlib; 332 | MODULEMAP_FILE = "Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.modulemap"; 333 | MTL_ENABLE_DEBUG_INFO = NO; 334 | OTHER_LDFLAGS = ""; 335 | OTHER_LIBTOOLFLAGS = ""; 336 | PODS_ROOT = "$(SRCROOT)"; 337 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; 338 | PRODUCT_NAME = Pods_PlaceholderViewExample; 339 | SDKROOT = iphoneos; 340 | SKIP_INSTALL = YES; 341 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 342 | SWIFT_VERSION = 3.0; 343 | TARGETED_DEVICE_FAMILY = "1,2"; 344 | VERSIONING_SYSTEM = "apple-generic"; 345 | VERSION_INFO_PREFIX = ""; 346 | }; 347 | name = Release; 348 | }; 349 | 1106BDF52E67A91B4DF42F60FE61ED34 /* Debug */ = { 350 | isa = XCBuildConfiguration; 351 | baseConfigurationReference = 26273B376DD81763D26268341E432734 /* SlidingGradientView.xcconfig */; 352 | buildSettings = { 353 | CODE_SIGN_IDENTITY = ""; 354 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 355 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 356 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 357 | CURRENT_PROJECT_VERSION = 1; 358 | DEBUG_INFORMATION_FORMAT = dwarf; 359 | DEFINES_MODULE = YES; 360 | DYLIB_COMPATIBILITY_VERSION = 1; 361 | DYLIB_CURRENT_VERSION = 1; 362 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 363 | ENABLE_STRICT_OBJC_MSGSEND = YES; 364 | GCC_NO_COMMON_BLOCKS = YES; 365 | GCC_PREFIX_HEADER = "Target Support Files/SlidingGradientView/SlidingGradientView-prefix.pch"; 366 | INFOPLIST_FILE = "Target Support Files/SlidingGradientView/Info.plist"; 367 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 368 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 369 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 370 | MODULEMAP_FILE = "Target Support Files/SlidingGradientView/SlidingGradientView.modulemap"; 371 | MTL_ENABLE_DEBUG_INFO = YES; 372 | PRODUCT_NAME = SlidingGradientView; 373 | SDKROOT = iphoneos; 374 | SKIP_INSTALL = YES; 375 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 376 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 377 | SWIFT_VERSION = 3.0; 378 | TARGETED_DEVICE_FAMILY = "1,2"; 379 | VERSIONING_SYSTEM = "apple-generic"; 380 | VERSION_INFO_PREFIX = ""; 381 | }; 382 | name = Debug; 383 | }; 384 | 163D87BE96A63549B0EACF1CC31A2E90 /* Debug */ = { 385 | isa = XCBuildConfiguration; 386 | buildSettings = { 387 | ALWAYS_SEARCH_USER_PATHS = NO; 388 | CLANG_ANALYZER_NONNULL = YES; 389 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES; 390 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 391 | CLANG_CXX_LIBRARY = "libc++"; 392 | CLANG_ENABLE_MODULES = YES; 393 | CLANG_ENABLE_OBJC_ARC = YES; 394 | CLANG_WARN_BOOL_CONVERSION = YES; 395 | CLANG_WARN_CONSTANT_CONVERSION = YES; 396 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; 397 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 398 | CLANG_WARN_EMPTY_BODY = YES; 399 | CLANG_WARN_ENUM_CONVERSION = YES; 400 | CLANG_WARN_INFINITE_RECURSION = YES; 401 | CLANG_WARN_INT_CONVERSION = YES; 402 | CLANG_WARN_OBJC_ROOT_CLASS = YES; 403 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 404 | CLANG_WARN_UNREACHABLE_CODE = YES; 405 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 406 | CODE_SIGNING_REQUIRED = NO; 407 | COPY_PHASE_STRIP = NO; 408 | ENABLE_TESTABILITY = YES; 409 | GCC_C_LANGUAGE_STANDARD = gnu99; 410 | GCC_DYNAMIC_NO_PIC = NO; 411 | GCC_OPTIMIZATION_LEVEL = 0; 412 | GCC_PREPROCESSOR_DEFINITIONS = ( 413 | "POD_CONFIGURATION_DEBUG=1", 414 | "DEBUG=1", 415 | "$(inherited)", 416 | ); 417 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 418 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 419 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 420 | GCC_WARN_UNDECLARED_SELECTOR = YES; 421 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 422 | GCC_WARN_UNUSED_FUNCTION = YES; 423 | GCC_WARN_UNUSED_VARIABLE = YES; 424 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 425 | ONLY_ACTIVE_ARCH = YES; 426 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; 427 | STRIP_INSTALLED_PRODUCT = NO; 428 | SYMROOT = "${SRCROOT}/../build"; 429 | }; 430 | name = Debug; 431 | }; 432 | 707B86CFB21B645E37109F39754D4051 /* Release */ = { 433 | isa = XCBuildConfiguration; 434 | buildSettings = { 435 | ALWAYS_SEARCH_USER_PATHS = NO; 436 | CLANG_ANALYZER_NONNULL = YES; 437 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES; 438 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 439 | CLANG_CXX_LIBRARY = "libc++"; 440 | CLANG_ENABLE_MODULES = YES; 441 | CLANG_ENABLE_OBJC_ARC = YES; 442 | CLANG_WARN_BOOL_CONVERSION = YES; 443 | CLANG_WARN_CONSTANT_CONVERSION = YES; 444 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES; 445 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 446 | CLANG_WARN_EMPTY_BODY = YES; 447 | CLANG_WARN_ENUM_CONVERSION = YES; 448 | CLANG_WARN_INFINITE_RECURSION = YES; 449 | CLANG_WARN_INT_CONVERSION = YES; 450 | CLANG_WARN_OBJC_ROOT_CLASS = YES; 451 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 452 | CLANG_WARN_UNREACHABLE_CODE = YES; 453 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 454 | CODE_SIGNING_REQUIRED = NO; 455 | COPY_PHASE_STRIP = YES; 456 | ENABLE_NS_ASSERTIONS = NO; 457 | GCC_C_LANGUAGE_STANDARD = gnu99; 458 | GCC_PREPROCESSOR_DEFINITIONS = ( 459 | "POD_CONFIGURATION_RELEASE=1", 460 | "$(inherited)", 461 | ); 462 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 463 | GCC_WARN_ABOUT_RETURN_TYPE = YES; 464 | GCC_WARN_UNDECLARED_SELECTOR = YES; 465 | GCC_WARN_UNINITIALIZED_AUTOS = YES; 466 | GCC_WARN_UNUSED_FUNCTION = YES; 467 | GCC_WARN_UNUSED_VARIABLE = YES; 468 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 469 | PROVISIONING_PROFILE_SPECIFIER = NO_SIGNING/; 470 | STRIP_INSTALLED_PRODUCT = NO; 471 | SYMROOT = "${SRCROOT}/../build"; 472 | VALIDATE_PRODUCT = YES; 473 | }; 474 | name = Release; 475 | }; 476 | 929380873F8272EFD771DD213974C720 /* Debug */ = { 477 | isa = XCBuildConfiguration; 478 | baseConfigurationReference = F89E35238A2BADBCFBA5F64E097DAD96 /* Pods-PlaceholderViewExample.debug.xcconfig */; 479 | buildSettings = { 480 | CODE_SIGN_IDENTITY = ""; 481 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 482 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 483 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 484 | CURRENT_PROJECT_VERSION = 1; 485 | DEBUG_INFORMATION_FORMAT = dwarf; 486 | DEFINES_MODULE = YES; 487 | DYLIB_COMPATIBILITY_VERSION = 1; 488 | DYLIB_CURRENT_VERSION = 1; 489 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 490 | ENABLE_STRICT_OBJC_MSGSEND = YES; 491 | GCC_NO_COMMON_BLOCKS = YES; 492 | INFOPLIST_FILE = "Target Support Files/Pods-PlaceholderViewExample/Info.plist"; 493 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 494 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 495 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 496 | MACH_O_TYPE = staticlib; 497 | MODULEMAP_FILE = "Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.modulemap"; 498 | MTL_ENABLE_DEBUG_INFO = YES; 499 | OTHER_LDFLAGS = ""; 500 | OTHER_LIBTOOLFLAGS = ""; 501 | PODS_ROOT = "$(SRCROOT)"; 502 | PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.${PRODUCT_NAME:rfc1034identifier}"; 503 | PRODUCT_NAME = Pods_PlaceholderViewExample; 504 | SDKROOT = iphoneos; 505 | SKIP_INSTALL = YES; 506 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 507 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 508 | SWIFT_VERSION = 3.0; 509 | TARGETED_DEVICE_FAMILY = "1,2"; 510 | VERSIONING_SYSTEM = "apple-generic"; 511 | VERSION_INFO_PREFIX = ""; 512 | }; 513 | name = Debug; 514 | }; 515 | E1EE461F2D28C6BB4D546839868CE951 /* Release */ = { 516 | isa = XCBuildConfiguration; 517 | baseConfigurationReference = 26273B376DD81763D26268341E432734 /* SlidingGradientView.xcconfig */; 518 | buildSettings = { 519 | CODE_SIGN_IDENTITY = ""; 520 | "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; 521 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; 522 | "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; 523 | CURRENT_PROJECT_VERSION = 1; 524 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 525 | DEFINES_MODULE = YES; 526 | DYLIB_COMPATIBILITY_VERSION = 1; 527 | DYLIB_CURRENT_VERSION = 1; 528 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 529 | ENABLE_STRICT_OBJC_MSGSEND = YES; 530 | GCC_NO_COMMON_BLOCKS = YES; 531 | GCC_PREFIX_HEADER = "Target Support Files/SlidingGradientView/SlidingGradientView-prefix.pch"; 532 | INFOPLIST_FILE = "Target Support Files/SlidingGradientView/Info.plist"; 533 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 534 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 535 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 536 | MODULEMAP_FILE = "Target Support Files/SlidingGradientView/SlidingGradientView.modulemap"; 537 | MTL_ENABLE_DEBUG_INFO = NO; 538 | PRODUCT_NAME = SlidingGradientView; 539 | SDKROOT = iphoneos; 540 | SKIP_INSTALL = YES; 541 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 542 | SWIFT_VERSION = 3.0; 543 | TARGETED_DEVICE_FAMILY = "1,2"; 544 | VERSIONING_SYSTEM = "apple-generic"; 545 | VERSION_INFO_PREFIX = ""; 546 | }; 547 | name = Release; 548 | }; 549 | /* End XCBuildConfiguration section */ 550 | 551 | /* Begin XCConfigurationList section */ 552 | 17B823C9BF4C175C4F088585C70FA022 /* Build configuration list for PBXNativeTarget "Pods-PlaceholderViewExample" */ = { 553 | isa = XCConfigurationList; 554 | buildConfigurations = ( 555 | 929380873F8272EFD771DD213974C720 /* Debug */, 556 | 067E071992EA6570D6F3B82AFB092998 /* Release */, 557 | ); 558 | defaultConfigurationIsVisible = 0; 559 | defaultConfigurationName = Release; 560 | }; 561 | 2D8E8EC45A3A1A1D94AE762CB5028504 /* Build configuration list for PBXProject "Pods" */ = { 562 | isa = XCConfigurationList; 563 | buildConfigurations = ( 564 | 163D87BE96A63549B0EACF1CC31A2E90 /* Debug */, 565 | 707B86CFB21B645E37109F39754D4051 /* Release */, 566 | ); 567 | defaultConfigurationIsVisible = 0; 568 | defaultConfigurationName = Release; 569 | }; 570 | 508DE151B449A5F4C3EEB1CBCC1C3FB4 /* Build configuration list for PBXNativeTarget "SlidingGradientView" */ = { 571 | isa = XCConfigurationList; 572 | buildConfigurations = ( 573 | 1106BDF52E67A91B4DF42F60FE61ED34 /* Debug */, 574 | E1EE461F2D28C6BB4D546839868CE951 /* Release */, 575 | ); 576 | defaultConfigurationIsVisible = 0; 577 | defaultConfigurationName = Release; 578 | }; 579 | /* End XCConfigurationList section */ 580 | }; 581 | rootObject = D41D8CD98F00B204E9800998ECF8427E /* Project object */; 582 | } 583 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Pods.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/Pods-PlaceholderViewExample.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 34 | 35 | 45 | 46 | 52 | 53 | 54 | 55 | 56 | 57 | 63 | 64 | 66 | 67 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Pods.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/SlidingGradientView.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 32 | 33 | 43 | 44 | 45 | 46 | 52 | 53 | 55 | 56 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Pods.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | Pods-PlaceholderViewExample.xcscheme 8 | 9 | isShown 10 | 11 | 12 | SlidingGradientView.xcscheme 13 | 14 | isShown 15 | 16 | 17 | 18 | SuppressBuildableAutocreation 19 | 20 | 0EE717FD1528C7EA51501F0A9EF8E19C 21 | 22 | primary 23 | 24 | 25 | 76347100D6C484EA48BC121F62D24C44 26 | 27 | primary 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/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 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-acknowledgements.markdown: -------------------------------------------------------------------------------- 1 | # Acknowledgements 2 | This application makes use of the following third party libraries: 3 | 4 | ## SlidingGradientView 5 | 6 | Copyright (c) 2017 rockbruno 7 | 8 | Permission is hereby granted, free of charge, to any person obtaining a copy 9 | of this software and associated documentation files (the "Software"), to deal 10 | in the Software without restriction, including without limitation the rights 11 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 12 | copies of the Software, and to permit persons to whom the Software is 13 | furnished to do so, subject to the following conditions: 14 | 15 | The above copyright notice and this permission notice shall be included in 16 | all copies or substantial portions of the Software. 17 | 18 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 19 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 20 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 21 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 22 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 23 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 24 | THE SOFTWARE. 25 | 26 | Generated by CocoaPods - https://cocoapods.org 27 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-acknowledgements.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreferenceSpecifiers 6 | 7 | 8 | FooterText 9 | This application makes use of the following third party libraries: 10 | Title 11 | Acknowledgements 12 | Type 13 | PSGroupSpecifier 14 | 15 | 16 | FooterText 17 | Copyright (c) 2017 rockbruno <brunorochaesilva@gmail.com> 18 | 19 | Permission is hereby granted, free of charge, to any person obtaining a copy 20 | of this software and associated documentation files (the "Software"), to deal 21 | in the Software without restriction, including without limitation the rights 22 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 23 | copies of the Software, and to permit persons to whom the Software is 24 | furnished to do so, subject to the following conditions: 25 | 26 | The above copyright notice and this permission notice shall be included in 27 | all copies or substantial portions of the Software. 28 | 29 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 30 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 31 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 32 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 33 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 34 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 35 | THE SOFTWARE. 36 | 37 | License 38 | MIT 39 | Title 40 | SlidingGradientView 41 | Type 42 | PSGroupSpecifier 43 | 44 | 45 | FooterText 46 | Generated by CocoaPods - https://cocoapods.org 47 | Title 48 | 49 | Type 50 | PSGroupSpecifier 51 | 52 | 53 | StringsTable 54 | Acknowledgements 55 | Title 56 | Acknowledgements 57 | 58 | 59 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_Pods_PlaceholderViewExample : NSObject 3 | @end 4 | @implementation PodsDummy_Pods_PlaceholderViewExample 5 | @end 6 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-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/SlidingGradientView/SlidingGradientView.framework" 93 | fi 94 | if [[ "$CONFIGURATION" == "Release" ]]; then 95 | install_framework "$BUILT_PRODUCTS_DIR/SlidingGradientView/SlidingGradientView.framework" 96 | fi 97 | if [ "${COCOAPODS_PARALLEL_CODE_SIGN}" == "true" ]; then 98 | wait 99 | fi 100 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-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 | 4) 25 | TARGET_DEVICE_ARGS="--target-device watch" 26 | ;; 27 | *) 28 | TARGET_DEVICE_ARGS="--target-device mac" 29 | ;; 30 | esac 31 | 32 | install_resource() 33 | { 34 | if [[ "$1" = /* ]] ; then 35 | RESOURCE_PATH="$1" 36 | else 37 | RESOURCE_PATH="${PODS_ROOT}/$1" 38 | fi 39 | if [[ ! -e "$RESOURCE_PATH" ]] ; then 40 | cat << EOM 41 | error: Resource "$RESOURCE_PATH" not found. Run 'pod install' to update the copy resources script. 42 | EOM 43 | exit 1 44 | fi 45 | case $RESOURCE_PATH in 46 | *.storyboard) 47 | 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}" 48 | 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} 49 | ;; 50 | *.xib) 51 | echo "ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile ${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib $RESOURCE_PATH --sdk ${SDKROOT} ${TARGET_DEVICE_ARGS}" 52 | ibtool --reference-external-strings-file --errors --warnings --notices --minimum-deployment-target ${!DEPLOYMENT_TARGET_SETTING_NAME} --output-format human-readable-text --compile "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename \"$RESOURCE_PATH\" .xib`.nib" "$RESOURCE_PATH" --sdk "${SDKROOT}" ${TARGET_DEVICE_ARGS} 53 | ;; 54 | *.framework) 55 | echo "mkdir -p ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 56 | mkdir -p "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 57 | echo "rsync -av $RESOURCE_PATH ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 58 | rsync -av "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}" 59 | ;; 60 | *.xcdatamodel) 61 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH"`.mom\"" 62 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodel`.mom" 63 | ;; 64 | *.xcdatamodeld) 65 | echo "xcrun momc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd\"" 66 | xcrun momc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcdatamodeld`.momd" 67 | ;; 68 | *.xcmappingmodel) 69 | echo "xcrun mapc \"$RESOURCE_PATH\" \"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm\"" 70 | xcrun mapc "$RESOURCE_PATH" "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/`basename "$RESOURCE_PATH" .xcmappingmodel`.cdm" 71 | ;; 72 | *.xcassets) 73 | ABSOLUTE_XCASSET_FILE="$RESOURCE_PATH" 74 | XCASSET_FILES+=("$ABSOLUTE_XCASSET_FILE") 75 | ;; 76 | *) 77 | echo "$RESOURCE_PATH" 78 | echo "$RESOURCE_PATH" >> "$RESOURCES_TO_COPY" 79 | ;; 80 | esac 81 | } 82 | 83 | mkdir -p "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 84 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 85 | if [[ "${ACTION}" == "install" ]] && [[ "${SKIP_INSTALL}" == "NO" ]]; then 86 | mkdir -p "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 87 | rsync -avr --copy-links --no-relative --exclude '*/.svn/*' --files-from="$RESOURCES_TO_COPY" / "${INSTALL_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" 88 | fi 89 | rm -f "$RESOURCES_TO_COPY" 90 | 91 | if [[ -n "${WRAPPER_EXTENSION}" ]] && [ "`xcrun --find actool`" ] && [ -n "$XCASSET_FILES" ] 92 | then 93 | # Find all other xcassets (this unfortunately includes those of path pods and other targets). 94 | OTHER_XCASSETS=$(find "$PWD" -iname "*.xcassets" -type d) 95 | while read line; do 96 | if [[ $line != "${PODS_ROOT}*" ]]; then 97 | XCASSET_FILES+=("$line") 98 | fi 99 | done <<<"$OTHER_XCASSETS" 100 | 101 | 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}" 102 | fi 103 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample-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_PlaceholderViewExampleVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char Pods_PlaceholderViewExampleVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.debug.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/SlidingGradientView" 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/SlidingGradientView/SlidingGradientView.framework/Headers" 6 | OTHER_LDFLAGS = $(inherited) -framework "SlidingGradientView" 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_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.modulemap: -------------------------------------------------------------------------------- 1 | framework module Pods_PlaceholderViewExample { 2 | umbrella header "Pods-PlaceholderViewExample-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/Pods-PlaceholderViewExample/Pods-PlaceholderViewExample.release.xcconfig: -------------------------------------------------------------------------------- 1 | ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES 2 | FRAMEWORK_SEARCH_PATHS = $(inherited) "$PODS_CONFIGURATION_BUILD_DIR/SlidingGradientView" 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/SlidingGradientView/SlidingGradientView.framework/Headers" 6 | OTHER_LDFLAGS = $(inherited) -framework "SlidingGradientView" 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_PODFILE_DIR_PATH = ${SRCROOT}/. 11 | PODS_ROOT = ${SRCROOT}/Pods 12 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView/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.3 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | ${CURRENT_PROJECT_VERSION} 23 | NSPrincipalClass 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView/SlidingGradientView-dummy.m: -------------------------------------------------------------------------------- 1 | #import 2 | @interface PodsDummy_SlidingGradientView : NSObject 3 | @end 4 | @implementation PodsDummy_SlidingGradientView 5 | @end 6 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView/SlidingGradientView-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 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView/SlidingGradientView-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 SlidingGradientViewVersionNumber; 15 | FOUNDATION_EXPORT const unsigned char SlidingGradientViewVersionString[]; 16 | 17 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView/SlidingGradientView.modulemap: -------------------------------------------------------------------------------- 1 | framework module SlidingGradientView { 2 | umbrella header "SlidingGradientView-umbrella.h" 3 | 4 | export * 5 | module * { export * } 6 | } 7 | -------------------------------------------------------------------------------- /PlaceholderViewExample/Pods/Target Support Files/SlidingGradientView/SlidingGradientView.xcconfig: -------------------------------------------------------------------------------- 1 | CONFIGURATION_BUILD_DIR = $PODS_CONFIGURATION_BUILD_DIR/SlidingGradientView 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}/../.. 9 | PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier} 10 | SKIP_INSTALL = YES 11 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # SlidingGradientView 2 | 3 | [![Version](https://img.shields.io/cocoapods/v/SlidingGradientView.svg?style=flat)](http://cocoapods.org/pods/SlidingGradientView) 4 | [![License](https://img.shields.io/cocoapods/l/SlidingGradientView.svg?style=flat)](http://cocoapods.org/pods/SlidingGradientView) 5 | [![Platform](https://img.shields.io/cocoapods/p/SlidingGradientView.svg?style=flat)](http://cocoapods.org/pods/SlidingGradientView) 6 | 7 | SlidingGradientView adds a sliding gradient to images in order to give the impression that something is loading. This is mostly meant to be used with images that resemble placeholders. 8 | 9 | [![Loading](https://i.imgur.com/fARnxgL.gif)](http://cocoapods.org/pods/SlidingGradientView) 10 | 11 | # Usage 12 | ```swift 13 | let image = UIImage(named: "placeholderEvents") 14 | let placeholderView = SlidingGradientView(image: image) 15 | //addSubview and constraints 16 | placeholderView.startAnimating() 17 | ``` 18 | 19 | ## Customization 20 | 21 | By default, SlidingGradientView uses a gradient that starts and end at `RGB 248 248 248` and traverses 120% of the screen's bounds in 0.7 seconds. You can edit these properties by creating a `GradientProperties` object like this: 22 | 23 | ```swift 24 | //Use UIColor.white.withAlphaComponent(0) for transparency, not UiColor.clear! 25 | let gradientColors = [ 26 | GradientColor(color: UIColor.white.withAlphaComponent(0), location: 0), 27 | GradientColor(color: UIColor.red, location: 0.5), 28 | GradientColor(color: UIColor.white.withAlphaComponent(0), location: 1) 29 | ] 30 | let slidingProperties = SlidingProperties(fromX: 0, toX: 100, animationDuration: 3) 31 | let properties = GradientProperties(gradientWidth: 300, gradientColors: gradientColors, slidingProperties: slidingProperties) 32 | let placeHolder2 = SlidingGradientView(image: image, properties: properties) 33 | ``` 34 | 35 | 36 | # Installation 37 | 38 | ### CocoaPods 39 | 40 | ```ruby 41 | pod "SlidingGradientView" 42 | ``` 43 | 44 | ## Author 45 | 46 | rockbruno, brunorochaesilva@gmail.com 47 | 48 | ## License 49 | 50 | SlidingGradientView is available under the MIT license. See the LICENSE file for more info. 51 | -------------------------------------------------------------------------------- /SlidingGradientView.podspec: -------------------------------------------------------------------------------- 1 | Pod::Spec.new do |s| 2 | s.name = 'SlidingGradientView' 3 | s.version = '0.2.8' 4 | s.summary = 'Easily add sliding gradient effects to images. Meant to be used as loading placeholder views.' 5 | 6 | s.description = <<-DESC 7 | TODO: Add long description of the pod here. 8 | DESC 9 | 10 | s.homepage = 'https://github.com/rockbruno/SlidingGradientView' 11 | s.license = { :type => 'MIT', :file => 'LICENSE' } 12 | s.author = { 'rockbruno' => 'brunorochaesilva@gmail.com' } 13 | s.source = { :git => 'https://github.com/rockbruno/SlidingGradientView.git', :branch => "master", :tag => s.version.to_s } 14 | 15 | s.ios.deployment_target = '9.0' 16 | 17 | s.source_files = 'SlidingGradientView/Sources/**/*' 18 | 19 | end 20 | -------------------------------------------------------------------------------- /SlidingGradientView.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | FD2B520F1EC9F1CF00239581 /* SlidingProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD2B520E1EC9F1CF00239581 /* SlidingProperties.swift */; }; 11 | FD6A904D1EC8849F00AFFA47 /* SlidingGradientView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD6A904C1EC8849F00AFFA47 /* SlidingGradientView.swift */; }; 12 | FD6A904F1EC8852000AFFA47 /* GradientProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD6A904E1EC8852000AFFA47 /* GradientProperties.swift */; }; 13 | FD6A90511EC8858F00AFFA47 /* GradientColor.swift in Sources */ = {isa = PBXBuildFile; fileRef = FD6A90501EC8858F00AFFA47 /* GradientColor.swift */; }; 14 | /* End PBXBuildFile section */ 15 | 16 | /* Begin PBXFileReference section */ 17 | FD2B520E1EC9F1CF00239581 /* SlidingProperties.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SlidingProperties.swift; sourceTree = ""; }; 18 | FD6A90401EC8845F00AFFA47 /* SlidingGradientView.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = SlidingGradientView.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 19 | FD6A90441EC8845F00AFFA47 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 20 | FD6A904C1EC8849F00AFFA47 /* SlidingGradientView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SlidingGradientView.swift; sourceTree = ""; }; 21 | FD6A904E1EC8852000AFFA47 /* GradientProperties.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GradientProperties.swift; sourceTree = ""; }; 22 | FD6A90501EC8858F00AFFA47 /* GradientColor.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GradientColor.swift; sourceTree = ""; }; 23 | /* End PBXFileReference section */ 24 | 25 | /* Begin PBXFrameworksBuildPhase section */ 26 | FD6A903C1EC8845F00AFFA47 /* Frameworks */ = { 27 | isa = PBXFrameworksBuildPhase; 28 | buildActionMask = 2147483647; 29 | files = ( 30 | ); 31 | runOnlyForDeploymentPostprocessing = 0; 32 | }; 33 | /* End PBXFrameworksBuildPhase section */ 34 | 35 | /* Begin PBXGroup section */ 36 | FD6A90361EC8845F00AFFA47 = { 37 | isa = PBXGroup; 38 | children = ( 39 | FD6A90411EC8845F00AFFA47 /* Products */, 40 | FD6A90421EC8845F00AFFA47 /* SlidingGradientView */, 41 | ); 42 | sourceTree = ""; 43 | }; 44 | FD6A90411EC8845F00AFFA47 /* Products */ = { 45 | isa = PBXGroup; 46 | children = ( 47 | FD6A90401EC8845F00AFFA47 /* SlidingGradientView.framework */, 48 | ); 49 | name = Products; 50 | sourceTree = ""; 51 | }; 52 | FD6A90421EC8845F00AFFA47 /* SlidingGradientView */ = { 53 | isa = PBXGroup; 54 | children = ( 55 | FD6A904B1EC8848A00AFFA47 /* Sources */, 56 | FD6A90441EC8845F00AFFA47 /* Info.plist */, 57 | ); 58 | path = SlidingGradientView; 59 | sourceTree = ""; 60 | }; 61 | FD6A904B1EC8848A00AFFA47 /* Sources */ = { 62 | isa = PBXGroup; 63 | children = ( 64 | FD6A90501EC8858F00AFFA47 /* GradientColor.swift */, 65 | FD6A904E1EC8852000AFFA47 /* GradientProperties.swift */, 66 | FD6A904C1EC8849F00AFFA47 /* SlidingGradientView.swift */, 67 | FD2B520E1EC9F1CF00239581 /* SlidingProperties.swift */, 68 | ); 69 | path = Sources; 70 | sourceTree = ""; 71 | }; 72 | /* End PBXGroup section */ 73 | 74 | /* Begin PBXHeadersBuildPhase section */ 75 | FD6A903D1EC8845F00AFFA47 /* Headers */ = { 76 | isa = PBXHeadersBuildPhase; 77 | buildActionMask = 2147483647; 78 | files = ( 79 | ); 80 | runOnlyForDeploymentPostprocessing = 0; 81 | }; 82 | /* End PBXHeadersBuildPhase section */ 83 | 84 | /* Begin PBXNativeTarget section */ 85 | FD6A903F1EC8845F00AFFA47 /* SlidingGradientView */ = { 86 | isa = PBXNativeTarget; 87 | buildConfigurationList = FD6A90481EC8845F00AFFA47 /* Build configuration list for PBXNativeTarget "SlidingGradientView" */; 88 | buildPhases = ( 89 | FD6A903B1EC8845F00AFFA47 /* Sources */, 90 | FD6A903C1EC8845F00AFFA47 /* Frameworks */, 91 | FD6A903D1EC8845F00AFFA47 /* Headers */, 92 | FD6A903E1EC8845F00AFFA47 /* Resources */, 93 | ); 94 | buildRules = ( 95 | ); 96 | dependencies = ( 97 | ); 98 | name = SlidingGradientView; 99 | productName = PlaceholderLoadingView; 100 | productReference = FD6A90401EC8845F00AFFA47 /* SlidingGradientView.framework */; 101 | productType = "com.apple.product-type.framework"; 102 | }; 103 | /* End PBXNativeTarget section */ 104 | 105 | /* Begin PBXProject section */ 106 | FD6A90371EC8845F00AFFA47 /* Project object */ = { 107 | isa = PBXProject; 108 | attributes = { 109 | LastUpgradeCheck = 0900; 110 | ORGANIZATIONNAME = "Bruno Rocha"; 111 | TargetAttributes = { 112 | FD6A903F1EC8845F00AFFA47 = { 113 | CreatedOnToolsVersion = 8.3; 114 | DevelopmentTeam = 3PG7SEBUB3; 115 | LastSwiftMigration = 0900; 116 | ProvisioningStyle = Automatic; 117 | }; 118 | }; 119 | }; 120 | buildConfigurationList = FD6A903A1EC8845F00AFFA47 /* Build configuration list for PBXProject "SlidingGradientView" */; 121 | compatibilityVersion = "Xcode 3.2"; 122 | developmentRegion = English; 123 | hasScannedForEncodings = 0; 124 | knownRegions = ( 125 | en, 126 | ); 127 | mainGroup = FD6A90361EC8845F00AFFA47; 128 | productRefGroup = FD6A90411EC8845F00AFFA47 /* Products */; 129 | projectDirPath = ""; 130 | projectRoot = ""; 131 | targets = ( 132 | FD6A903F1EC8845F00AFFA47 /* SlidingGradientView */, 133 | ); 134 | }; 135 | /* End PBXProject section */ 136 | 137 | /* Begin PBXResourcesBuildPhase section */ 138 | FD6A903E1EC8845F00AFFA47 /* Resources */ = { 139 | isa = PBXResourcesBuildPhase; 140 | buildActionMask = 2147483647; 141 | files = ( 142 | ); 143 | runOnlyForDeploymentPostprocessing = 0; 144 | }; 145 | /* End PBXResourcesBuildPhase section */ 146 | 147 | /* Begin PBXSourcesBuildPhase section */ 148 | FD6A903B1EC8845F00AFFA47 /* Sources */ = { 149 | isa = PBXSourcesBuildPhase; 150 | buildActionMask = 2147483647; 151 | files = ( 152 | FD6A90511EC8858F00AFFA47 /* GradientColor.swift in Sources */, 153 | FD2B520F1EC9F1CF00239581 /* SlidingProperties.swift in Sources */, 154 | FD6A904D1EC8849F00AFFA47 /* SlidingGradientView.swift in Sources */, 155 | FD6A904F1EC8852000AFFA47 /* GradientProperties.swift in Sources */, 156 | ); 157 | runOnlyForDeploymentPostprocessing = 0; 158 | }; 159 | /* End PBXSourcesBuildPhase section */ 160 | 161 | /* Begin XCBuildConfiguration section */ 162 | FD6A90461EC8845F00AFFA47 /* Debug */ = { 163 | isa = XCBuildConfiguration; 164 | buildSettings = { 165 | ALWAYS_SEARCH_USER_PATHS = NO; 166 | CLANG_ANALYZER_NONNULL = YES; 167 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 168 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 169 | CLANG_CXX_LIBRARY = "libc++"; 170 | CLANG_ENABLE_MODULES = YES; 171 | CLANG_ENABLE_OBJC_ARC = YES; 172 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 173 | CLANG_WARN_BOOL_CONVERSION = YES; 174 | CLANG_WARN_COMMA = YES; 175 | CLANG_WARN_CONSTANT_CONVERSION = YES; 176 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 177 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 178 | CLANG_WARN_EMPTY_BODY = YES; 179 | CLANG_WARN_ENUM_CONVERSION = YES; 180 | CLANG_WARN_INFINITE_RECURSION = YES; 181 | CLANG_WARN_INT_CONVERSION = YES; 182 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 183 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 184 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 185 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 186 | CLANG_WARN_STRICT_PROTOTYPES = YES; 187 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 188 | CLANG_WARN_UNREACHABLE_CODE = YES; 189 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 190 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 191 | COPY_PHASE_STRIP = NO; 192 | CURRENT_PROJECT_VERSION = 1; 193 | DEBUG_INFORMATION_FORMAT = dwarf; 194 | ENABLE_STRICT_OBJC_MSGSEND = YES; 195 | ENABLE_TESTABILITY = YES; 196 | GCC_C_LANGUAGE_STANDARD = gnu99; 197 | GCC_DYNAMIC_NO_PIC = NO; 198 | GCC_NO_COMMON_BLOCKS = YES; 199 | GCC_OPTIMIZATION_LEVEL = 0; 200 | GCC_PREPROCESSOR_DEFINITIONS = ( 201 | "DEBUG=1", 202 | "$(inherited)", 203 | ); 204 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 205 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 206 | GCC_WARN_UNDECLARED_SELECTOR = YES; 207 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 208 | GCC_WARN_UNUSED_FUNCTION = YES; 209 | GCC_WARN_UNUSED_VARIABLE = YES; 210 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 211 | MTL_ENABLE_DEBUG_INFO = YES; 212 | ONLY_ACTIVE_ARCH = YES; 213 | SDKROOT = iphoneos; 214 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 215 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 216 | SWIFT_SWIFT3_OBJC_INFERENCE = Off; 217 | SWIFT_VERSION = 4.0; 218 | TARGETED_DEVICE_FAMILY = "1,2"; 219 | VERSIONING_SYSTEM = "apple-generic"; 220 | VERSION_INFO_PREFIX = ""; 221 | }; 222 | name = Debug; 223 | }; 224 | FD6A90471EC8845F00AFFA47 /* Release */ = { 225 | isa = XCBuildConfiguration; 226 | buildSettings = { 227 | ALWAYS_SEARCH_USER_PATHS = NO; 228 | CLANG_ANALYZER_NONNULL = YES; 229 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 230 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 231 | CLANG_CXX_LIBRARY = "libc++"; 232 | CLANG_ENABLE_MODULES = YES; 233 | CLANG_ENABLE_OBJC_ARC = YES; 234 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 235 | CLANG_WARN_BOOL_CONVERSION = YES; 236 | CLANG_WARN_COMMA = YES; 237 | CLANG_WARN_CONSTANT_CONVERSION = YES; 238 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 239 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 240 | CLANG_WARN_EMPTY_BODY = YES; 241 | CLANG_WARN_ENUM_CONVERSION = YES; 242 | CLANG_WARN_INFINITE_RECURSION = YES; 243 | CLANG_WARN_INT_CONVERSION = YES; 244 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 245 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 246 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 247 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 248 | CLANG_WARN_STRICT_PROTOTYPES = YES; 249 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 250 | CLANG_WARN_UNREACHABLE_CODE = YES; 251 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 252 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 253 | COPY_PHASE_STRIP = NO; 254 | CURRENT_PROJECT_VERSION = 1; 255 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 256 | ENABLE_NS_ASSERTIONS = NO; 257 | ENABLE_STRICT_OBJC_MSGSEND = YES; 258 | GCC_C_LANGUAGE_STANDARD = gnu99; 259 | GCC_NO_COMMON_BLOCKS = YES; 260 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 261 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 262 | GCC_WARN_UNDECLARED_SELECTOR = YES; 263 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 264 | GCC_WARN_UNUSED_FUNCTION = YES; 265 | GCC_WARN_UNUSED_VARIABLE = YES; 266 | IPHONEOS_DEPLOYMENT_TARGET = 10.3; 267 | MTL_ENABLE_DEBUG_INFO = NO; 268 | SDKROOT = iphoneos; 269 | SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; 270 | SWIFT_SWIFT3_OBJC_INFERENCE = Off; 271 | SWIFT_VERSION = 4.0; 272 | TARGETED_DEVICE_FAMILY = "1,2"; 273 | VALIDATE_PRODUCT = YES; 274 | VERSIONING_SYSTEM = "apple-generic"; 275 | VERSION_INFO_PREFIX = ""; 276 | }; 277 | name = Release; 278 | }; 279 | FD6A90491EC8845F00AFFA47 /* Debug */ = { 280 | isa = XCBuildConfiguration; 281 | buildSettings = { 282 | CLANG_ENABLE_MODULES = YES; 283 | CODE_SIGN_IDENTITY = ""; 284 | DEFINES_MODULE = YES; 285 | DEVELOPMENT_TEAM = 3PG7SEBUB3; 286 | DYLIB_COMPATIBILITY_VERSION = 1; 287 | DYLIB_CURRENT_VERSION = 1; 288 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 289 | INFOPLIST_FILE = SlidingGradientView/Info.plist; 290 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 291 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 292 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 293 | PRODUCT_BUNDLE_IDENTIFIER = com.rockbruno.SlidingGradientView; 294 | PRODUCT_NAME = "$(TARGET_NAME)"; 295 | SKIP_INSTALL = YES; 296 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 297 | SWIFT_SWIFT3_OBJC_INFERENCE = On; 298 | SWIFT_VERSION = 4.0; 299 | }; 300 | name = Debug; 301 | }; 302 | FD6A904A1EC8845F00AFFA47 /* Release */ = { 303 | isa = XCBuildConfiguration; 304 | buildSettings = { 305 | CLANG_ENABLE_MODULES = YES; 306 | CODE_SIGN_IDENTITY = ""; 307 | DEFINES_MODULE = YES; 308 | DEVELOPMENT_TEAM = 3PG7SEBUB3; 309 | DYLIB_COMPATIBILITY_VERSION = 1; 310 | DYLIB_CURRENT_VERSION = 1; 311 | DYLIB_INSTALL_NAME_BASE = "@rpath"; 312 | INFOPLIST_FILE = SlidingGradientView/Info.plist; 313 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; 314 | IPHONEOS_DEPLOYMENT_TARGET = 9.0; 315 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 316 | PRODUCT_BUNDLE_IDENTIFIER = com.rockbruno.SlidingGradientView; 317 | PRODUCT_NAME = "$(TARGET_NAME)"; 318 | SKIP_INSTALL = YES; 319 | SWIFT_SWIFT3_OBJC_INFERENCE = On; 320 | SWIFT_VERSION = 4.0; 321 | }; 322 | name = Release; 323 | }; 324 | /* End XCBuildConfiguration section */ 325 | 326 | /* Begin XCConfigurationList section */ 327 | FD6A903A1EC8845F00AFFA47 /* Build configuration list for PBXProject "SlidingGradientView" */ = { 328 | isa = XCConfigurationList; 329 | buildConfigurations = ( 330 | FD6A90461EC8845F00AFFA47 /* Debug */, 331 | FD6A90471EC8845F00AFFA47 /* Release */, 332 | ); 333 | defaultConfigurationIsVisible = 0; 334 | defaultConfigurationName = Release; 335 | }; 336 | FD6A90481EC8845F00AFFA47 /* Build configuration list for PBXNativeTarget "SlidingGradientView" */ = { 337 | isa = XCConfigurationList; 338 | buildConfigurations = ( 339 | FD6A90491EC8845F00AFFA47 /* Debug */, 340 | FD6A904A1EC8845F00AFFA47 /* Release */, 341 | ); 342 | defaultConfigurationIsVisible = 0; 343 | defaultConfigurationName = Release; 344 | }; 345 | /* End XCConfigurationList section */ 346 | }; 347 | rootObject = FD6A90371EC8845F00AFFA47 /* Project object */; 348 | } 349 | -------------------------------------------------------------------------------- /SlidingGradientView.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /SlidingGradientView.xcodeproj/project.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rockbruno/SlidingGradientView/0557b6f7947bf7275064316e281a688053146cef/SlidingGradientView.xcodeproj/project.xcworkspace/xcuserdata/bruno.rocha.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /SlidingGradientView.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/SlidingGradientView.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 31 | 32 | 33 | 34 | 35 | 36 | 47 | 48 | 54 | 55 | 56 | 57 | 58 | 59 | 65 | 66 | 72 | 73 | 74 | 75 | 77 | 78 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /SlidingGradientView.xcodeproj/xcuserdata/bruno.rocha.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | SlidingGradientView.xcscheme 8 | 9 | orderHint 10 | 0 11 | 12 | 13 | SuppressBuildableAutocreation 14 | 15 | FD6A903F1EC8845F00AFFA47 16 | 17 | primary 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /SlidingGradientView/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 19 | CFBundleVersion 20 | $(CURRENT_PROJECT_VERSION) 21 | NSPrincipalClass 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /SlidingGradientView/Sources/GradientColor.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | 3 | public struct GradientColor { 4 | let color: UIColor 5 | let location: NSNumber 6 | 7 | public init(color: UIColor, location: NSNumber) { 8 | self.color = color 9 | self.location = location 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /SlidingGradientView/Sources/GradientProperties.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | 3 | public struct GradientProperties { 4 | let gradientWidth: CGFloat 5 | let gradientColors: [GradientColor] 6 | let slidingProperties: SlidingProperties 7 | 8 | public init(gradientWidth: CGFloat = defaultGradientWidth, 9 | gradientColors: [GradientColor] = defaultGradientColors, 10 | slidingProperties: SlidingProperties = defaultSlidingProperties) { 11 | self.gradientWidth = gradientWidth 12 | self.gradientColors = gradientColors 13 | self.slidingProperties = slidingProperties 14 | } 15 | 16 | public init() { 17 | self.init(gradientWidth: GradientProperties.defaultGradientWidth, 18 | gradientColors: GradientProperties.defaultGradientColors, 19 | slidingProperties: GradientProperties.defaultSlidingProperties) 20 | } 21 | 22 | public static let defaultGradientWidth = UIScreen.main.bounds.width / 2.2 23 | public static let defaultGradientColors = [ 24 | GradientColor( 25 | color: 26 | UIColor(red: 241.0 / 255.0, 27 | green: 241.0 / 255.0, 28 | blue: 241.0 / 255.0, 29 | alpha: 1.0), 30 | location: 0), 31 | GradientColor( 32 | color: 33 | UIColor(red: 246.0 / 255.0, 34 | green: 246.0 / 255.0, 35 | blue: 246.0 / 255.0, 36 | alpha: 1.0), 37 | location: 0.25), 38 | GradientColor( 39 | color: 40 | UIColor(red: 248.0 / 255.0, 41 | green: 248.0 / 255.0, 42 | blue: 248.0 / 255.0, 43 | alpha: 1.0), 44 | location: 0.50), 45 | GradientColor( 46 | color: 47 | UIColor(red: 246.0 / 255.0, 48 | green: 246.0 / 255.0, 49 | blue: 246.0 / 255.0, 50 | alpha: 1.0), 51 | location: 0.75), 52 | GradientColor( 53 | color: 54 | UIColor(red: 241.0 / 255.0, 55 | green: 241.0 / 255.0, 56 | blue: 241.0 / 255.0, 57 | alpha: 1.0), 58 | location: 1.0) 59 | ] 60 | public static let defaultSlidingProperties = SlidingProperties() 61 | } 62 | -------------------------------------------------------------------------------- /SlidingGradientView/Sources/SlidingGradientView.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | 3 | private struct Strings { 4 | static let position = "position" 5 | static let animationKey = "slide" 6 | } 7 | 8 | open class SlidingGradientView: UIImageView { 9 | 10 | let gradientWidth: CGFloat 11 | let slidingProperties: SlidingProperties 12 | 13 | private var layerPositionOffset: CGFloat = 0 14 | 15 | private let gradientLayer: CAGradientLayer = { 16 | let gradient = CAGradientLayer() 17 | gradient.startPoint = CGPoint(x: 0, y: 1) 18 | gradient.endPoint = CGPoint(x: 1, y: 1) 19 | gradient.colors = [] 20 | gradient.locations = [] 21 | gradient.isOpaque = true 22 | gradient.isHidden = true 23 | return gradient 24 | }() 25 | 26 | private let gradientView: UIView = UIView() 27 | private let gradientMaskView: UIImageView = UIImageView() 28 | 29 | public init(image: UIImage?, properties: GradientProperties = .init()) { 30 | gradientWidth = properties.gradientWidth 31 | slidingProperties = properties.slidingProperties 32 | super.init(image: image) 33 | properties.gradientColors.forEach { 34 | gradientLayer.colors?.append($0.color.cgColor) 35 | gradientLayer.locations?.append($0.location) 36 | } 37 | setUp() 38 | } 39 | 40 | required public init(coder aDecoder: NSCoder) { 41 | fatalError() 42 | } 43 | 44 | private func setUp() { 45 | setupMaskView() 46 | setupGradientView() 47 | setupLayer() 48 | } 49 | 50 | private func setupMaskView() { 51 | addSubview(gradientMaskView) 52 | gradientMaskView.image = image 53 | } 54 | 55 | private func setupGradientView() { 56 | addSubview(gradientView) 57 | constrainEdges(gradientView, self) 58 | } 59 | 60 | private func constrainEdges(_ v1: UIView, _ v2: UIView) { 61 | v1.translatesAutoresizingMaskIntoConstraints = false 62 | NSLayoutConstraint.activate([ 63 | v1.topAnchor.constraint(equalTo: v2.topAnchor), 64 | v1.leftAnchor.constraint(equalTo: v2.leftAnchor), 65 | v1.rightAnchor.constraint(equalTo: v2.rightAnchor), 66 | v1.bottomAnchor.constraint(equalTo: v2.bottomAnchor) 67 | ]) 68 | } 69 | 70 | private func setupLayer() { 71 | gradientView.layer.insertSublayer(gradientLayer, at: 0) 72 | gradientView.layer.mask = gradientMaskView.layer 73 | } 74 | 75 | override open func layoutSublayers(of layer: CALayer) { 76 | super.layoutSublayers(of: layer) 77 | gradientLayer.frame = CGRect(x: 0, y: 0, width: gradientWidth, height: gradientView.frame.size.height) 78 | layerPositionOffset = gradientLayer.position.x 79 | gradientLayer.position.x = -layerPositionOffset 80 | } 81 | 82 | override open func layoutSubviews() { 83 | super.layoutSubviews() 84 | //Can't constrain masks. 85 | gradientMaskView.frame = self.bounds 86 | } 87 | 88 | open override func startAnimating() { 89 | guard gradientLayer.animationKeys()?.contains(Strings.animationKey) != true else { 90 | return 91 | } 92 | alpha = 1.0 93 | gradientLayer.isHidden = false 94 | updateConstraintsIfNeeded() 95 | layoutIfNeeded() 96 | addAnimation() 97 | } 98 | 99 | private func addAnimation() { 100 | let positionAnimation = CABasicAnimation(keyPath: Strings.position) 101 | let fromX = slidingProperties.fromX - layerPositionOffset 102 | let fromY = gradientLayer.position.y 103 | positionAnimation.fromValue = CGPoint(x: fromX, y: fromY) 104 | let toX = slidingProperties.toX + layerPositionOffset 105 | let toY = gradientLayer.position.y 106 | positionAnimation.toValue = CGPoint(x: toX, y: toY) 107 | positionAnimation.duration = slidingProperties.animationDuration 108 | positionAnimation.repeatCount = .infinity 109 | positionAnimation.isRemovedOnCompletion = false 110 | gradientLayer.add(positionAnimation, forKey: Strings.animationKey) 111 | } 112 | 113 | open override func stopAnimating() { 114 | stopAnimating(fadeOut: false) 115 | } 116 | 117 | public func stopAnimating(fadeOut: Bool = false, completion: (() -> Void)? = nil) { 118 | guard gradientLayer.isHidden == false else { 119 | return 120 | } 121 | if fadeOut { 122 | UIView.animate(withDuration: 0.3, animations: { [weak self] in 123 | self?.alpha = 0.0 124 | }, completion: { [weak self] _ in 125 | self?.removeAnimationsAndHide(completion) 126 | }) 127 | } else { 128 | removeAnimationsAndHide(completion) 129 | } 130 | } 131 | 132 | private func removeAnimationsAndHide(_ completion: (() -> Void)? = nil) { 133 | gradientLayer.position.x = -layerPositionOffset 134 | gradientLayer.removeAnimation(forKey: Strings.animationKey) 135 | gradientLayer.isHidden = true 136 | completion?() 137 | } 138 | } 139 | -------------------------------------------------------------------------------- /SlidingGradientView/Sources/SlidingProperties.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | 3 | public struct SlidingProperties { 4 | let fromX: CGFloat 5 | let toX: CGFloat 6 | let animationDuration: TimeInterval 7 | 8 | public init(fromX: CGFloat = 0, toX: CGFloat = UIScreen.main.bounds.width * 1.2, animationDuration: TimeInterval = 0.7) { 9 | self.fromX = fromX 10 | self.toX = toX 11 | self.animationDuration = animationDuration 12 | } 13 | } 14 | --------------------------------------------------------------------------------