summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Terjan <pterjan@mandriva.org>2010-04-21 16:53:30 +0000
committerPascal Terjan <pterjan@mandriva.org>2010-04-21 16:53:30 +0000
commit138cdfda46a96526c3cd8ebc5a09d7da0b732f30 (patch)
tree04fd2c6f9275422a483b3dd441f00e1ab2f0402a
parentc5db0bde74fc91561ce2449a6da5be5a3211227b (diff)
downloaddrakx-backup-do-not-use-138cdfda46a96526c3cd8ebc5a09d7da0b732f30.tar
drakx-backup-do-not-use-138cdfda46a96526c3cd8ebc5a09d7da0b732f30.tar.gz
drakx-backup-do-not-use-138cdfda46a96526c3cd8ebc5a09d7da0b732f30.tar.bz2
drakx-backup-do-not-use-138cdfda46a96526c3cd8ebc5a09d7da0b732f30.tar.xz
drakx-backup-do-not-use-138cdfda46a96526c3cd8ebc5a09d7da0b732f30.zip
Do not display dm-crypt partitions in separate tab, display included partition directly in-place
-rw-r--r--perl-install/NEWS2
-rw-r--r--perl-install/diskdrake/hd_gtk.pm18
2 files changed, 10 insertions, 10 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS
index fad3eb531..cc371beda 100644
--- a/perl-install/NEWS
+++ b/perl-install/NEWS
@@ -3,6 +3,8 @@
o offer encryption in a more visible way when creating a partition
o remove cryptoloop from diskdrake interface and transparently use dm-crypt
o support having dm-crypt partition with non default FS
+ o do not display dm-crypt partitions in separate tab, display included
+ partition directly in-place
Version 13.19 - 13 April 2010
diff --git a/perl-install/diskdrake/hd_gtk.pm b/perl-install/diskdrake/hd_gtk.pm
index ac0c2f186..099abd1ac 100644
--- a/perl-install/diskdrake/hd_gtk.pm
+++ b/perl-install/diskdrake/hd_gtk.pm
@@ -238,6 +238,9 @@ sub per_entry_info_box {
my $info;
if ($entry) {
$info = diskdrake::interactive::format_part_info(kind2hd($kind), $entry);
+ if($entry->{dmcrypt_name}) {
+ $info .= "\n" . N("Encrypted");
+ }
} elsif ($kind->{type} =~ /hd|lvm/) {
$info = diskdrake::interactive::format_hd_info($kind->{val});
}
@@ -254,10 +257,9 @@ sub current_kind_changed {
my $v = $kind->{val};
my @parts =
$kind->{type} eq 'raid' ? grep { $_ } @$v :
- $kind->{type} eq 'dmcrypt' ? @$v :
$kind->{type} eq 'loopback' ? @$v : fs::get::hds_fstab_and_holes($v);
my $totalsectors =
- $kind->{type} =~ /raid|dmcrypt|loopback/ ? sum(map { $_->{size} } @parts) : $v->{totalsectors};
+ $kind->{type} =~ /raid|loopback/ ? sum(map { $_->{size} } @parts) : $v->{totalsectors};
create_buttons4partitions($kind, $totalsectors, @parts);
}
@@ -284,7 +286,6 @@ sub create_automatic_notebooks {
$may_add->(hd2kind($_)) foreach @{$all_hds->{hds}};
$may_add->(lvm2kind($_)) foreach @{$all_hds->{lvms}};
$may_add->(raid2kind()) if @{$all_hds->{raids}};
- $may_add->(dmcrypt2kind()) if @{$all_hds->{dmcrypts}};
$may_add->(loopback2kind()) if @{$all_hds->{loopbacks}};
@notebook = grep_index {
@@ -343,6 +344,10 @@ sub create_buttons4partitions {
last;
}
});
+ if(fs::type::isRawLUKS($entry)) {
+ my $p = find { $entry->{dm_name} eq $_->{dmcrypt_name} } @{$all_hds->{dmcrypts}};
+ $entry = $p;
+ }
my @colorized_fs_types = qw(ext3 ext4 xfs swap vfat ntfs ntfs-3g);
$w->set_name("PART_" . (isEmpty($entry) ? 'empty' :
$entry->{fs_type} && member($entry->{fs_type}, @colorized_fs_types) ? $entry->{fs_type} :
@@ -440,13 +445,6 @@ sub raid2kind() {
################################################################################
# loopbacks: helpers
################################################################################
-sub dmcrypt2kind() {
- { type => 'dmcrypt', name => 'dmcrypt', val => $all_hds->{dmcrypts} };
-}
-
-################################################################################
-# loopbacks: helpers
-################################################################################
sub loopback2kind() {
{ type => 'loopback', name => 'loopback', val => $all_hds->{loopbacks} };
}