error checks
This commit is contained in:
parent
cea16818cc
commit
8562806880
@ -88,14 +88,18 @@ import UIKit
|
||||
}
|
||||
|
||||
@objc public override func dismissFieldInput(_ sender: Any?) {
|
||||
performDropdownAction()
|
||||
if !textField.isFirstResponder {
|
||||
performDropdownAction()
|
||||
}
|
||||
super.dismissFieldInput(sender)
|
||||
}
|
||||
|
||||
func performDropdownAction() {
|
||||
if let baseDropdownEntryFieldModel = baseDropdownEntryFieldModel, let actionModel = baseDropdownEntryFieldModel.action {
|
||||
let additionalDataWithSource = additionalData.dictionaryAdding(key: KeySourceModel, value: baseDropdownEntryFieldModel)
|
||||
MVMCoreActionHandler.shared()?.asyncHandleAction(with: actionModel, additionalData: additionalDataWithSource, delegateObject: delegateObject)
|
||||
}
|
||||
guard let baseDropdownEntryFieldModel = baseDropdownEntryFieldModel,
|
||||
let actionModel = baseDropdownEntryFieldModel.action
|
||||
else { return }
|
||||
|
||||
let additionalDataWithSource = additionalData.dictionaryAdding(key: KeySourceModel, value: baseDropdownEntryFieldModel)
|
||||
MVMCoreActionHandler.shared()?.asyncHandleAction(with: actionModel, additionalData: additionalDataWithSource, delegateObject: delegateObject)
|
||||
}
|
||||
}
|
||||
|
||||
@ -270,7 +270,9 @@ import UIKit
|
||||
bottomBar?.frame = CGRect(x: 0, y: bounds.height - size, width: bounds.width, height: size)
|
||||
|
||||
if updateMoleculeLayout || heightChanged {
|
||||
delegateObject?.moleculeDelegate?.moleculeLayoutUpdated(self)
|
||||
DispatchQueue.main.async { [self] in
|
||||
delegateObject?.moleculeDelegate?.moleculeLayoutUpdated(self)
|
||||
}
|
||||
}
|
||||
|
||||
setNeedsDisplay()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user