Implemented Scott feedback

This commit is contained in:
Khan, Arshad 2020-04-29 20:33:55 +05:30
parent cde1f5c4e6
commit e309c589d0

View File

@ -30,16 +30,16 @@ import UIKit
switch style { switch style {
case .standard: case .standard:
updateLineConstraints(constant: 1) updateLineConstraints(constant: 1)
backgroundColor = .mfSilver() backgroundColor = lineModel?.backgroundColor?.uiColor ?? .mfSilver()
case .thin: case .thin:
updateLineConstraints(constant: 1) updateLineConstraints(constant: 1)
backgroundColor = .black backgroundColor = lineModel?.backgroundColor?.uiColor ?? .black
case .medium: case .medium:
updateLineConstraints(constant: 2) updateLineConstraints(constant: 2)
backgroundColor = .black backgroundColor = lineModel?.backgroundColor?.uiColor ?? .black
case .heavy: case .heavy:
updateLineConstraints(constant: 4) updateLineConstraints(constant: 4)
backgroundColor = .black backgroundColor = lineModel?.backgroundColor?.uiColor ?? .black
case .none: case .none:
updateLineConstraints(constant: 0) updateLineConstraints(constant: 0)
} }
@ -69,11 +69,11 @@ import UIKit
// MARK: - MoleculeViewProtocol // MARK: - MoleculeViewProtocol
open override func set(with model: MoleculeModelProtocol, _ delegateObject: MVMCoreUIDelegateObject?, _ additionalData: [AnyHashable: Any]?) { open override func set(with model: MoleculeModelProtocol, _ delegateObject: MVMCoreUIDelegateObject?, _ additionalData: [AnyHashable: Any]?) {
super.set(with: model, delegateObject, additionalData)
if let lineModel = model as? LineModel { if let lineModel = model as? LineModel {
self.lineModel = lineModel self.lineModel = lineModel
setStyle(lineModel.type) setStyle(lineModel.type)
} }
super.set(with: model, delegateObject, additionalData)
} }
open override func reset() { open override func reset() {