Skip to content
This repository has been archived by the owner on Apr 12, 2021. It is now read-only.

Commit

Permalink
nixos/libinput: apply options to all device types
Browse files Browse the repository at this point in the history
Instead of assign the libinput options to touchpad devices only, it
should be appied by any device using libinput.
Due to the fact that `40-libinput.conf` already defines libinput as
driver for any detected input device, we can use `MatchDriver` to appy
options.

(cherry picked from commit d616928)
  • Loading branch information
sylv-io authored and worldofpeace committed Nov 19, 2019
1 parent 08e503b commit ea83c79
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions nixos/modules/services/x11/hardware/libinput.nix
Expand Up @@ -209,12 +209,12 @@ in {

services.xserver.config =
''
# Automatically enable the libinput driver for all touchpads.
# General libinput configuration.
# See CONFIGURATION DETAILS section of man:libinput(4).
Section "InputClass"
Identifier "libinputConfiguration"
MatchIsTouchpad "on"
MatchDriver "libinput"
${optionalString (cfg.dev != null) ''MatchDevicePath "${cfg.dev}"''}
Driver "libinput"
Option "AccelProfile" "${cfg.accelProfile}"
${optionalString (cfg.accelSpeed != null) ''Option "AccelSpeed" "${cfg.accelSpeed}"''}
${optionalString (cfg.buttonMapping != null) ''Option "ButtonMapping" "${cfg.buttonMapping}"''}
Expand Down

0 comments on commit ea83c79

Please sign in to comment.