Skip to content

Commit 55c384f

Browse files
Merge pull request #19 from simformsolutions/develop
Develop
2 parents 9d5212d + 27a41d7 commit 55c384f

File tree

8 files changed

+24
-26
lines changed

8 files changed

+24
-26
lines changed

SSSpinnerButton.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
Pod::Spec.new do |s|
1010
s.name = "SSSpinnerButton"
11-
s.version = "1.1.2"
11+
s.version = "2.0.0"
1212
s.summary = "SSSpinnerButton is an elegant button with a different spinner animations."
1313

1414
#s.description = "SSSpinnerButton is an elegant button with a different spinner animations."

SSSpinnerButton.xcodeproj/project.pbxproj

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
objects = {
88

99
/* Begin PBXBuildFile section */
10-
5189267820C96E9F0016E3A0 /* SSFailMark.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5189267720C96E9F0016E3A0 /* SSFailMark.swift */; };
1110
519A451320C6A15D00BD9352 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 51AAA5DC20C64ED3000F4BCD /* Main.storyboard */; };
11+
519BCB68219A946600F50E26 /* SSFailMark.swift in Sources */ = {isa = PBXBuildFile; fileRef = 519BCB67219A946600F50E26 /* SSFailMark.swift */; };
1212
51AAA5D920C64ED3000F4BCD /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 51AAA5D820C64ED3000F4BCD /* AppDelegate.swift */; };
1313
51AAA5DB20C64ED3000F4BCD /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 51AAA5DA20C64ED3000F4BCD /* ViewController.swift */; };
1414
51AAA5E020C64ED3000F4BCD /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 51AAA5DF20C64ED3000F4BCD /* Assets.xcassets */; };
@@ -30,7 +30,7 @@
3030
/* End PBXBuildFile section */
3131

