-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
bevy_input_focus improvements (follow-up PR) #16665
Conversation
- Initialize InputFocusVisible resource. - Make `input_focus` available from `bevy` module.
crates/bevy_input_focus/src/lib.rs
Outdated
@@ -135,6 +138,13 @@ fn dispatch_keyboard_input( | |||
} | |||
} | |||
|
|||
/// System which synchronizes the a11y focus state with the input focus state. | |||
fn sync_a11y_focus(focus: Res<InputFocus>, mut a11y_focus: ResMut<Focus>) { |
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.
This seems silly: shouldn't we just change the a11y focus to use the new resource?
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.
Uh, I did it this way because my understanding was (based on our previous discussion) that we couldn't have bevy_a11y
depend on bevy_input_focus
.
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.
Hmm. Maybe I'm misremembering or maybe there was a micommunication, but bevy_a11y depending on bevy_input_focus definitely seems more correct than the reverse (like it is now).
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.
I think we should split off the bevy_a11y changes and merge the rest as trivial :)
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.
Missed a change, but once that's done this LGTM and I'll merge as trivial.
This adds a few minor items which were left out of the previous PR:
input_focus
available frombevy
module.I've tested this using VoiceOver on Mac OS. It works, but it needs considerable polish.