diff options
author | damien <damien@mandriva.com> | 2000-12-02 23:40:03 +0000 |
---|---|---|
committer | damien <damien@mandriva.com> | 2000-12-02 23:40:03 +0000 |
commit | 04f2c9d38fbabe790866de773204d4dfc046bdfe (patch) | |
tree | 49f7f03564a4e79f2db27d8f09e9b6547d3ee8e3 | |
parent | 3bbe50efa24feda87401646458c5e00809cf0db1 (diff) | |
download | drakx-04f2c9d38fbabe790866de773204d4dfc046bdfe.tar drakx-04f2c9d38fbabe790866de773204d4dfc046bdfe.tar.gz drakx-04f2c9d38fbabe790866de773204d4dfc046bdfe.tar.bz2 drakx-04f2c9d38fbabe790866de773204d4dfc046bdfe.tar.xz drakx-04f2c9d38fbabe790866de773204d4dfc046bdfe.zip |
incorporated in the firewall branch
-rwxr-xr-x | perl-install/standalone/mousedrake | 33 |
1 files changed, 3 insertions, 30 deletions
diff --git a/perl-install/standalone/mousedrake b/perl-install/standalone/mousedrake index 5736f79ee..7e9bfdce7 100755 --- a/perl-install/standalone/mousedrake +++ b/perl-install/standalone/mousedrake @@ -6,6 +6,7 @@ use common qw(:common :system); use interactive; use mouse; use c; +#require 'dumpvar.pl'; local $_ = join '', @ARGV; @@ -33,7 +34,6 @@ if (!$mouse || !$::auto) { eval { modules::load($c->[1], "serial_usb") }; } } - $mouse->{XEMU3} = 'yes' if $mouse->{nbuttons} < 3 && (!$::noauto || $in->ask_yesorno('', _("Emulate third button?"), 1)); $o->{mouse}{device} = @@ -42,34 +42,7 @@ $o->{mouse}{device} = \&mouse::serial_port2text, [ mouse::serial_ports ]) if $mouse->{type} eq 'serial'; -mouse::write('', $mouse); -modules::write_conf('') if $mouse->{device} eq "usbmouse" && !$::testing; - -my $f = "/etc/X11/XF86Config"; -my $g = "/etc/X11/XF86Config-4"; - -my @zaxis = ( - $mouse->{nbuttons} > 3 ? [ "ZAxisMapping", "4 5" ] : (), - $mouse->{nbuttons} > 5 ? [ "ZAxisMapping", "6 7" ] : (), - $mouse->{nbuttons} < 3 ? ([ "Emulate3Buttons" ], [ "Emulate3Timeout", "50" ]) : () -); - -my $zaxis = join('', map { qq(\n $_->[0]) . ($_->[1] && qq( $_->[1])) } @zaxis); -substInFile { - if (/^Section\s+"Pointer"/ .. /^EndSection/) { - $_ = '' if /(ZAxisMapping|Emulate3)/; #- remove existing line - s|^(\s*Protocol\s+).*|$1"$mouse->{XMOUSETYPE}"|; - s|^(\s*Device\s+).*|$1"/dev/mouse"$zaxis|; - } -} $f if -e $f && !$::testing; - -$zaxis = join('', map { qq(\n Option "$_->[0]") . ($_->[1] && qq( "$_->[1]")) } @zaxis); -substInFile { - if (/Identifier\s+"Mouse1"/ .. /^EndSection/) { - $_ = '' if /(ZAxisMapping|Emulate3)/; #- remove existing line - s|^(\s*Option\s+"Protocol"\s+).*|$1"$mouse->{XMOUSETYPE}"|; - s|^(\s*Option\s+"Device"\s+).*|$1"/dev/mouse"$zaxis|; - } -} $g if -e $g && !$::testing; +#dumpValue(\$mouse); +mouse::write_conf($mouse); $in->exit(0); |