Fixed that isFocussedChanged() got called even though TextField hasn't been focused (but why did textFieldShouldBeginEditing() get called even though it hasn't been focused?)
This commit is contained in:
parent
cd365fd0cd
commit
d17c91b6d6
|
@ -127,7 +127,9 @@ struct UIKitTextField: UIViewRepresentable {
|
||||||
|
|
||||||
func textFieldShouldBeginEditing(_ textField: UITextField) -> Bool {
|
func textFieldShouldBeginEditing(_ textField: UITextField) -> Bool {
|
||||||
if isUserInputEnabled {
|
if isUserInputEnabled {
|
||||||
isFocussedChanged?(true)
|
if textField.isFirstResponder {
|
||||||
|
isFocussedChanged?(true)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return isUserInputEnabled
|
return isUserInputEnabled
|
||||||
|
|
Loading…
Reference in New Issue