bevy/crates/bevy_input/src
Jim Eckerlein 13f50c7a53
Rename keys like LAlt to AltLeft (#8792)
# Objective

The
[`KeyCode`](https://github.com/bevyengine/bevy/blob/main/crates/bevy_input/src/keyboard.rs#L86)
enum cases `LWin` and `RWin` are too opinionated because they are also
assigned meaning by non-Windows operating systems. macOS calls the keys
completely different.

## Solution

Match [winits
approach](https://github.com/rust-windowing/winit/blob/master/src/keyboard.rs#L1635)
naming convention.

---

## Migration Guide

Migrate by replacing:
- `LAlt` → `AltLeft`
- `RAlt` → `AltRight`
- `LBracket` → `BracketLeft`
- `RBracket` → `BracketRight`
- `LControl` → `ControlLeft`
- `RControl` → `ControlRight`
- `LShift` → `ShiftLeft`
- `RShift` → `ShiftRight`
- `LWin` → `SuperLeft`
- `RWin` → `SuperRight`
2023-06-15 01:37:04 +00:00
..
axis.rs add Axis::devices to get all the input devices (#5400) 2023-01-06 18:00:22 +00:00
common_conditions.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
gamepad.rs Require #[derive(Event)] on all Events (#7086) 2023-06-06 14:44:32 +00:00
input.rs reflect: stable type path v2 (#7184) 2023-06-05 20:31:20 +00:00
keyboard.rs Rename keys like LAlt to AltLeft (#8792) 2023-06-15 01:37:04 +00:00
lib.rs Touchpad magnify and rotate events (#8791) 2023-06-08 20:31:43 +00:00
mouse.rs Require #[derive(Event)] on all Events (#7086) 2023-06-06 14:44:32 +00:00
touch.rs Require #[derive(Event)] on all Events (#7086) 2023-06-06 14:44:32 +00:00
touchpad.rs Touchpad magnify and rotate events (#8791) 2023-06-08 20:31:43 +00:00