diff options
-rw-r--r-- | perl-install/common.pm | 6 | ||||
-rw-r--r-- | perl-install/fs.pm | 2 | ||||
-rw-r--r-- | perl-install/install2.pm | 2 | ||||
-rw-r--r-- | perl-install/install_any.pm | 1 | ||||
-rw-r--r-- | perl-install/install_steps_gtk.pm | 4 | ||||
-rw-r--r-- | perl-install/install_steps_interactive.pm | 2 | ||||
-rw-r--r-- | perl-install/lang.pm | 8 | ||||
-rw-r--r-- | perl-install/mouse.pm | 15 |
8 files changed, 19 insertions, 21 deletions
diff --git a/perl-install/common.pm b/perl-install/common.pm index a6849e63f..cea5a0be3 100644 --- a/perl-install/common.pm +++ b/perl-install/common.pm @@ -589,8 +589,12 @@ sub formatTime($) { my ($s, $m, $h) = gmtime($_[0]); if ($h) { sprintf "%02d:%02d", $h, $m; + } elsif ($m > 1) { + _("%d minutes", $m); + } elsif ($m == 1) { + _("1 minute"); } else { - sprintf _("%d minutes"), $m; + _("%d seconds", $s); } } diff --git a/perl-install/fs.pm b/perl-install/fs.pm index 7b9563ebb..f12da5e86 100644 --- a/perl-install/fs.pm +++ b/perl-install/fs.pm @@ -71,7 +71,7 @@ sub get_mntpoints_from_fstab { $p->{device} eq $_->{device} or next; $_->{type} ne 'auto' && $_->{type} ne type2fs($p->{type}) and log::l("err, fstab and partition table do not agree for $_->{device} type: " . (type2fs($p->{type}) || type2name($p->{type})) . " vs $_->{type}"), next; - delete $_->{unsafeMntpoint} || !$_->{mntpoint} or next; + delete $p->{unsafeMntpoint} || !$p->{mntpoint} or next; $p->{mntpoint} = $_->{mntpoint}; $p->{options} = $_->{options}; } diff --git a/perl-install/install2.pm b/perl-install/install2.pm index 81f75436f..15f66bcff 100644 --- a/perl-install/install2.pm +++ b/perl-install/install2.pm @@ -417,7 +417,7 @@ sub setRootPassword { } #------------------------------------------------------------------------------ sub addUser { - return if $o->{isUpgrade}; + return if $o->{isUpgrade} && !$_[0]; $o->addUser($_[0]); install_any::setAuthentication($o); diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm index 6947d4b7f..29f5114a0 100644 --- a/perl-install/install_any.pm +++ b/perl-install/install_any.pm @@ -654,7 +654,6 @@ sub use_root_part { my $handle = any::inspect($part, $prefix) or die; fs::get_mntpoints_from_fstab($fstab, $handle->{dir}, 'uniq'); } - map { $_->{mntpoint} = 'swap_upgrade' } grep { isSwap($_) } @$fstab; #- use all available swap. fs::mount_all($fstab, $prefix); } diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm index bf3c76fc7..dfb43f872 100644 --- a/perl-install/install_steps_gtk.pm +++ b/perl-install/install_steps_gtk.pm @@ -749,8 +749,8 @@ sub init_sizes() { ($::rootheight, $::rootwidth) = my_gtk::gtkroot()->get_size; #- ($::rootheight, $::rootwidth) = (min(768, $::rootheight), min(1024, $::rootwidth)); ($::stepswidth, $::stepsheight) = (145, $::rootheight); - ($::logowidth, $::logoheight) = ($::rootwidth - $::stepswidth, 40); - ($::helpwidth, $::helpheight) = ($::rootwidth - $::stepswidth, 100); + ($::logowidth, $::logoheight) = ($::rootwidth - $::stepswidth, 40); + ($::helpwidth, $::helpheight) = ($::rootwidth - $::stepswidth, 104); ($::windowwidth, $::windowheight) = ($::rootwidth - $::stepswidth, $::rootheight - $::helpheight - $::logoheight); } diff --git a/perl-install/install_steps_interactive.pm b/perl-install/install_steps_interactive.pm index 4b7943bcd..d28fea76d 100644 --- a/perl-install/install_steps_interactive.pm +++ b/perl-install/install_steps_interactive.pm @@ -658,7 +658,7 @@ sub addUser { ), $::beginner ? () : ( _("Shell") => {val => \$u->{shell}, list => [ any::shells($o->{prefix}) ], not_edit => !$::expert} ), $o->{security} > 3 ? () : ( - _("Icon") => {val => \$u->{icon}, list => [ any::facesnames() ], icon2f => sub { any::face2xpm($_[0], $o->{prefix}) } }, + _("Icon") => {val => \$u->{icon}, list => [ any::facesnames($o->{prefix}) ], icon2f => sub { any::face2xpm($_[0], $o->{prefix}) } }, ), ], focus_out => sub { diff --git a/perl-install/lang.pm b/perl-install/lang.pm index cec746739..218ae85a6 100644 --- a/perl-install/lang.pm +++ b/perl-install/lang.pm @@ -289,12 +289,8 @@ sub write { $lang or return; - my $h = { LC_COLLATE => $lang }; - add2hash $h, { LC_CTYPE => $lang }; - add2hash $h, { LC_MESSAGES => $lang }; - add2hash $h, { LC_NUMERIC => $lang }; - add2hash $h, { LC_MONETARY => $lang }; - add2hash $h, { LC_TIME => $lang }; + my $h = { RPM_INSTALL_LANG => $ENV{RPM_INSTALL_LANG} }; + $h{$_} = $lang foreach qw(LC_COLLATE LC_CTYPE LC_MESSAGES LC_NUMERIC LC_MONETARY LC_TIME); if (my $l = $languages{$lang}) { add2hash $h, { LANG => $l->[2], LANGUAGE => $l->[3], KDE_LANG => $l->[3], RPM_INSTALL_LANG => $l->[3] }; diff --git a/perl-install/mouse.pm b/perl-install/mouse.pm index 2382f9f1e..cb3dd3d9c 100644 --- a/perl-install/mouse.pm +++ b/perl-install/mouse.pm @@ -169,22 +169,21 @@ sub detect() { detect_devices::hasMousePS2 and return { %{name2mouse("Generic Mouse (PS/2)")}, unsafe => 1 }; - eval { commands::modprobe("serial") }; - my ($r, $wacom) = mouseconfig(); return ($r, $wacom) if $r; - if (modules::get_alias("usb-interface") && detect_devices::hasUsbMouse()) { eval { modules::load("usbmouse"); modules::load("mousedev"); }; - if (!$@ && detect_devices::tryOpen("usbmouse")) { - $wacom or modules::unload("serial"); - return name2mouse("USB Mouse"), $wacom; + !$@ && detect_devices::tryOpen("usbmouse") and return name2mouse("USB Mouse"); + eval { + modules::unload("mousedev"); + modules::unload("usbmouse"); } - modules::unload("mousedev"); - modules::unload("usbmouse"); } + eval { commands::modprobe("serial") }; + my ($r, $wacom) = mouseconfig(); return ($r, $wacom) if $r; + #- defaults to generic serial mouse on ttyS0. #- Oops? using return let return a hash ref, if not using it, it return a list directly :-) return { %{name2mouse("Generic Mouse (serial)")}, device => "ttyS0", unsafe => 1 }; |