Conversation
- Hide keyboard when search field loses focus - Hide keyboard when back/clear button is pressed - Hide keyboard when clear text (X) button is pressed - Hide keyboard when navigating to a settings sub-screen - Hide keyboard when clicking a search result Fixes recloudstream#3171 and recloudstream#3177
|
Can you can confirm that this issue still exists on the latest pre-release, and that this pull request changes anything. Because I suspect this issue was already solved by a recent fix, but the issues where not closed. |
|
Thanks for checking! I tested against the latest pre-release (after #3201 was merged), and the keyboard issues still exist. PR #3201 replaced the SearchBarDefaults.InputField with a plain TextField, but the keyboard dismissal was not fully addressed:
The DisposableEffect on line 374-378 only hides the keyboard when the composable is disposed (i.e. leaving the Settings screen entirely), not during any of the above interactions. This PR adds keyboardController?.hide() calls in all the places where the keyboard should be dismissed. Happy to rebase if needed. |
Summary
This PR fixes the keyboard not dismissing properly in the Settings screen on TV devices (Fire TV, Android TV).
Issues Fixed
Changes Made
In SettingsFragmentScreen.kt:
Testing