-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix focus in Cupertino textfield #952
Fix focus in Cupertino textfield #952
Conversation
@@ -98,6 +98,12 @@ private fun getTapHandlerModifier( | |||
detectRepeatingTapGestures( | |||
onTap = { touchPointOffset -> | |||
if (currentState.hasFocus) { | |||
// To show keyboard if it was hidden. Even in selection mode (like native) | |||
tapTextFieldToFocus( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dima-avdeev-jb
It seems like I messed up with the naming of that method in Common code in my previous request dedicated to that feature. Under the hood, this method is responsible to focus if textfield was unfocused and to show the keyboard if textfield was focused. Should I make another request for fixing that, or I can fix it here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can fix it in this PR too
I will wait fix with naming and approve after that |
Proposed Changes
added explicit showing keyboard method in focused textfield (like it is in android)
Testing
Test: open app, go to Application layouts, toggle "Insets" switch, then try to click on 'show keyboard' textfield and 'hide keyboard' button repetitively.
Issues Fixed
https://youtrack.jetbrains.com/issue/COMPOSE-667/fix-Regression-with-TextField-and-Keyboard
Google CLA
You need to sign the Google Contributor’s License Agreement at https://cla.developers.google.com/.
This is needed since we synchronise most of the code with Google’s AOSP repository. Signing this agreement allows us to synchronise code from your Pull Requests as well.