From 9134af7ac0b3e6962f55d27dcb149b7259b94033 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Mon, 9 Jul 2007 17:11:14 +0000 Subject: - wacom configuration: add "pad" InputDevice section --- lib/Xconfig/xfree.pm | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'lib') diff --git a/lib/Xconfig/xfree.pm b/lib/Xconfig/xfree.pm index a3dda06..8248fe9 100644 --- a/lib/Xconfig/xfree.pm +++ b/lib/Xconfig/xfree.pm @@ -275,21 +275,20 @@ sub set_wacoms { $raw_X->remove_InputDevices('wacom'); my $layout = get_ServerLayout($raw_X)->{InputDevice} ||= []; - @$layout = grep { $_->{val} !~ /^"(Stylus|Eraser|Cursor)/ } @$layout; + @$layout = grep { $_->{val} !~ /^"(Stylus|Eraser|Cursor|Pad)/ } @$layout; @wacoms or return; - my %Modes = (Stylus => 'Absolute', Eraser => 'Absolute', Cursor => 'Relative'); - + my @Modes = ('Stylus', 'Eraser', 'Cursor', 'Pad'); + each_index { my $wacom = $_; - foreach (keys %Modes) { + foreach (@Modes) { my $identifier = $_ . ($::i + 1); my $h = { Identifier => { val => $identifier }, Driver => { val => 'wacom' }, Type => { val => lc $_, Option => 1 }, Device => { val => $wacom->{Device}, Option => 1 }, - Mode => { val => $Modes{$_}, Option => 1 }, if_($wacom->{USB}, USB => { Option => 1 }) }; $raw_X->add_Section('InputDevice', $h); -- cgit v1.2.1