Use untranslated file system name when importing partition table.

BUG: 364648
This commit is contained in:
Andrius Štikonas 2017-09-14 14:47:39 +01:00
parent f8f74d1698
commit 4b4198c34a
2 changed files with 5 additions and 5 deletions

View File

@ -143,7 +143,7 @@ void EditMountPointDialogWidget::setupOptions(const QStringList& options)
optTmpList.append(o);
}
m_Options = optTmpList.join(QStringLiteral(","));
m_Options = optTmpList.join(QLatin1Char(','));
}
void EditMountPointDialogWidget::buttonSelectClicked(bool)
@ -155,7 +155,7 @@ void EditMountPointDialogWidget::buttonSelectClicked(bool)
void EditMountPointDialogWidget::buttonMoreClicked(bool)
{
QPointer<EditMountOptionsDialog> dlg = new EditMountOptionsDialog(this, m_Options.split(QStringLiteral(",")));
QPointer<EditMountOptionsDialog> dlg = new EditMountOptionsDialog(this, m_Options.split(QLatin1Char(',')));
if (dlg->exec() == QDialog::Accepted)
setupOptions(dlg->options());
@ -165,7 +165,7 @@ void EditMountPointDialogWidget::buttonMoreClicked(bool)
QStringList EditMountPointDialogWidget::options() const
{
QStringList optList = m_Options.split(QStringLiteral(","), QString::SkipEmptyParts);
QStringList optList = m_Options.split(QLatin1Char(','), QString::SkipEmptyParts);
const auto keys = boxOptions();
for (const auto &s : keys)

View File

@ -1002,7 +1002,7 @@ void MainWindow::onImportPartitionTable()
qint32 num = rePartition.captured(1).toInt();
qint64 firstSector = rePartition.captured(2).toLongLong();
qint64 lastSector = rePartition.captured(3).toLongLong();
QString fsName = rePartition.captured(4);
QLatin1String fsName = QLatin1String(rePartition.captured(4).toLatin1());
QString roleNames = rePartition.captured(5);
QString volumeLabel = rePartition.captured(6).replace(QStringLiteral("\""), QString());
QStringList flags = rePartition.captured(7).replace(QStringLiteral("\""), QString()).split(QStringLiteral(","));
@ -1046,7 +1046,7 @@ void MainWindow::onImportPartitionTable()
return;
}
FileSystem* fs = FileSystemFactory::create(FileSystem::typeForName(fsName), firstSector, lastSector, device.logicalSize());
FileSystem* fs = FileSystemFactory::create(FileSystem::typeForUntranslatedName(fsName), firstSector, lastSector, device.logicalSize());
if (fs == nullptr) {
KMessageBox::error(this, xi18nc("@info the partition is NOT a device path, just a number", "Could not create file system \"%1\" for partition %2 (line %3).", fsName, num, lineNo), xi18nc("@title:window", "Error While Importing Partition Table"));