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

Correctly remove&add FocusNode listener #73

Merged
merged 1 commit into from Mar 19, 2022

Conversation

Albert221
Copy link
Contributor

@Albert221 Albert221 commented Mar 17, 2022

The current implementation adds the same listener on each update to the widget when focusNode is null. This change fixes it.

This is exactly what Flutter does in the framework in many places:

https://github.com/flutter/flutter/blob/master/packages/flutter/lib/src/material/text_field.dart#L959-L962

@TinoGuo TinoGuo self-requested a review March 19, 2022 04:30
@TinoGuo TinoGuo added the bug Something isn't working label Mar 19, 2022
@TinoGuo TinoGuo merged commit d52d6e5 into TinoGuo:master Mar 19, 2022
@Albert221 Albert221 deleted the fix/focus-node-update branch April 4, 2022 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants