Editors: Fix message box when opening broken code style file

The file name is not supposed to be the button label.

Fixes: QTCREATORBUG-28746
Change-Id: I45ee2a860da8f7ffefc6d72c0d85b7f6a261489c
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
Eike Ziller
2023-02-06 15:46:56 +01:00
parent 3358f94cb7
commit 5728f09fac

View File

@@ -209,8 +209,9 @@ void CodeStyleSelectorWidget::slotImportClicked()
if (importedStyle)
m_codeStyle->setCurrentDelegate(importedStyle);
else
QMessageBox::warning(this, tr("Import Code Style"),
tr("Cannot import code style from %1"), fileName.toUserOutput());
QMessageBox::warning(this,
tr("Import Code Style"),
tr("Cannot import code style from %1").arg(fileName.toUserOutput()));
}
}