mirror of
https://github.com/systemd/systemd.git
synced 2025-03-14 04:58:28 +03:00
Include dpad buttons in joystick detection (#6240)
Since f472d466ec26 ("Remove BTN_DPAD_* keys from ID_INPUT_KEY test (#5701)") dpad buttons are excluded from keyboard keys for keyboard detection. Include them in joystick buttons for joystick detection.
This commit is contained in:
parent
16a5d4128f
commit
b876bc09b1
@ -211,6 +211,8 @@ static bool test_pointers(struct udev_device *dev,
|
||||
has_joystick_axes_or_buttons = test_bit(button, bitmask_key);
|
||||
for (button = BTN_TRIGGER_HAPPY1; button <= BTN_TRIGGER_HAPPY40 && !has_joystick_axes_or_buttons; button++)
|
||||
has_joystick_axes_or_buttons = test_bit(button, bitmask_key);
|
||||
for (button = BTN_DPAD_UP; button <= BTN_DPAD_RIGHT && !has_joystick_axes_or_buttons; button++)
|
||||
has_joystick_axes_or_buttons = test_bit(button, bitmask_key);
|
||||
for (axis = ABS_RX; axis < ABS_PRESSURE && !has_joystick_axes_or_buttons; axis++)
|
||||
has_joystick_axes_or_buttons = test_bit(axis, bitmask_abs);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user