3232
/* Begin PBXFileReference section */
33-
5189267720C96E9F0016E3A0 /* SSFailMark.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = SSFailMark.swift; path = SSSpinnerButton/SSSpinnerButton/SpinerShapes/SSFailMark.swift; sourceTree = SOURCE_ROOT; };
33+
519BCB67219A946600F50E26 /* SSFailMark.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SSFailMark.swift; sourceTree = "<group>"; };
3434
51AAA5D520C64ED3000F4BCD /* SSSpinnerButton.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SSSpinnerButton.app; sourceTree = BUILT_PRODUCTS_DIR; };
3535
51AAA5D820C64ED3000F4BCD /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
3636
51AAA5DA20C64ED3000F4BCD /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
@@ -129,12 +129,12 @@
129129
51AAA5F020C64EF0000F4BCD /* SpinnerShapeWithAnimation */ = {
130130
isa = PBXGroup;
131131
children = (
132+
519BCB67219A946600F50E26 /* SSFailMark.swift */,
132133
51AAA5F120C64EF0000F4BCD /* SSBallRotateChase.swift */,
133134
51AAA5F220C64EF0000F4BCD /* SSBallSpinFadeLoader.swift */,
134135
51AAA5F320C64EF0000F4BCD /* SSCircleStrokeSpin.swift */,
135136
51AAA5F420C64EF0000F4BCD /* SSLineSpinFadeLoader.swift */,
136137
51AAA5F520C64EF0000F4BCD /* SSSpinnerBallClipRotate.swift */,
137-
5189267720C96E9F0016E3A0 /* SSFailMark.swift */,
138138
730FA84E2136AD4800F6116F /* SSSuccessMark.swift */,
139139
737852F82137B12B005A1EA6 /* SSErrorMark.swift */,
140140
);
@@ -177,11 +177,12 @@
177177
isa = PBXProject;
178178
attributes = {
179179
LastSwiftUpdateCheck = 0920;
180-
LastUpgradeCheck = 0920;
180+
LastUpgradeCheck = 0940;
181181
ORGANIZATIONNAME = "Simform Solutions";
182182
TargetAttributes = {
183183
51AAA5D420C64ED3000F4BCD = {
184184
CreatedOnToolsVersion = 9.2;
185+
LastSwiftMigration = 1010;
185186
ProvisioningStyle = Automatic;
186187
};
187188
};
@@ -248,12 +249,12 @@
248249
51AAA5D920C64ED3000F4BCD /* AppDelegate.swift in Sources */,
249250
51AAA5FB20C64EF0000F4BCD /* spinnerShape.swift in Sources */,
250251
51AAA60220C64EF0000F4BCD /* SSSpinnerButton.swift in Sources */,
252+
519BCB68219A946600F50E26 /* SSFailMark.swift in Sources */,
251253
51AAA5FE20C64EF0000F4BCD /* SSCircleStrokeSpin.swift in Sources */,
252254
51AAA5FD20C64EF0000F4BCD /* SSBallSpinFadeLoader.swift in Sources */,
253255
51AAA60120C64EF0000F4BCD /* SpinnerTypes.swift in Sources */,
254256
737852FB2137C745005A1EA6 /* Extensions.swift in Sources */,
255257
51AAA5FF20C64EF0000F4BCD /* SSLineSpinFadeLoader.swift in Sources */,
256-
5189267820C96E9F0016E3A0 /* SSFailMark.swift in Sources */,
257258
51AAA5F920C64EF0000F4BCD /* SpinnerAnimationDelegate.swift in Sources */,
258259
51AAA60020C64EF0000F4BCD /* SSSpinnerBallClipRotate.swift in Sources */,
259260
);
@@ -295,13 +296,15 @@
295296
CLANG_WARN_BOOL_CONVERSION = YES;
296297
CLANG_WARN_COMMA = YES;
297298
CLANG_WARN_CONSTANT_CONVERSION = YES;
299+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
298300
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
299301
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
300302
CLANG_WARN_EMPTY_BODY = YES;
301303
CLANG_WARN_ENUM_CONVERSION = YES;
302304
CLANG_WARN_INFINITE_RECURSION = YES;
303305
CLANG_WARN_INT_CONVERSION = YES;
304306
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
307+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
305308
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
306309
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
307310
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
@@ -352,13 +355,15 @@
352355
CLANG_WARN_BOOL_CONVERSION = YES;
353356
CLANG_WARN_COMMA = YES;
354357
CLANG_WARN_CONSTANT_CONVERSION = YES;
358+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
355359
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
356360
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
357361
CLANG_WARN_EMPTY_BODY = YES;
358362
CLANG_WARN_ENUM_CONVERSION = YES;
359363
CLANG_WARN_INFINITE_RECURSION = YES;
360364
CLANG_WARN_INT_CONVERSION = YES;
361365
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
366+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
362367
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
363368
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
364369
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
@@ -399,7 +404,7 @@
399404
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
400405
PRODUCT_BUNDLE_IDENTIFIER = com.simform.SSSpinnerButton;
401406
PRODUCT_NAME = "$(TARGET_NAME)";
402-
SWIFT_VERSION = 4.0;
407+
SWIFT_VERSION = 4.2;
403408
TARGETED_DEVICE_FAMILY = "1,2";
404409
};
405410
name = Debug;
@@ -415,7 +420,7 @@
415420
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
416421
PRODUCT_BUNDLE_IDENTIFIER = com.simform.SSSpinnerButton;
417422
PRODUCT_NAME = "$(TARGET_NAME)";
418-
SWIFT_VERSION = 4.0;
423+
SWIFT_VERSION = 4.2;
419424
TARGETED_DEVICE_FAMILY = "1,2";
420425
};
421426
name = Release;
@@ -434,13 +439,15 @@
434439
CLANG_WARN_BOOL_CONVERSION = YES;
435440
CLANG_WARN_COMMA = YES;
436441
CLANG_WARN_CONSTANT_CONVERSION = YES;
442+
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
437443
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
438444
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
439445
CLANG_WARN_EMPTY_BODY = YES;
440446
CLANG_WARN_ENUM_CONVERSION = YES;
441447
CLANG_WARN_INFINITE_RECURSION = YES;
442448
CLANG_WARN_INT_CONVERSION = YES;
443449
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
450+
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
444451
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
445452
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
446453
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
@@ -488,7 +495,7 @@
488495
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
489496
PRODUCT_BUNDLE_IDENTIFIER = com.simform.SSSpinnerButton;
490497
PRODUCT_NAME = "$(TARGET_NAME)";
491-
SWIFT_VERSION = 4.0;
498+
SWIFT_VERSION = 4.2;
492499
TARGETED_DEVICE_FAMILY = "1,2";
493500
};
494501
name = Analyze;

SSSpinnerButton/AppDelegate.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
1414
var window: UIWindow?
1515

1616

17-
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
17+
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
1818
// Override point for customization after application launch.
1919
return true
2020
}

