DeviceEvent { device_id: DeviceId(X(DeviceId(12))), event: Key(KeyboardInput { scancode: 42, state: Pressed, virtual_keycode: Some(LShift), modifiers: (empty) }) }
WindowEvent { window_id: WindowId(X(WindowId(117440513))), event: KeyboardInput { device_id: DeviceId(X(DeviceId(3))), input: KeyboardInput { scancode: 42, state: Pressed, virtual_keycode: Some(LShift), modifiers: SHIFT }, is_synthetic: false } }
DeviceEvent { device_id: DeviceId(X(DeviceId(12))), event: Key(KeyboardInput { scancode: 56, state: Pressed, virtual_keycode: Some(LAlt), modifiers: SHIFT }) }
WindowEvent { window_id: WindowId(X(WindowId(117440513))), event: KeyboardInput { device_id: DeviceId(X(DeviceId(3))), input: KeyboardInput { scancode: 56, state: Pressed, virtual_keycode: None, modifiers: SHIFT | ALT }, is_synthetic: false } }
DeviceEvent { device_id: DeviceId(X(DeviceId(12))), event: Key(KeyboardInput { scancode: 42, state: Released, virtual_keycode: Some(LShift), modifiers: SHIFT | ALT }) }
WindowEvent { window_id: WindowId(X(WindowId(117440513))), event: KeyboardInput { device_id: DeviceId(X(DeviceId(3))), input: KeyboardInput { scancode: 42, state: Released, virtual_keycode: Some(LShift), modifiers: ALT }, is_synthetic: false } }
DeviceEvent { device_id: DeviceId(X(DeviceId(12))), event: Key(KeyboardInput { scancode: 56, state: Released, virtual_keycode: Some(LAlt), modifiers: ALT }) }
WindowEvent { window_id: WindowId(X(WindowId(117440513))), event: KeyboardInput { device_id: DeviceId(X(DeviceId(3))), input: KeyboardInput { scancode: 56, state: Released, virtual_keycode: Some(LAlt), modifiers: (empty) }, is_synthetic: false } }
Platform:
X11 on Linux
Steps to reproduce:
cargo run --example window | grep KeyboardInputExpected result:
A
WindowEventwithvirtual_keycode: Some(LAlt)Actual result:
A
WindowEventwithvirtual_keycode: NoneThe below output is from the input sequence:
press LShift, press LAlt, release LShift, release LAlt
Note that the
virtual_keycodeinDeviceEventis correct. OnlyWindowEventis affected. The same problem also happens if I hold RShift instead of LShift.