Expose Winit's `KeyEvent::repeat` in `KeyboardInput`
Objective
I would like to know if an event was emitted because of "key repeats" or not. Winit already exposes this information, but it isn't sent along by Bevy, which this PR intends to address.
Solution
Expose winit::event::KeyEvent::repeat in bevy::input::keyboard::KeyboardInput.
Testing
Just hold any regular key down and only the first event should have KeyboardInput::repeat set to false. Most OSs have "key repeat" enabled by default.
Changelog
- Added
KeyboardInput::repeatsignifying if this event was sent in response to a "key repeat" event or not.
AFAICS this change is additive so this:
Added KeyboardInput::repeat signifying if this event was sent in response to a "key repeat" event or not.
Could be moved to the Changelog section of the PR description and the Migration Guide removed.
Thanks for adding it!
AFAICS this change is additive so this:
Added KeyboardInput::repeat signifying if this event was sent in response to a "key repeat" event or not.
Could be moved to the Changelog section of the PR description and the Migration Guide removed.
Ah, that was by mistake! Thanks!