SSSpinnerButton/SSSpinnerButton/SpinerShapes/SpinnerShapeWithAnimation/SSBallSpinFadeLoader.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ class SSBallSpinFadeLoader: SSSpinnerAnimationDelegate {
5353
let animation = CAAnimationGroup()
5454

5555
animation.animations = [scaleAnimation, opacityAnimaton]
56-
animation.timingFunction = CAMediaTimingFunction(name: kCAMediaTimingFunctionLinear)
56+
animation.timingFunction = CAMediaTimingFunction(name: CAMediaTimingFunctionName.linear)
5757
animation.duration = duration
5858
animation.repeatCount = HUGE
5959
animation.isRemovedOnCompletion = false

SSSpinnerButton/SSSpinnerButton/SpinerShapes/SpinnerShapeWithAnimation/SSCircleStrokeSpin.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class SSCircleStrokeSpin: SSSpinnerAnimationDelegate {
3434

3535
let rotationAnimation = CABasicAnimation(keyPath: "transform.rotation")
3636
rotationAnimation.byValue = Float.pi * 2
37-
rotationAnimation.timingFunction = CAMediaTimingFunction(name: kCAMediaTimingFunctionLinear)
37+
rotationAnimation.timingFunction = CAMediaTimingFunction(name: CAMediaTimingFunctionName.linear)
3838

3939
let strokeEndAnimation = CABasicAnimation(keyPath: "strokeEnd")
4040
strokeEndAnimation.duration = strokeEndDuration
@@ -54,7 +54,7 @@ class SSCircleStrokeSpin: SSSpinnerAnimationDelegate {
5454
groupAnimation.duration = strokeStartDuration + beginTime
5555
groupAnimation.repeatCount = .infinity
5656
groupAnimation.isRemovedOnCompletion = false
57-
groupAnimation.fillMode = kCAFillModeForwards
57+
groupAnimation.fillMode = CAMediaTimingFillMode.forwards
5858

5959
let circle = SpinnerShape.stroke.layerWith(size: CGSize(width: sizeValue, height: sizeValue), color: color)
6060
let frame = CGRect(

SSSpinnerButton/SSSpinnerButton/SpinerShapes/SSFailMark.swift renamed to SSSpinnerButton/SSSpinnerButton/SpinerShapes/SpinnerShapeWithAnimation/SSFailMark.swift

File renamed without changes.

SSSpinnerButton/SSSpinnerButton/SpinerShapes/SpinnerShapeWithAnimation/SSLineSpinFadeLoader.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class SSLineSpinFadeLoader: SSSpinnerAnimationDelegate {
3232
let duration: CFTimeInterval = 1.2
3333
let beginTime = CACurrentMediaTime()
3434
let beginTimes: [CFTimeInterval] = [0.12, 0.24, 0.36, 0.48, 0.6, 0.72, 0.84, 0.96]
35-
let timingFunction = CAMediaTimingFunction(name: kCAMediaTimingFunctionEaseInEaseOut)
35+
let timingFunction = CAMediaTimingFunction(name: CAMediaTimingFunctionName.easeInEaseOut)
3636

3737
// Animation
3838
let animation = CAKeyframeAnimation(keyPath: "opacity")

SSSpinnerButton/SSSpinnerButton/SpinnerButton/SSSpinnerButton.swift

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ open class SSSpinnerButton: UIButton {
5555

5656
var spinnerSize: UInt?
5757
/// Sets the button title for its normal state
58+
5859
public var normalTitle: String? {
5960
get {
6061
return self.title(for: .normal)
@@ -131,16 +132,6 @@ open class SSSpinnerButton: UIButton {
131132
}
132133
}
133134

134-
/// Sets the button title color.
135-
public var titleColor: UIColor? {
136-
get {
137-
return self.titleColor
138-
}
139-
set {
140-
self.setTitleColor(newValue, for: .normal)
141-
}
142-
}
143-
144135
// MARK: - Initializers
145136
public required init(coder aDecoder: NSCoder) {
146137
super.init(coder: aDecoder)!
@@ -334,7 +325,7 @@ private extension SSSpinnerButton {
334325
animaton.fromValue = bounds.width
335326
animaton.toValue = bounds.height
336327
animaton.duration = animationDuration
337-
animaton.fillMode = kCAFillModeBoth
328+
animaton.fillMode = CAMediaTimingFillMode.both
338329
animaton.isRemovedOnCompletion = false
339330
if layer.sublayers != nil {
340331

@@ -433,7 +424,7 @@ private extension SSSpinnerButton {
433424
animation.fromValue = self.frame.height
434425
animation.toValue = self.frame.width
435426
animation.duration = self.animationDuration
436-
animation.fillMode = kCAFillModeForwards
427+
animation.fillMode = CAMediaTimingFillMode.forwards
437428
animation.isRemovedOnCompletion = false
438429

439430
self.layer.add(animation, forKey: animation.keyPath)

0 commit comments

Comments
 (0)