on 07616aa help sign in
.swift-version+1−1
since splitsnapshots
unifiedsplit
@@ -1 +1 @@
1−4.0
1+3.0
GMStepper.podspec+2−2
@@ -1,9 +1,9 @@
1Pod::Spec.new do |s|
1Pod::Spec.new do |s|
2 s.name = "GMStepper"
2 s.name = "GMStepper"
3− s.version = "2.1"
3+ s.version = "2.0.0"
4 s.summary = "A stepper with a sliding label in the middle."
4 s.summary = "A stepper with a sliding label in the middle."
5 s.homepage = "https://github.com/gmertk/GMStepper"
5 s.homepage = "https://github.com/gmertk/GMStepper"
6− s.screenshots = "https://raw.githubusercontent.com/gmertk/GMStepper/master/Screenshots/screenshot_1.gif"
6+ s.screenshots = "https://dl.dropboxusercontent.com/u/4397140/pod-screenshots/screenshot_1.png"
7 s.license = 'MIT'
7 s.license = 'MIT'
8 s.author = { "Gunay Mert Karadogan" => "mertkaradogan@gmail.com" }
8 s.author = { "Gunay Mert Karadogan" => "mertkaradogan@gmail.com" }
9 s.source = { :git => "https://github.com/gmertk/GMStepper.git", :tag => s.version.to_s }
9 s.source = { :git => "https://github.com/gmertk/GMStepper.git", :tag => s.version.to_s }
GMStepper/GMStepper.swift+28−37
@@ -11,7 +11,7 @@ import UIKit
11@IBDesignable public class GMStepper: UIControl {
11@IBDesignable public class GMStepper: UIControl {
12
12
13 /// Current value of the stepper. Defaults to 0.
13 /// Current value of the stepper. Defaults to 0.
14− @objc @IBInspectable public var value: Double = 0 {
14+ @IBInspectable public var value: Double = 0 {
15 didSet {
15 didSet {
16 value = min(maximumValue, max(minimumValue, value))
16 value = min(maximumValue, max(minimumValue, value))
17
17
@@ -37,44 +37,44 @@ import UIKit
37 }
37 }
38
38
39 /// Minimum value. Must be less than maximumValue. Defaults to 0.
39 /// Minimum value. Must be less than maximumValue. Defaults to 0.
40− @objc @IBInspectable public var minimumValue: Double = 0 {
40+ @IBInspectable public var minimumValue: Double = 0 {
41 didSet {
41 didSet {
42 value = min(maximumValue, max(minimumValue, value))
42 value = min(maximumValue, max(minimumValue, value))
43 }
43 }
44 }
44 }
45
45
46 /// Maximum value. Must be more than minimumValue. Defaults to 100.
46 /// Maximum value. Must be more than minimumValue. Defaults to 100.
47− @objc @IBInspectable public var maximumValue: Double = 100 {
47+ @IBInspectable public var maximumValue: Double = 100 {
48 didSet {
48 didSet {
49 value = min(maximumValue, max(minimumValue, value))
49 value = min(maximumValue, max(minimumValue, value))
50 }
50 }
51 }
51 }
52
52
53 /// Step/Increment value as in UIStepper. Defaults to 1.
53 /// Step/Increment value as in UIStepper. Defaults to 1.
54− @objc @IBInspectable public var stepValue: Double = 1
54+ @IBInspectable public var stepValue: Double = 1
55
55
56 /// The same as UIStepper's autorepeat. If true, holding on the buttons or keeping the pan gesture alters the value repeatedly. Defaults to true.
56 /// The same as UIStepper's autorepeat. If true, holding on the buttons or keeping the pan gesture alters the value repeatedly. Defaults to true.
57− @objc @IBInspectable public var autorepeat: Bool = true
57+ @IBInspectable public var autorepeat: Bool = true
58
58
59 /// If the value is integer, it is shown without floating point.
59 /// If the value is integer, it is shown without floating point.
60− @objc @IBInspectable public var showIntegerIfDoubleIsInteger: Bool = true
60+ @IBInspectable public var showIntegerIfDoubleIsInteger: Bool = true
61
61
62 /// Text on the left button. Be sure that it fits in the button. Defaults to "−".
62 /// Text on the left button. Be sure that it fits in the button. Defaults to "−".
63− @objc @IBInspectable public var leftButtonText: String = "−" {
63+ @IBInspectable public var leftButtonText: String = "−" {
64 didSet {
64 didSet {
65 leftButton.setTitle(leftButtonText, for: .normal)
65 leftButton.setTitle(leftButtonText, for: .normal)
66 }
66 }
67 }
67 }
68
68
69 /// Text on the right button. Be sure that it fits in the button. Defaults to "+".
69 /// Text on the right button. Be sure that it fits in the button. Defaults to "+".
70− @objc @IBInspectable public var rightButtonText: String = "+" {
70+ @IBInspectable public var rightButtonText: String = "+" {
71 didSet {
71 didSet {
72 rightButton.setTitle(rightButtonText, for: .normal)
72 rightButton.setTitle(rightButtonText, for: .normal)
73 }
73 }
74 }
74 }
75
75
76 /// Text color of the buttons. Defaults to white.
76 /// Text color of the buttons. Defaults to white.
77− @objc @IBInspectable public var buttonsTextColor: UIColor = UIColor.white {
77+ @IBInspectable public var buttonsTextColor: UIColor = UIColor.white {
78 didSet {
78 didSet {
79 for button in [leftButton, rightButton] {
79 for button in [leftButton, rightButton] {
80 button.setTitleColor(buttonsTextColor, for: .normal)
80 button.setTitleColor(buttonsTextColor, for: .normal)
@@ -83,7 +83,7 @@ import UIKit
83 }
83 }
84
84
85 /// Background color of the buttons. Defaults to dark blue.
85 /// Background color of the buttons. Defaults to dark blue.
86− @objc @IBInspectable public var buttonsBackgroundColor: UIColor = UIColor(red:0.21, green:0.5, blue:0.74, alpha:1) {
86+ @IBInspectable public var buttonsBackgroundColor: UIColor = UIColor(red:0.21, green:0.5, blue:0.74, alpha:1) {
87 didSet {
87 didSet {
88 for button in [leftButton, rightButton] {
88 for button in [leftButton, rightButton] {
89 button.backgroundColor = buttonsBackgroundColor
89 button.backgroundColor = buttonsBackgroundColor
@@ -93,7 +93,7 @@ import UIKit
93 }
93 }
94
94
95 /// Font of the buttons. Defaults to AvenirNext-Bold, 20.0 points in size.
95 /// Font of the buttons. Defaults to AvenirNext-Bold, 20.0 points in size.
96− @objc public var buttonsFont = UIFont(name: "AvenirNext-Bold", size: 20.0)! {
96+ public var buttonsFont = UIFont(name: "AvenirNext-Bold", size: 20.0)! {
97 didSet {
97 didSet {
98 for button in [leftButton, rightButton] {
98 for button in [leftButton, rightButton] {
99 button.titleLabel?.font = buttonsFont
99 button.titleLabel?.font = buttonsFont
@@ -102,35 +102,28 @@ import UIKit
102 }
102 }
103
103
104 /// Text color of the middle label. Defaults to white.
104 /// Text color of the middle label. Defaults to white.
105− @objc @IBInspectable public var labelTextColor: UIColor = UIColor.white {
105+ @IBInspectable public var labelTextColor: UIColor = UIColor.white {
106 didSet {
106 didSet {
107 label.textColor = labelTextColor
107 label.textColor = labelTextColor
108 }
108 }
109 }
109 }
110
110
111 /// Text color of the middle label. Defaults to lighter blue.
111 /// Text color of the middle label. Defaults to lighter blue.
112− @objc @IBInspectable public var labelBackgroundColor: UIColor = UIColor(red:0.26, green:0.6, blue:0.87, alpha:1) {
112+ @IBInspectable public var labelBackgroundColor: UIColor = UIColor(red:0.26, green:0.6, blue:0.87, alpha:1) {
113 didSet {
113 didSet {
114 label.backgroundColor = labelBackgroundColor
114 label.backgroundColor = labelBackgroundColor
115 }
115 }
116 }
116 }
117
117
118 /// Font of the middle label. Defaults to AvenirNext-Bold, 25.0 points in size.
118 /// Font of the middle label. Defaults to AvenirNext-Bold, 25.0 points in size.
119− @objc public var labelFont = UIFont(name: "AvenirNext-Bold", size: 25.0)! {
119+ public var labelFont = UIFont(name: "AvenirNext-Bold", size: 25.0)! {
120 didSet {
120 didSet {
121 label.font = labelFont
121 label.font = labelFont
122 }
122 }
123 }
123 }
124− /// Corner radius of the middle label. Defaults to 0.
125− @objc @IBInspectable public var labelCornerRadius: CGFloat = 0 {
126− didSet {
127− label.layer.cornerRadius = labelCornerRadius
128−
129− }
130− }
131
124
132 /// Corner radius of the stepper's layer. Defaults to 4.0.
125 /// Corner radius of the stepper's layer. Defaults to 4.0.
133− @objc @IBInspectable public var cornerRadius: CGFloat = 4.0 {
126+ @IBInspectable public var cornerRadius: CGFloat = 4.0 {
134 didSet {
127 didSet {
135 layer.cornerRadius = cornerRadius
128 layer.cornerRadius = cornerRadius
136 clipsToBounds = true
129 clipsToBounds = true
@@ -138,7 +131,7 @@ import UIKit
138 }
131 }
139
132
140 /// Border width of the stepper and middle label's layer. Defaults to 0.0.
133 /// Border width of the stepper and middle label's layer. Defaults to 0.0.
141− @objc @IBInspectable public var borderWidth: CGFloat = 0.0 {
134+ @IBInspectable public var borderWidth: CGFloat = 0.0 {
142 didSet {
135 didSet {
143 layer.borderWidth = borderWidth
136 layer.borderWidth = borderWidth
144 label.layer.borderWidth = borderWidth
137 label.layer.borderWidth = borderWidth
@@ -146,7 +139,7 @@ import UIKit
146 }
139 }
147
140
148 /// Color of the border of the stepper and middle label's layer. Defaults to clear color.
141 /// Color of the border of the stepper and middle label's layer. Defaults to clear color.
149− @objc @IBInspectable public var borderColor: UIColor = UIColor.clear {
142+ @IBInspectable public var borderColor: UIColor = UIColor.clear {
150 didSet {
143 didSet {
151 layer.borderColor = borderColor.cgColor
144 layer.borderColor = borderColor.cgColor
152 label.layer.borderColor = borderColor.cgColor
145 label.layer.borderColor = borderColor.cgColor
@@ -154,7 +147,7 @@ import UIKit
154 }
147 }
155
148
156 /// Percentage of the middle label's width. Must be between 0 and 1. Defaults to 0.5. Be sure that it is wide enough to show the value.
149 /// Percentage of the middle label's width. Must be between 0 and 1. Defaults to 0.5. Be sure that it is wide enough to show the value.
157− @objc @IBInspectable public var labelWidthWeight: CGFloat = 0.5 {
150+ @IBInspectable public var labelWidthWeight: CGFloat = 0.5 {
158 didSet {
151 didSet {
159 labelWidthWeight = min(1, max(0, labelWidthWeight))
152 labelWidthWeight = min(1, max(0, labelWidthWeight))
160 setNeedsLayout()
153 setNeedsLayout()
@@ -162,7 +155,7 @@ import UIKit
162 }
155 }
163
156
164 /// Color of the flashing animation on the buttons in case the value hit the limit.
157 /// Color of the flashing animation on the buttons in case the value hit the limit.
165− @objc @IBInspectable public var limitHitAnimationColor: UIColor = UIColor(red:0.26, green:0.6, blue:0.87, alpha:1)
158+ @IBInspectable public var limitHitAnimationColor: UIColor = UIColor(red:0.26, green:0.6, blue:0.87, alpha:1)
166
159
167 /**
160 /**
168 Width of the sliding animation. When buttons clicked, the middle label does a slide animation towards to the clicked button. Defaults to 5.
161 Width of the sliding animation. When buttons clicked, the middle label does a slide animation towards to the clicked button. Defaults to 5.
@@ -212,8 +205,6 @@ import UIKit
212 label.textColor = self.labelTextColor
205 label.textColor = self.labelTextColor
213 label.backgroundColor = self.labelBackgroundColor
206 label.backgroundColor = self.labelBackgroundColor
214 label.font = self.labelFont
207 label.font = self.labelFont
215− label.layer.cornerRadius = self.labelCornerRadius
216− label.layer.masksToBounds = true
217 label.isUserInteractionEnabled = true
208 label.isUserInteractionEnabled = true
218 let panRecognizer = UIPanGestureRecognizer(target: self, action: #selector(GMStepper.handlePan))
209 let panRecognizer = UIPanGestureRecognizer(target: self, action: #selector(GMStepper.handlePan))
219 panRecognizer.maximumNumberOfTouches = 1
210 panRecognizer.maximumNumberOfTouches = 1
@@ -245,7 +236,7 @@ import UIKit
245 }
236 }
246
237
247
238
248− @objc public var items : [String] = [] {
239+ public var items : [String] = [] {
249 didSet {
240 didSet {
250 let isInteger = floor(value) == value
241 let isInteger = floor(value) == value
251
242
@@ -291,12 +282,12 @@ import UIKit
291 }
282 }
292 }
283 }
293
284
294− @objc required public init?(coder aDecoder: NSCoder) {
285+ required public init?(coder aDecoder: NSCoder) {
295 super.init(coder: aDecoder)
286 super.init(coder: aDecoder)
296 setup()
287 setup()
297 }
288 }
298
289
299− @objc public override init(frame: CGRect) {
290+ public override init(frame: CGRect) {
300 super.init(frame: frame)
291 super.init(frame: frame)
301 setup()
292 setup()
302 }
293 }
@@ -356,7 +347,7 @@ import UIKit
356
347
357// MARK: Pan Gesture
348// MARK: Pan Gesture
358extension GMStepper {
349extension GMStepper {
359− @objc func handlePan(gesture: UIPanGestureRecognizer) {
350+ func handlePan(gesture: UIPanGestureRecognizer) {
360 switch gesture.state {
351 switch gesture.state {
361 case .began:
352 case .began:
362 leftButton.isEnabled = false
353 leftButton.isEnabled = false
@@ -406,7 +397,7 @@ extension GMStepper {
406 }
397 }
407 }
398 }
408
399
409− @objc func reset() {
400+ func reset() {
410 panState = .Stable
401 panState = .Stable
411 stepperState = .Stable
402 stepperState = .Stable
412 resetTimer()
403 resetTimer()
@@ -425,7 +416,7 @@ extension GMStepper {
425
416
426// MARK: Button Events
417// MARK: Button Events
427extension GMStepper {
418extension GMStepper {
428− @objc func leftButtonTouchDown(button: UIButton) {
419+ func leftButtonTouchDown(button: UIButton) {
429 rightButton.isEnabled = false
420 rightButton.isEnabled = false
430 label.isUserInteractionEnabled = false
421 label.isUserInteractionEnabled = false
431 resetTimer()
422 resetTimer()
@@ -439,7 +430,7 @@ extension GMStepper {
439
430
440 }
431 }
441
432
442− @objc func rightButtonTouchDown(button: UIButton) {
433+ func rightButtonTouchDown(button: UIButton) {
443 leftButton.isEnabled = false
434 leftButton.isEnabled = false
444 label.isUserInteractionEnabled = false
435 label.isUserInteractionEnabled = false
445 resetTimer()
436 resetTimer()
@@ -452,7 +443,7 @@ extension GMStepper {
452 }
443 }
453 }
444 }
454
445
455− @objc func buttonTouchUp(button: UIButton) {
446+ func buttonTouchUp(button: UIButton) {
456 reset()
447 reset()
457 }
448 }
458}
449}
@@ -497,7 +488,7 @@ extension GMStepper {
497
488
498// MARK: Timer
489// MARK: Timer
499extension GMStepper {
490extension GMStepper {
500− @objc func handleTimerFire(timer: Timer) {
491+ func handleTimerFire(timer: Timer) {
501 timerFireCount += 1
492 timerFireCount += 1
502
493
503 if timerFireCount % timerFireCountModulo == 0 {
494 if timerFireCount % timerFireCountModulo == 0 {
GMStepperExample/GMStepperExample.xcodeproj/project.pbxproj+6−23
@@ -163,19 +163,18 @@
163 attributes = {
163 attributes = {
164 LastSwiftMigration = 0700;
164 LastSwiftMigration = 0700;
165 LastSwiftUpdateCheck = 0800;
165 LastSwiftUpdateCheck = 0800;
166− LastUpgradeCheck = 0900;
166+ LastUpgradeCheck = 0800;
167 ORGANIZATIONNAME = "Gunay Mert Karadogan";
167 ORGANIZATIONNAME = "Gunay Mert Karadogan";
168 TargetAttributes = {
168 TargetAttributes = {
169 3116C0D71DA4DD360015AC69 = {
169 3116C0D71DA4DD360015AC69 = {
170 CreatedOnToolsVersion = 8.0;
170 CreatedOnToolsVersion = 8.0;
171− LastSwiftMigration = 0900;
172 ProvisioningStyle = Automatic;
171 ProvisioningStyle = Automatic;
173 TestTargetID = 319C19311B4843EB005EFEE5;
172 TestTargetID = 319C19311B4843EB005EFEE5;
174 };
173 };
175 319C19311B4843EB005EFEE5 = {
174 319C19311B4843EB005EFEE5 = {
176 CreatedOnToolsVersion = 6.4;
175 CreatedOnToolsVersion = 6.4;
177 DevelopmentTeam = 289M6XEDV4;
176 DevelopmentTeam = 289M6XEDV4;
178− LastSwiftMigration = 0900;
177+ LastSwiftMigration = 0800;
179 };
178 };
180 };
179 };
181 };
180 };
@@ -282,8 +281,7 @@
282 PRODUCT_BUNDLE_IDENTIFIER = com.gmertk.GMStepperExampleTests;
281 PRODUCT_BUNDLE_IDENTIFIER = com.gmertk.GMStepperExampleTests;
283 PRODUCT_NAME = "$(TARGET_NAME)";
282 PRODUCT_NAME = "$(TARGET_NAME)";
284 SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
283 SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
285− SWIFT_SWIFT3_OBJC_INFERENCE = On;
286− SWIFT_VERSION = 4.0;
284+ SWIFT_VERSION = 3.0;
287 TEST_HOST = "$(BUILT_PRODUCTS_DIR)/GMStepperExample.app/GMStepperExample";
285 TEST_HOST = "$(BUILT_PRODUCTS_DIR)/GMStepperExample.app/GMStepperExample";
288 };
286 };
289 name = Debug;
287 name = Debug;
@@ -300,8 +298,7 @@
300 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
298 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
301 PRODUCT_BUNDLE_IDENTIFIER = com.gmertk.GMStepperExampleTests;
299 PRODUCT_BUNDLE_IDENTIFIER = com.gmertk.GMStepperExampleTests;
302 PRODUCT_NAME = "$(TARGET_NAME)";
300 PRODUCT_NAME = "$(TARGET_NAME)";
303− SWIFT_SWIFT3_OBJC_INFERENCE = On;
304− SWIFT_VERSION = 4.0;
301+ SWIFT_VERSION = 3.0;
305 TEST_HOST = "$(BUILT_PRODUCTS_DIR)/GMStepperExample.app/GMStepperExample";
302 TEST_HOST = "$(BUILT_PRODUCTS_DIR)/GMStepperExample.app/GMStepperExample";
306 };
303 };
307 name = Release;
304 name = Release;
@@ -314,20 +311,14 @@
314 CLANG_CXX_LIBRARY = "libc++";
311 CLANG_CXX_LIBRARY = "libc++";
315 CLANG_ENABLE_MODULES = YES;
312 CLANG_ENABLE_MODULES = YES;
316 CLANG_ENABLE_OBJC_ARC = YES;
313 CLANG_ENABLE_OBJC_ARC = YES;
317− CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
318 CLANG_WARN_BOOL_CONVERSION = YES;
314 CLANG_WARN_BOOL_CONVERSION = YES;
319− CLANG_WARN_COMMA = YES;
320 CLANG_WARN_CONSTANT_CONVERSION = YES;
315 CLANG_WARN_CONSTANT_CONVERSION = YES;
321 CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
316 CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
322 CLANG_WARN_EMPTY_BODY = YES;
317 CLANG_WARN_EMPTY_BODY = YES;
323 CLANG_WARN_ENUM_CONVERSION = YES;
318 CLANG_WARN_ENUM_CONVERSION = YES;
324 CLANG_WARN_INFINITE_RECURSION = YES;
319 CLANG_WARN_INFINITE_RECURSION = YES;
325 CLANG_WARN_INT_CONVERSION = YES;
320 CLANG_WARN_INT_CONVERSION = YES;
326− CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
327− CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
328 CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
321 CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
329− CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
330− CLANG_WARN_STRICT_PROTOTYPES = YES;
331 CLANG_WARN_SUSPICIOUS_MOVE = YES;
322 CLANG_WARN_SUSPICIOUS_MOVE = YES;
332 CLANG_WARN_UNREACHABLE_CODE = YES;
323 CLANG_WARN_UNREACHABLE_CODE = YES;
333 CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
324 CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
@@ -367,20 +358,14 @@
367 CLANG_CXX_LIBRARY = "libc++";
358 CLANG_CXX_LIBRARY = "libc++";
368 CLANG_ENABLE_MODULES = YES;
359 CLANG_ENABLE_MODULES = YES;
369 CLANG_ENABLE_OBJC_ARC = YES;
360 CLANG_ENABLE_OBJC_ARC = YES;
370− CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
371 CLANG_WARN_BOOL_CONVERSION = YES;
361 CLANG_WARN_BOOL_CONVERSION = YES;
372− CLANG_WARN_COMMA = YES;
373 CLANG_WARN_CONSTANT_CONVERSION = YES;
362 CLANG_WARN_CONSTANT_CONVERSION = YES;
374 CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
363 CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
375 CLANG_WARN_EMPTY_BODY = YES;
364 CLANG_WARN_EMPTY_BODY = YES;
376 CLANG_WARN_ENUM_CONVERSION = YES;
365 CLANG_WARN_ENUM_CONVERSION = YES;
377 CLANG_WARN_INFINITE_RECURSION = YES;
366 CLANG_WARN_INFINITE_RECURSION = YES;
378 CLANG_WARN_INT_CONVERSION = YES;
367 CLANG_WARN_INT_CONVERSION = YES;
379− CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
380− CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
381 CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
368 CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
382− CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
383− CLANG_WARN_STRICT_PROTOTYPES = YES;
384 CLANG_WARN_SUSPICIOUS_MOVE = YES;
369 CLANG_WARN_SUSPICIOUS_MOVE = YES;
385 CLANG_WARN_UNREACHABLE_CODE = YES;
370 CLANG_WARN_UNREACHABLE_CODE = YES;
386 CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
371 CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
@@ -414,8 +399,7 @@
414 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
399 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
415 PRODUCT_BUNDLE_IDENTIFIER = "com.gunaymert.$(PRODUCT_NAME:rfc1034identifier)";
400 PRODUCT_BUNDLE_IDENTIFIER = "com.gunaymert.$(PRODUCT_NAME:rfc1034identifier)";
416 PRODUCT_NAME = "$(TARGET_NAME)";
401 PRODUCT_NAME = "$(TARGET_NAME)";
417− SWIFT_SWIFT3_OBJC_INFERENCE = Default;
418− SWIFT_VERSION = 4.0;
402+ SWIFT_VERSION = 3.0;
419 };
403 };
420 name = Debug;
404 name = Debug;
421 };
405 };
@@ -428,8 +412,7 @@
428 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
412 LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
429 PRODUCT_BUNDLE_IDENTIFIER = "com.gunaymert.$(PRODUCT_NAME:rfc1034identifier)";
413 PRODUCT_BUNDLE_IDENTIFIER = "com.gunaymert.$(PRODUCT_NAME:rfc1034identifier)";
430 PRODUCT_NAME = "$(TARGET_NAME)";
414 PRODUCT_NAME = "$(TARGET_NAME)";
431− SWIFT_SWIFT3_OBJC_INFERENCE = Default;
432− SWIFT_VERSION = 4.0;
415+ SWIFT_VERSION = 3.0;
433 };
416 };
434 name = Release;
417 name = Release;
435 };
418 };
GMStepperExample/GMStepperExample/ViewController.swift+1−1
@@ -16,7 +16,7 @@ class ViewController: UIViewController {
16 stepper.addTarget(self, action: #selector(ViewController.stepperValueChanged), for: .valueChanged)
16 stepper.addTarget(self, action: #selector(ViewController.stepperValueChanged), for: .valueChanged)
17 }
17 }
18
18
19− @objc func stepperValueChanged(stepper: GMStepper) {
19+ func stepperValueChanged(stepper: GMStepper) {
20 print(stepper.value, terminator: "")
20 print(stepper.value, terminator: "")
21 }
21 }
22}
22}
README.md+3−4
@@ -5,6 +5,8 @@
5
5
6A stepper with a sliding label in the middle. Pan the label or tap the buttons. Check out the tutorial, [How to Build a Custom Stepper - Part 1](http://gmertk.github.io/custom-stepper-part-1/).
6A stepper with a sliding label in the middle. Pan the label or tap the buttons. Check out the tutorial, [How to Build a Custom Stepper - Part 1](http://gmertk.github.io/custom-stepper-part-1/).
7
7
8+**I'm looking for a maintainer who is willing to keep this library updated. Feel free to contact me.**
9+
8
10
9## Screenshot
11## Screenshot
10
12
@@ -69,9 +71,6 @@ var labelBackgroundColor: UIColor = UIColor(red:0.26, green:0.6, blue:0.87, alph
69/// Font of the middle label. Defaults to AvenirNext-Bold, 25.0 points in size.
71/// Font of the middle label. Defaults to AvenirNext-Bold, 25.0 points in size.
70var labelFont = UIFont(name: "AvenirNext-Bold", size: 25.0)
72var labelFont = UIFont(name: "AvenirNext-Bold", size: 25.0)
71
73
72−/// Corner radius of the middle label's layer. Defaults to 0.0.
73−var labelCornerRadius: CGFloat = 0.0
74−
75/// Corner radius of the stepper's layer. Defaults to 4.0.
74/// Corner radius of the stepper's layer. Defaults to 4.0.
76var cornerRadius: CGFloat = 4.0
75var cornerRadius: CGFloat = 4.0
77
76
@@ -91,7 +90,7 @@ var limitHitAnimationColor: UIColor = UIColor(red:0.26, green:0.6, blue:0.87, al
91
90
92## Authors
91## Authors
93
92
94−* [Brent Whitman](https://github.com/bwhtmn) - Maintainer
93+* [Brent W.](https://github.com/bwhtmn) - Maintainer
95* [Günay Mert Karadoğan](https://github.com/gmertk) - Creator
94* [Günay Mert Karadoğan](https://github.com/gmertk) - Creator
96
95
97## License
96## License