added isAnimated logic
Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
parent
5e8a1d349b
commit
790fa208db
@ -136,6 +136,8 @@ open class ToggleBase: Control, Accessable, DataTrackable, BinaryColorable {
|
||||
// MARK: - Public Properties
|
||||
//--------------------------------------------------
|
||||
open var isOn: Bool = false { didSet { didChange() }}
|
||||
|
||||
open var isAnimated: Bool = true { didSet { didChange() }}
|
||||
|
||||
open var showText: Bool = false { didSet { didChange() }}
|
||||
|
||||
@ -200,7 +202,7 @@ open class ToggleBase: Control, Accessable, DataTrackable, BinaryColorable {
|
||||
let toggleColor = toggleColorConfiguration.getColor(self)
|
||||
let knobColor = knobColorConfiguration.getColor(self)
|
||||
|
||||
if disabled {
|
||||
if disabled || !isAnimated {
|
||||
toggleView.backgroundColor = toggleColor
|
||||
knobView.backgroundColor = knobColor
|
||||
constrainKnob()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user