summaryrefslogtreecommitdiffstats
path: root/perl-install/mouse.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2002-03-11 16:50:06 +0000
committerPascal Rigaux <pixel@mandriva.com>2002-03-11 16:50:06 +0000
commit16e296fba4df19b2f9a2a988cc87830b1c570e30 (patch)
tree76465efd060e26bc9b9b12b85cff10874b0c3283 /perl-install/mouse.pm
parent45dc12a94fcfe30c49be23b2d9ac13a3a06f21e5 (diff)
downloaddrakx-backup-do-not-use-16e296fba4df19b2f9a2a988cc87830b1c570e30.tar
drakx-backup-do-not-use-16e296fba4df19b2f9a2a988cc87830b1c570e30.tar.gz
drakx-backup-do-not-use-16e296fba4df19b2f9a2a988cc87830b1c570e30.tar.bz2
drakx-backup-do-not-use-16e296fba4df19b2f9a2a988cc87830b1c570e30.tar.xz
drakx-backup-do-not-use-16e296fba4df19b2f9a2a988cc87830b1c570e30.zip
(fullname2mouse): workaround when "1 Button" is not found
Diffstat (limited to 'perl-install/mouse.pm')
-rw-r--r--perl-install/mouse.pm5
1 files changed, 5 insertions, 0 deletions
diff --git a/perl-install/mouse.pm b/perl-install/mouse.pm
index 9009d811d..1d47d1bb2 100644
--- a/perl-install/mouse.pm
+++ b/perl-install/mouse.pm
@@ -170,11 +170,16 @@ sub fullname2mouse {
my ($fname, %opts) = @_;
my ($type, @l) = split '\|', $fname;
my ($name) = pop @l;
+ search:
$opts{device} ||= $mice{$type}[0][0];
foreach (@{$mice{$type}[1]}) {
my $l = raw2mouse($type, $_);
$name eq $l->{name} and return { %$l, %opts };
}
+ if ($name eq '1 Button') {
+ $name = "Generic 2 Button Mouse";
+ goto search;
+ }
die "$fname not found ($type, $name)";
}