summaryrefslogtreecommitdiffstats
path: root/perl-install/diskdrake/hd_gtk.pm
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/diskdrake/hd_gtk.pm')
-rw-r--r--perl-install/diskdrake/hd_gtk.pm12
1 files changed, 6 insertions, 6 deletions
diff --git a/perl-install/diskdrake/hd_gtk.pm b/perl-install/diskdrake/hd_gtk.pm
index 9de1dde04..d674d1e35 100644
--- a/perl-install/diskdrake/hd_gtk.pm
+++ b/perl-install/diskdrake/hd_gtk.pm
@@ -357,15 +357,15 @@ sub createOrChangeType {
{ pt_type => 0, start => 1, size => $hd->{totalsectors} - 1 };
$part or return;
if ($fs_type eq 'other') {
- $in->ask_warn('', N("Use ``%s'' instead", $part->{pt_type} ? N("Type") : N("Create")));
+ $in->ask_warn('', N("Use ``%s'' instead", isEmpty($part) ? N("Create") : N("Type")));
} elsif (!$fs_type) {
- $in->ask_warn('', N("Use ``%s'' instead", N("Delete"))) if $part->{pt_type};
- } elsif ($part->{pt_type}) {
- return if $fs_type eq $part->{fs_type};
- $in->ask_warn('', isBusy($part) ? N("Use ``Unmount'' first") : N("Use ``%s'' instead", N("Type")));
- } else {
+ $in->ask_warn('', N("Use ``%s'' instead", N("Delete"))) if !isEmpty($part);
+ } elsif (isEmpty($part)) {
fs::type::set_fs_type($part, $fs_type);
diskdrake::interactive::Create($in, $hd, $part, $all_hds);
+ } else {
+ return if $fs_type eq $part->{fs_type};
+ $in->ask_warn('', isBusy($part) ? N("Use ``Unmount'' first") : N("Use ``%s'' instead", N("Type")));
}
}