diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2002-07-29 19:40:31 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2002-07-29 19:40:31 +0000 |
commit | b79a22b24f0a5bfe15b3c1deba7460577b8410c4 (patch) | |
tree | 957f8c9017eb413422f389c85e29e13037854eb6 | |
parent | 0b88c22555f88c1a72395dd39d0e71e001d6ea57 (diff) | |
download | drakx-backup-do-not-use-b79a22b24f0a5bfe15b3c1deba7460577b8410c4.tar drakx-backup-do-not-use-b79a22b24f0a5bfe15b3c1deba7460577b8410c4.tar.gz drakx-backup-do-not-use-b79a22b24f0a5bfe15b3c1deba7460577b8410c4.tar.bz2 drakx-backup-do-not-use-b79a22b24f0a5bfe15b3c1deba7460577b8410c4.tar.xz drakx-backup-do-not-use-b79a22b24f0a5bfe15b3c1deba7460577b8410c4.zip |
allow to not mess with X config auxmouse
(that way mousedrake doesn't need to care about it)
-rw-r--r-- | perl-install/mouse.pm | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/perl-install/mouse.pm b/perl-install/mouse.pm index b9c8a89c7..799d4fba8 100644 --- a/perl-install/mouse.pm +++ b/perl-install/mouse.pm @@ -336,7 +336,7 @@ sub detect() { } sub set_xfree_conf { - my ($mouse, $xfree_conf) = @_; + my ($mouse, $xfree_conf, $keep_auxmouse_unchanged) = @_; my @mice = map { { @@ -347,6 +347,11 @@ sub set_xfree_conf { }; } ($mouse, if_($mouse->{auxmouse}, $mouse->{auxmouse})); + if (!$mouse->{auxmouse} && $keep_auxmouse_unchanged) { + my (undef, @l) = $xfree_conf->get_mice; + push @mice, @l; + } + $xfree_conf->set_mice(@mice); } @@ -362,14 +367,14 @@ sub set_xfree_conf { #- $mouse->{MOUSETYPE} : type of the mouse : string : ex "ps/2" #- $mouse->{XEMU3} : emulate 3rd button : string : 'yes' or 'no' sub write_conf { - my ($mouse) = @_; + my ($mouse, $keep_auxmouse_unchanged) = @_; &write('', $mouse); modules::write_conf('') if $mouse->{device} eq "usbmouse" && !$::testing; require Xconfig::xfree; my $xfree_conf = Xconfig::xfree->read; - set_xfree_conf($mouse, $xfree_conf); + set_xfree_conf($mouse, $xfree_conf, $keep_auxmouse_unchanged); $xfree_conf->write; } |