Trim /dev/ from visible partition paths.
This commit is contained in:
parent
18755314fd
commit
3732f3e5b2
@ -189,7 +189,11 @@ PartitionLabelsView::buildTexts( const QModelIndex& index ) const
|
||||
firstLine = tr( "New partition for %1" ).arg( mountPoint );
|
||||
}
|
||||
else if ( index.data( PartitionModel::OsproberNameRole ).toString().isEmpty() )
|
||||
{
|
||||
firstLine = index.data().toString();
|
||||
if ( firstLine.startsWith( "/dev/sd" ) )
|
||||
firstLine.remove( 0, 5 ); // "/dev/"
|
||||
}
|
||||
else
|
||||
firstLine = index.data( PartitionModel::OsproberNameRole ).toString();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user