[partition] Display partition label and path if set
Setting labels (e.g. in manual partitioning) landed some time ago, but the progress display still shows a raw device path. Make it more expressive. FIXES #449 FIXES #540
This commit is contained in:
parent
c48209a9dd
commit
5bff26e1e0
@ -58,10 +58,13 @@ FormatPartitionJob::prettyDescription() const
|
||||
QString
|
||||
FormatPartitionJob::prettyStatusMessage() const
|
||||
{
|
||||
QString partitionLabel = m_partition->label().isEmpty()
|
||||
? m_partition->partitionPath()
|
||||
: tr( "%1 (%2)", "partition label %1 (device path %2)" )
|
||||
.arg( m_partition->label(), m_partition->partitionPath() );
|
||||
return tr( "Formatting partition %1 with "
|
||||
"file system %2." )
|
||||
.arg( m_partition->partitionPath() )
|
||||
.arg( userVisibleFS( m_partition->fileSystem() ) );
|
||||
.arg( partitionLabel, userVisibleFS( m_partition->fileSystem() ) );
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user