1
0
mirror of https://github.com/systemd/systemd.git synced 2024-12-22 17:35:35 +03:00

hwdb: Add property for keyboards without LEDs

It is useful for desktop environments to be able to show Caps-Lock or
Num-Lock status changes as an on-screen display when using a keyboard
that doesn't have LEDs for this.

Closes: #5559
This commit is contained in:
Bastien Nocera 2017-03-09 14:53:52 +01:00
parent 6a36cfec4a
commit b698b5cf85
2 changed files with 15 additions and 0 deletions

View File

@ -1304,3 +1304,16 @@ evdev:input:b0003v1050p0116*
evdev:input:b0003v05FEp1010*
XKB_FIXED_LAYOUT="us"
XKB_FIXED_VARIANT=""
######################### LACK OF MODIFIER LEDS ############################
# This section lists keyboard which do not have their own LEDs for some
# modifiers. Only Caps-Lock (KEYBOARD_LED_CAPSLOCK) and Num-Lock
# (KEYBOARD_LED_CAPSLOCK) are currently handled and need their values set
# to "0" to indicate the absence of LED.
#
# Presence of a LED is implicit when the property is absent.
# Logitech K750
evdev:input:b0003v046Dp4002*
KEYBOARD_LED_NUMLOCK=0
KEYBOARD_LED_CAPSLOCK=0

View File

@ -112,6 +112,8 @@ def property_grammar():
('ID_INPUT_TOUCHPAD_INTEGRATION', Or(('internal', 'external'))),
('XKB_FIXED_LAYOUT', STRING),
('XKB_FIXED_VARIANT', STRING),
('KEYBOARD_LED_NUMLOCK', Literal('0')),
('KEYBOARD_LED_CAPSLOCK', Literal('0')),
('ACCEL_MOUNT_MATRIX', mount_matrix),
)
fixed_props = [Literal(name)('NAME') - Suppress('=') - val('VALUE')