shapelayer .

This commit is contained in:
Kevin G Christiano 2019-10-07 16:33:39 -04:00
parent 7d6289463d
commit 66e45378f4

View File

@ -80,9 +80,9 @@ import MVMCore
/// Width of the check mark.
public var checkWidth: CGFloat = 2 {
didSet {
if shapeLayer != nil {
if let shapeLayer = shapeLayer {
CATransaction.withDisabledAnimations {
shapeLayer?.lineWidth = checkWidth
shapeLayer.lineWidth = checkWidth
}
}
}
@ -91,9 +91,9 @@ import MVMCore
/// Color of the check mark.
public var checkColor: UIColor = .black {
didSet {
if shapeLayer != nil {
if let shapeLayer = shapeLayer {
CATransaction.withDisabledAnimations {
shapeLayer?.strokeColor = checkColor.cgColor
shapeLayer.strokeColor = checkColor.cgColor
}
}
}