summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/Xconfig/xfree.pm14
-rw-r--r--perl-install/Xconfig/xfree3.pm6
-rw-r--r--perl-install/Xconfig/xfreeX.pm16
-rw-r--r--perl-install/install_any.pm10
-rw-r--r--perl-install/install_steps_gtk.pm8
-rw-r--r--perl-install/interactive.pm54
6 files changed, 54 insertions, 54 deletions
diff --git a/perl-install/Xconfig/xfree.pm b/perl-install/Xconfig/xfree.pm
index 9a44749ae..8df42bd8a 100644
--- a/perl-install/Xconfig/xfree.pm
+++ b/perl-install/Xconfig/xfree.pm
@@ -10,17 +10,15 @@ use Xconfig::xfree4;
use log;
-#- files are optional
sub read {
- my ($class, $xfree3_file, $xfree4_file) = @_;
- bless { xfree3 => eval { Xconfig::xfree3->read($xfree3_file) } || [],
- xfree4 => eval { Xconfig::xfree4->read($xfree4_file) } || [] }, $class;
+ my ($class, $o_xfree3_file, $o_xfree4_file) = @_;
+ bless { xfree3 => eval { Xconfig::xfree3->read($o_xfree3_file) } || [],
+ xfree4 => eval { Xconfig::xfree4->read($o_xfree4_file) } || [] }, $class;
}
-#- files are optional
sub write {
- my ($both, $xfree3_file, $xfree4_file) = @_;
- $both->{xfree3} ? $both->{xfree3}->write($xfree3_file) : unlink($xfree3_file);
- $both->{xfree4} ? $both->{xfree4}->write($xfree4_file) : unlink($xfree4_file);
+ my ($both, $o_xfree3_file, $o_xfree4_file) = @_;
+ $both->{xfree3} ? $both->{xfree3}->write($o_xfree3_file) : unlink($o_xfree3_file);
+ $both->{xfree4} ? $both->{xfree4}->write($o_xfree4_file) : unlink($o_xfree4_file);
}
sub empty_config {
diff --git a/perl-install/Xconfig/xfree3.pm b/perl-install/Xconfig/xfree3.pm
index 8d6ce63da..450ce3461 100644
--- a/perl-install/Xconfig/xfree3.pm
+++ b/perl-install/Xconfig/xfree3.pm
@@ -102,11 +102,11 @@ sub new_device_sections {
}
sub is_fbdev {
- my ($raw_X, $Screen) = @_;
+ my ($raw_X, $o_Screen) = @_;
- my $Screen_ = $Screen || $raw_X->get_default_screen or return;
+ my $Screen = $o_Screen || $raw_X->get_default_screen or return;
- val($Screen_->{Server}) eq 'FBDev';
+ val($Screen->{Server}) eq 'FBDev';
}
sub set_Option {}
diff --git a/perl-install/Xconfig/xfreeX.pm b/perl-install/Xconfig/xfreeX.pm
index e8d5f33f4..7f79f19f9 100644
--- a/perl-install/Xconfig/xfreeX.pm
+++ b/perl-install/Xconfig/xfreeX.pm
@@ -15,14 +15,14 @@ sub empty_config {
}
sub read {
- my ($class, $file) = @_;
- $file ||= ($::prefix || '') . (bless {}, $class)->config_file;
+ my ($class, $o_file) = @_;
+ my $file = $o_file || ($::prefix || '') . (bless {}, $class)->config_file;
my $raw_X = Xconfig::parse::read_XF86Config($file);
bless $raw_X, $class;
}
sub write {
- my ($raw_X, $file) = @_;
- $file ||= ($::prefix || '') . $raw_X->config_file;
+ my ($raw_X, $o_file) = @_;
+ my $file = $o_file || ($::prefix || '') . $raw_X->config_file;
rename $file, "$file.old";
Xconfig::parse::write_XF86Config($raw_X, $file);
}
@@ -167,8 +167,8 @@ sub set_load_module {
}
sub get_resolution {
- my ($raw_X, $Screen) = @_;
- $Screen ||= $raw_X->get_default_screen or return {};
+ my ($raw_X, $o_Screen) = @_;
+ my $Screen = $o_Screen || $raw_X->get_default_screen or return {};
my $depth = val($Screen->{DefaultColorDepth});
my $Display = find { !$depth || val($_->{l}{Depth}) eq $depth } @{$Screen->{Display} || []} or return {};
@@ -177,9 +177,9 @@ sub get_resolution {
}
sub set_resolution {
- my ($raw_X, $resolution, $Screen_) = @_;
+ my ($raw_X, $resolution, $o_Screen_) = @_;
- foreach my $Screen ($Screen_ ? $Screen_ : $raw_X->get_screens) {
+ foreach my $Screen ($o_Screen_ ? $o_Screen_ : $raw_X->get_screens) {
$Screen ||= $raw_X->get_default_screen or internal_error('no screen');
$Screen->{DefaultColorDepth} = { val => $resolution->{Depth} };
diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm
index f0ce7fcb9..a43dc80c8 100644
--- a/perl-install/install_any.pm
+++ b/perl-install/install_any.pm
@@ -1142,11 +1142,11 @@ sub install {
}
sub ensure_is_installed {
- my ($do, $pkg, $file, $auto) = @_;
+ my ($do, $pkg, $file, $b_auto) = @_;
if (! -e "$::prefix$file") {
$do->{o}->ask_okcancel('', N("The package %s needs to be installed. Do you want to install it?", $pkg), 1)
- or return if !$auto;
+ or return if !$b_auto;
$do->{o}->do_pkgs->install($pkg);
}
if (! -e "$::prefix$file") {
@@ -1157,9 +1157,9 @@ sub ensure_is_installed {
}
sub check_kernel_module_packages {
- my ($do, $base_name, $ext_name) = @_;
+ my ($do, $base_name, $o_ext_name) = @_;
- if (!$ext_name || pkgs::packageByName($do->{o}{packages}, $ext_name)) {
+ if (!$o_ext_name || pkgs::packageByName($do->{o}{packages}, $o_ext_name)) {
my @rpms;
foreach my $p (@{$do->{o}{packages}{depslist}}) {
my ($ext, $version_release) = $p->name =~ /kernel[^\-]*(-smp|-enterprise|-secure)?(?:-([^\-]+))?$/
@@ -1170,7 +1170,7 @@ sub check_kernel_module_packages {
log::l("found kernel module packages $name");
push @rpms, $name;
}
- @rpms > 0 and return [ @rpms, if_($ext_name, $ext_name) ];
+ @rpms > 0 and return [ @rpms, if_($o_ext_name, $o_ext_name) ];
}
return undef;
}
diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm
index 577e78654..589828e49 100644
--- a/perl-install/install_steps_gtk.pm
+++ b/perl-install/install_steps_gtk.pm
@@ -284,7 +284,7 @@ sub reallyChooseGroups {
}
sub choosePackagesTree {
- my ($o, $packages, $limit_to_medium) = @_;
+ my ($o, $packages, $o_limit_to_medium) = @_;
my $available = install_any::getAvailableSpace($o);
my $availableCorrected = pkgs::invCorrectSize($available / sqr(1024)) * sqr(1024);
@@ -304,7 +304,7 @@ sub choosePackagesTree {
build_tree => sub {
my ($add_node, $flat) = @_;
if ($flat) {
- foreach (sort map { $_->name } grep { !$limit_to_medium || pkgs::packageMedium($packages, $_) == $limit_to_medium }
+ foreach (sort map { $_->name } grep { !$o_limit_to_medium || pkgs::packageMedium($packages, $_) == $o_limit_to_medium }
@{$packages->{depslist}}) {
$add_node->($_, undef);
}
@@ -314,7 +314,7 @@ sub choosePackagesTree {
#$fl{$_} = $o->{compssUsersChoice}{$_} foreach @{$o->{compssUsers}{$root}{flags}}; #- FEATURE:improve choce of packages...
$fl{$_} = 1 foreach @{$o->{compssUsers}{$root}{flags}};
foreach my $p (@{$packages->{depslist}}) {
- !$limit_to_medium || pkgs::packageMedium($packages, $p) == $limit_to_medium or next;
+ !$o_limit_to_medium || pkgs::packageMedium($packages, $p) == $o_limit_to_medium or next;
my @flags = $p->rflags;
next if !($p->rate && any { any { !/^!/ && $fl{$_} } split('\|\|') } @flags);
$p->rate >= 3 ?
@@ -423,7 +423,7 @@ sub choosePackagesTree {
],
state => {
auto_deps => 1,
- flat => $limit_to_medium,
+ flat => $o_limit_to_medium,
},
};
diff --git a/perl-install/interactive.pm b/perl-install/interactive.pm
index 63fe9a347..46a325631 100644
--- a/perl-install/interactive.pm
+++ b/perl-install/interactive.pm
@@ -84,8 +84,8 @@ sub new($) {
}
sub vnew {
- my ($_type, $su, $icon) = @_;
- $su = $su eq "su";
+ my ($_type, $o_su, $o_icon) = @_;
+ my $su = $o_su eq "su";
if ($ENV{INTERACTIVE_HTTP}) {
require interactive::http;
return interactive::http->new;
@@ -100,7 +100,7 @@ sub vnew {
eval { require interactive::gtk };
if (!$@) {
my $o = interactive::gtk->new;
- if ($icon && $icon ne 'default' && !$::isWizard) { $o->{icon} = $icon } else { undef $o->{icon} }
+ if ($o_icon && $o_icon ne 'default' && !$::isWizard) { $o->{icon} = $o_icon } else { undef $o->{icon} }
return $o;
}
}
@@ -127,12 +127,12 @@ sub ask_warn {
ask_warn_($o, { title => $title, messages => $message });
}
sub ask_yesorno {
- my ($o, $title, $message, $def) = @_;
- ask_yesorno_($o, { title => $title, messages => $message }, $def);
+ my ($o, $title, $message, $b_def) = @_;
+ ask_yesorno_($o, { title => $title, messages => $message }, $b_def);
}
sub ask_okcancel {
- my ($o, $title, $message, $def) = @_;
- ask_okcancel_($o, { title => $title, messages => $message }, $def);
+ my ($o, $title, $message, $b_def) = @_;
+ ask_okcancel_($o, { title => $title, messages => $message }, $b_def);
}
sub ask_warn_ {
@@ -141,26 +141,26 @@ sub ask_warn_ {
}
sub ask_yesorno_ {
- my ($o, $common, $def) = @_;
+ my ($o, $common, $b_def) = @_;
$common->{cancel} = '';
- ask_from_listf_raw($o, $common, sub { translate($_[0]) }, [ N_("Yes"), N_("No") ], $def ? "Yes" : "No") eq "Yes";
+ ask_from_listf_raw($o, $common, sub { translate($_[0]) }, [ N_("Yes"), N_("No") ], $b_def ? "Yes" : "No") eq "Yes";
}
sub ask_okcancel_ {
- my ($o, $common, $def) = @_;
+ my ($o, $common, $b_def) = @_;
if ($::isWizard) {
$::no_separator = 1;
- $common->{focus_cancel} = !$def;
+ $common->{focus_cancel} = !$b_def;
ask_from_no_check($o, $common, []);
} else {
- ask_from_listf_raw($o, $common, sub { translate($_[0]) }, [ N_("Ok"), N_("Cancel") ], $def ? "Ok" : "Cancel") eq "Ok";
+ ask_from_listf_raw($o, $common, sub { translate($_[0]) }, [ N_("Ok"), N_("Cancel") ], $b_def ? "Ok" : "Cancel") eq "Ok";
}
}
sub ask_file {
- my ($o, $title, $dir) = @_;
- $o->ask_fileW($title, $dir);
+ my ($o, $title, $o_dir) = @_;
+ $o->ask_fileW($title, $o_dir);
}
sub ask_fileW {
my ($o, $title, $_dir) = @_;
@@ -168,22 +168,22 @@ sub ask_fileW {
}
sub ask_from_list {
- my ($o, $title, $message, $l, $def) = @_;
- ask_from_listf($o, $title, $message, undef, $l, $def);
+ my ($o, $title, $message, $l, $o_def) = @_;
+ ask_from_listf($o, $title, $message, undef, $l, $o_def);
}
sub ask_from_list_ {
- my ($o, $title, $message, $l, $def) = @_;
- ask_from_listf($o, $title, $message, sub { translate($_[0]) }, $l, $def);
+ my ($o, $title, $message, $l, $o_def) = @_;
+ ask_from_listf($o, $title, $message, sub { translate($_[0]) }, $l, $o_def);
}
sub ask_from_listf_ {
- my ($o, $title, $message, $f, $l, $def) = @_;
- ask_from_listf($o, $title, $message, sub { translate($f->(@_)) }, $l, $def);
+ my ($o, $title, $message, $f, $l, $o_def) = @_;
+ ask_from_listf($o, $title, $message, sub { translate($f->(@_)) }, $l, $o_def);
}
sub ask_from_listf {
- my ($o, $title, $message, $f, $l, $def) = @_;
- ask_from_listf_raw($o, { title => $title, messages => $message }, $f, $l, $def);
+ my ($o, $title, $message, $f, $l, $o_def) = @_;
+ ask_from_listf_raw($o, { title => $title, messages => $message }, $f, $l, $o_def);
}
sub ask_from_listf_raw {
my ($_o, $_common, $_f, $l, $_def) = @_;
@@ -382,11 +382,13 @@ sub ask_from_no_check {
my ($o, $common, $l) = @_;
ask_from_normalize($o, $common, $l);
$common->{cancel} = '' if !defined wantarray();
- $o->ask_fromW($common, partition { !$_->{advanced} } @$l);
+ my ($l1, $l2) = partition { !$_->{advanced} } @$l;
+ $o->ask_fromW($common, $l1, $l2);
}
sub ask_from_real {
my ($o, $common, $l) = @_;
- my $v = $o->ask_fromW($common, partition { !$_->{advanced} } @$l);
+ my ($l1, $l2) = partition { !$_->{advanced} } @$l;
+ my $v = $o->ask_fromW($common, $l1, $l2);
%$common = ();
$v;
}
@@ -431,10 +433,10 @@ sub ask_browse_tree_info_refW { #- default definition, do not use with too many
}
sub wait_message {
- my ($o, $title, $message, $temp) = @_;
+ my ($o, $title, $message, $b_temp) = @_;
my $w = $o->wait_messageW($title, [ N("Please wait"), deref($message) ]);
- push @tempory::objects, $w if $temp;
+ push @tempory::objects, $w if $b_temp;
my $b = before_leaving { $o->wait_message_endW($w) };
#- enable access through set