07-21-2023, 05:02 PM
I found that `disablesAutomaticKeyboardDismissal` and adding a `disablesAutomaticKeyboardDismissal` function didn't work for my `UITextField` in a modal dialog.
The onscreen keyboard just wouldn't go away.
My solution was to *disable* all text-input controls in my dialog, then re-enable the relevant ones a fraction of a second later.
It seems as though when iOS sees that none of the `UITextField` controls are enabled, then it *does* get rid of the keyboard.
The onscreen keyboard just wouldn't go away.
My solution was to *disable* all text-input controls in my dialog, then re-enable the relevant ones a fraction of a second later.
It seems as though when iOS sees that none of the `UITextField` controls are enabled, then it *does* get rid of the keyboard.