diff --git a/README.md b/README.md index e07b532..8e9a054 100644 --- a/README.md +++ b/README.md @@ -130,7 +130,11 @@ YPDrawSignatureView is available under the MIT license. See the [LICENSE](LICENS ## Update history -### v1.0 - 9/12/16 +### v1.0.1 - 5/2/17 + +* Minor bugfix + +#### v1.0 - 9/12/16 * More Swifty API * Supports Swift 3 diff --git a/SignatureTest/SignatureTest/YPDrawSignatureView.swift b/SignatureTest/SignatureTest/YPDrawSignatureView.swift index db5b5d9..0cdf6c6 100644 --- a/SignatureTest/SignatureTest/YPDrawSignatureView.swift +++ b/SignatureTest/SignatureTest/YPDrawSignatureView.swift @@ -120,7 +120,7 @@ public class YPDrawSignatureView: UIView { } override public func touchesEnded(_ touches: Set , with event: UIEvent?) { - if self.controlPoint == 0 { + if self.controlPoint < 4 { let touchPoint = self.points[0] self.path.move(to: CGPoint(x: touchPoint.x-1.0,y: touchPoint.y)) self.path.addLine(to: CGPoint(x: touchPoint.x+1.0,y: touchPoint.y)) diff --git a/Sources/YPDrawSignatureView.swift b/Sources/YPDrawSignatureView.swift index db5b5d9..0cdf6c6 100644 --- a/Sources/YPDrawSignatureView.swift +++ b/Sources/YPDrawSignatureView.swift @@ -120,7 +120,7 @@ public class YPDrawSignatureView: UIView { } override public func touchesEnded(_ touches: Set , with event: UIEvent?) { - if self.controlPoint == 0 { + if self.controlPoint < 4 { let touchPoint = self.points[0] self.path.move(to: CGPoint(x: touchPoint.x-1.0,y: touchPoint.y)) self.path.addLine(to: CGPoint(x: touchPoint.x+1.0,y: touchPoint.y))