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] TextFormField onFieldSubmitted function did not call when pressing Enter key on the number keypad of external keyboard #147138

Open
selvam920 opened this issue Apr 21, 2024 · 15 comments
Labels
a: text input Entering text in a text field or keyboard related problems framework flutter/packages/flutter repository. See also f: labels. P3 Issues that are less important to the Flutter project platform-android Android applications specifically team-text-input Owned by Text Input team triaged-text-input Triaged by Text Input team

Comments

@selvam920
Copy link

selvam920 commented Apr 21, 2024

Steps to reproduce

Connected External keyboard to android phone
type some word in textformfield and press numkey enter
onFieldSubmitted() did not call but when press enter key it's working

TextFormField(
onFieldSubmitted: (str) {
}
)

Expected results

Should work onFieldSubmitted() method

Actual results

Did not call

Code sample

Code sample
[Paste your code here]

Screenshots or Video

Screenshots / Video demonstration

[Upload media here]

Logs

Logs
[Paste your logs here]

Flutter Doctor output

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel beta, 3.22.0-0.2.pre, on Microsoft Windows [Version 10.0.22631.3447], locale en-US)
[✓] Windows Version (Installed version of Windows is version 10 or higher)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Chrome - develop for the web
[✓] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.9.6)
[✓] Android Studio (version 2023.2)
[✓] VS Code (version 1.88.1)
[✓] Connected device (3 available)
[✓] Network resources

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.19.6, on Microsoft Windows [Version 10.0.22631.3447], locale en-US)
[✓] Windows Version (Installed version of Windows is version 10 or higher)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Chrome - develop for the web
[✓] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.9.6)
[✓] Android Studio (version 2023.2)
[✓] VS Code (version 1.88.1)
[✓] Connected device (3 available)
[✓] Network resources
@huycozy huycozy added the in triage Presently being triaged by the triage team label Apr 22, 2024
@huycozy
Copy link
Member

huycozy commented Apr 22, 2024

Hi @selvam920
I checked this issue with my setup (Android device and a hardware keyboard connect via Bluetooth) but couldn't see the issue. onFieldSubmitted is called when pressing enter from keyboard (adding a print inside the callback and see the str value is printed).

Not sure if other widgets or native code could cause the issue. Could you confirm this with a newly created project?

@huycozy huycozy added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Apr 22, 2024
@selvam920
Copy link
Author

selvam920 commented Apr 22, 2024

The issue with Numer keypad enter key, did you check?
I'm using logitech wireless keyboard and mouse

@github-actions github-actions bot removed the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Apr 22, 2024
@selvam920
Copy link
Author

tested with newly created project also, it's not working

@selvam920

This comment was marked as off-topic.

@huycozy
Copy link
Member

huycozy commented Apr 23, 2024

Do you mean the Enter key on the right-side number keypad, right?

SK-101-M-USB-2T

If so, my keyboard doesn't have that keypad. Could you check if this issue also happens on other platforms? (Desktop or web) I think this is text-input issue in general, but not Android-specific issue.

@huycozy huycozy added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Apr 23, 2024
@selvam920
Copy link
Author

yes, in the right side enter key.
this issue happing on android not windows

@github-actions github-actions bot removed the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Apr 23, 2024
@huycozy
Copy link
Member

huycozy commented Apr 23, 2024

Thanks for checking it. Labeling the issue for other's input.

@huycozy huycozy added a: text input Entering text in a text field or keyboard related problems platform-android Android applications specifically framework flutter/packages/flutter repository. See also f: labels. fyi-android For the attention of Android platform team team-text-input Owned by Text Input team and removed in triage Presently being triaged by the triage team labels Apr 23, 2024
@huycozy huycozy changed the title [Android] TextFormField onFieldSubmitted function did not call [Android] TextFormField onFieldSubmitted function did not call when pressing Enter key on the number keypad of external keyboard Apr 23, 2024
@selvam920
Copy link
Author

any fixes on this?

@yaakovschectman yaakovschectman added P2 Important issues not at the top of the work list triaged-android Triaged by Android platform team and removed P2 Important issues not at the top of the work list labels May 2, 2024
@flutter-triage-bot flutter-triage-bot bot removed fyi-android For the attention of Android platform team triaged-android Triaged by Android platform team labels May 2, 2024
@justinmc
Copy link
Contributor

justinmc commented May 2, 2024

@selvam920 Can you double check that this works as you describe on native Android? I want to make sure Flutter should be doing this before we make any changes.

@justinmc justinmc added triaged-text-input Triaged by Text Input team P3 Issues that are less important to the Flutter project labels May 2, 2024
@selvam920
Copy link
Author

selvam920 commented May 3, 2024

Yes this issue only in android

@huycozy
Copy link
Member

huycozy commented May 3, 2024

@selvam920 Do you mean this issue also happens with Android native EditText?

@selvam920
Copy link
Author

Oh sorry only in flutter android, i'm able get number keypad enter key in KeyboardListener,

@selvam920
Copy link
Author

Pls check with keyboard with numpad, you will get the issue

@selvam920
Copy link
Author

Any update on this, my customers are waiting to use my app bcoz app this issue

@selvam920
Copy link
Author

Hi flutter team, are you taking bugs as serious seems this is a blocker to use flutter android using numpad keyboard

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a: text input Entering text in a text field or keyboard related problems framework flutter/packages/flutter repository. See also f: labels. P3 Issues that are less important to the Flutter project platform-android Android applications specifically team-text-input Owned by Text Input team triaged-text-input Triaged by Text Input team
Projects
None yet
Development

No branches or pull requests

4 participants