Skip to content
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

[Android] Show keyboard when Entry, Editor and SearchBar get focus #5995

Closed
wants to merge 5 commits into from

Conversation

jsuarezruiz
Copy link
Contributor

Description of Change

Show/hide keyboard when Entry, Editor and SearchBar get or lost focus.

issue-5983

Issues Fixed

Fixes #5983

@jsuarezruiz jsuarezruiz added t/bug Something isn't working area-controls-entry Entry labels Apr 12, 2022
}
else
{
platformView?.HideKeyboard();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What happens here if you are tabbing through multiple fields?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we have something like:

StackLayout

  • Entry
  • Entry
  • Entry

If we have the focus on the first entry, and pass the focus to the second one:

  • The first Entry loses focus and the keyboard closes.
  • The second Entry gains focus so the keyboard is reopened.

That is, the keyboard would close and open in a short time.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't feel like that's the behavior we'd want here. If we want to maintain some level of behavior here with MAUI then I would say at the controls level if the user calls "FOCUS" then we open the keyboard but then that's it.

Copy link
Member

@PureWeen PureWeen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Keyboard visibility was very broken in XF. I don't think we should just bring this code straight over. Someone also logged this same bug on XF against iOS xamarin/Xamarin.Forms#8952

@Eilon Eilon added the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label Apr 12, 2022
@PureWeen PureWeen added this to the 6.0.300-servicing milestone Apr 18, 2022
@PureWeen PureWeen added the do-not-merge Don't merge this PR label May 8, 2022
@Redth Redth modified the milestones: 6.0-servicing, .NET 7 Planning Aug 30, 2022
@PureWeen PureWeen marked this pull request as draft September 28, 2022 20:26
@jsuarezruiz
Copy link
Contributor Author

To help focus and move faster, we're going to have fewer open PRs and focus on the ones we'll be working on in each release. This PR is not included in the next release so I close it for now. I will reopen it and adapt to changes later.

@jsuarezruiz jsuarezruiz closed this Nov 3, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Dec 21, 2023
@Eilon Eilon removed the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label May 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-controls-editor Editor area-controls-entry Entry do-not-merge Don't merge this PR t/bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Soft Keyboard does not Pop Up when Entry View's Focus is set to True Programmatically
5 participants