From 374adf19288216f2e114b898c43e62dbf817fa19 Mon Sep 17 00:00:00 2001 From: Pascal Terjan Date: Mon, 8 Feb 2010 19:34:54 +0000 Subject: Add back and fix lvm in patitioning wizard --- perl-install/fs/partitioning_wizard.pm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'perl-install/fs/partitioning_wizard.pm') diff --git a/perl-install/fs/partitioning_wizard.pm b/perl-install/fs/partitioning_wizard.pm index d95f0a63b..b71ea9384 100644 --- a/perl-install/fs/partitioning_wizard.pm +++ b/perl-install/fs/partitioning_wizard.pm @@ -87,7 +87,7 @@ sub partitionWizardSolutions { # each solution is a [ score, text, function ], where the function retunrs true if succeeded my @hds_rw = grep { !$_->{readonly} } @$hds; - my @hds_can_add = grep { $_->can_add } @hds_rw; + my @hds_can_add = grep { $_->{type} ne 'hd' || $_->can_add } @hds_rw; if (fs::get::hds_free_space(@hds_can_add) > $min_linux) { $solutions{free_space} = [ 30, N("Use free space"), sub { fsedit::auto_allocate($all_hds, $partitions); 1 } ]; } else { @@ -504,6 +504,7 @@ sub main { my @kinds = map { diskdrake::hd_gtk::hd2kind($_) } sort { $a->{is_removable} <=> $b->{is_removable} } @{$all_hds->{hds} }; push @kinds, map { diskdrake::hd_gtk::raid2kind($_) } @{$all_hds->{raids}}; + push @kinds, map { diskdrake::hd_gtk::lvm2kind($_) } @{$all_hds->{lvms}}; my $hdchoice = Gtk2::HBox->new; @@ -511,7 +512,8 @@ sub main { my $combobox = Gtk2::ComboBox->new_text; foreach (@kinds) { - my $info = $_->{val}{info} || $_->{val}{name}; + my $info = $_->{val}{info} || $_->{val}{device}; + $info =~ s|^(?:.*/)?(.{24}).*|$1|; $info .= " (" . formatXiB($_->{val}{totalsectors}, 512) . ")" if $_->{val}{totalsectors}; $combobox->append_text($info); } -- cgit v1.2.1