-
-
Notifications
You must be signed in to change notification settings - Fork 895
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 handling with a scope on the GameWidget
#1725
Conversation
7d7d997
to
87faaf6
Compare
cf93232
to
2e41b85
Compare
2e41b85
to
8926df2
Compare
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.
Nice!!
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.
One nit, but LGTM! Can we have a more contextual PR title though?
// ignore: avoid_redundant_argument_values | ||
autofocus: true, |
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.
// ignore: avoid_redundant_argument_values | |
autofocus: true, |
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.
It's pretty good to keep this imho, it gives the reader of the test more context of what is being tested.
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.
Disagree with the suggestion, that is to explicitly show what that test tests.
Co-authored-by: Lukas Klingsbo <me@lukas.fyi>
GameWidget
This ignores keyboard events if the game widget doesn't have the primary focus. This allows focus nodes on overlay widgets to take precedence on keyboard resolving. Also, add focus scope in the game widget for when the overlay is removed, the focus goes back to the game. Also, add tests for GameWidget for all these cases and some more.
This ignores keyboard events if the game widget doesn't have the primary focus. This allows focus nodes on overlay widgets to take precedence on keyboard resolving. Also, add focus scope in the game widget for when the overlay is removed, the focus goes back to the game. Also, add tests for GameWidget for all these cases and some more.
Description
This ignores keyboard events if the game widget doesn't have the primary focus. This allows focus nodes on overlay widgets to take precedence on keyboard resolving.
Also, add focus scope in the game widget for when the overlay is removed, the focus goes back to the game.
Also, add tests for
GameWidget
for all these cases and some more.Checklist
fix:
,feat:
,docs:
etc).docs
and added dartdoc comments with///
.examples
.Breaking Change
Related Issues
This is related to: