summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2004-04-22 09:29:32 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2004-04-22 09:29:32 +0000
commit9759e6587e6bae5522c56aeabe69d0330a2a2079 (patch)
tree5575c3577076d91d2f08d6bea57dc23dd982e8ca
parentdfd9a09a49599acd5484553aa66fda867178b575 (diff)
downloaddrakx-backup-do-not-use-9759e6587e6bae5522c56aeabe69d0330a2a2079.tar
drakx-backup-do-not-use-9759e6587e6bae5522c56aeabe69d0330a2a2079.tar.gz
drakx-backup-do-not-use-9759e6587e6bae5522c56aeabe69d0330a2a2079.tar.bz2
drakx-backup-do-not-use-9759e6587e6bae5522c56aeabe69d0330a2a2079.tar.xz
drakx-backup-do-not-use-9759e6587e6bae5522c56aeabe69d0330a2a2079.zip
switch to new harddrake data structure
-rwxr-xr-xperl-install/standalone/harddrake24
-rwxr-xr-xperl-install/standalone/service_harddrake5
2 files changed, 5 insertions, 4 deletions
diff --git a/perl-install/standalone/harddrake2 b/perl-install/standalone/harddrake2
index bd233db79..9afdcf78a 100755
--- a/perl-install/standalone/harddrake2
+++ b/perl-install/standalone/harddrake2
@@ -243,8 +243,8 @@ my $index = 0;
my @classes;
# Fill the graphic devices tree with a "tree branch" widget per device category
-foreach (@harddrake::data::tree) {
- my ($Ident, $title, $icon, $configurator, $detector) = @$_;
+foreach my $hw_class (@harddrake::data::tree) {
+ my ($Ident, $title, $icon, $configurator, $detector) = @$hw_class{qw(class string icon configurator detector)};
next if ref($detector) ne "CODE"; #skip class witouth detector
# blacklist agp controllers b/c string is not yet translated:
next if $Ident eq 'AGP';
diff --git a/perl-install/standalone/service_harddrake b/perl-install/standalone/service_harddrake
index 842fb60fd..20e43e995 100755
--- a/perl-install/standalone/service_harddrake
+++ b/perl-install/standalone/service_harddrake
@@ -38,8 +38,9 @@ my (%config, $wait);
my $in;
my $splash = -f '/proc/splash';
# For each hw, class, detect device, compare and offer to reconfigure if needed
-foreach (@harddrake::data::tree) {
- my ($Ident, $item, undef, $configurator, $detector, $do_it) = @$_;
+foreach my $hw_class (@harddrake::data::tree) {
+ my ($Ident, $item, $configurator, $detector, $do_it) = @$hw_class{qw(class string configurator detector checked_on_boot)};
+
next unless $do_it ^ $invert_do_it;
# No detector ? (should never happen but who know ?)
ref($detector) eq 'CODE' or next;