changes for refrsh
This commit is contained in:
parent
d8d691f2cc
commit
630c51d83b
@ -207,6 +207,8 @@ public typealias ActionBlockConfirmation = () -> (Bool)
|
|||||||
|
|
||||||
layer.cornerRadius = Self.getContainerHeight() / 2.0
|
layer.cornerRadius = Self.getContainerHeight() / 2.0
|
||||||
knobView.layer.cornerRadius = Self.getKnobHeight() / 2.0
|
knobView.layer.cornerRadius = Self.getKnobHeight() / 2.0
|
||||||
|
|
||||||
|
changeStateNoAnimation(isOn)
|
||||||
}
|
}
|
||||||
|
|
||||||
public override func setupView() {
|
public override func setupView() {
|
||||||
@ -245,8 +247,6 @@ public typealias ActionBlockConfirmation = () -> (Bool)
|
|||||||
backgroundColor = containerTintColor.off
|
backgroundColor = containerTintColor.off
|
||||||
knobView.backgroundColor = knobTintColor.off
|
knobView.backgroundColor = knobTintColor.off
|
||||||
isAnimated = true
|
isAnimated = true
|
||||||
isOn = false
|
|
||||||
constrainKnob()
|
|
||||||
didToggleAction = nil
|
didToggleAction = nil
|
||||||
shouldToggleAction = { return true }
|
shouldToggleAction = { return true }
|
||||||
}
|
}
|
||||||
@ -368,7 +368,8 @@ public typealias ActionBlockConfirmation = () -> (Bool)
|
|||||||
containerTintColor.off = model.offTintColor.uiColor
|
containerTintColor.off = model.offTintColor.uiColor
|
||||||
knobTintColor.on = model.onKnobTintColor.uiColor
|
knobTintColor.on = model.onKnobTintColor.uiColor
|
||||||
knobTintColor.off = model.offKnobTintColor.uiColor
|
knobTintColor.off = model.offKnobTintColor.uiColor
|
||||||
changeStateNoAnimation(model.state)
|
isOn = model.state
|
||||||
|
changeStateNoAnimation(isOn)
|
||||||
isAnimated = model.animated
|
isAnimated = model.animated
|
||||||
isEnabled = model.enabled
|
isEnabled = model.enabled
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user