mirror of
https://github.com/YACReader/yacreader
synced 2026-04-12 15:49:53 -04:00
Use target app and version in themes meta
This commit is contained in:
@ -264,10 +264,13 @@ void AppearanceTabWidget::importTheme()
|
||||
if (path.isEmpty() || !repository)
|
||||
return;
|
||||
|
||||
const QString id = repository->importThemeFromFile(path);
|
||||
QString errorMessage;
|
||||
const QString id = repository->importThemeFromFile(path, &errorMessage);
|
||||
if (id.isEmpty()) {
|
||||
QMessageBox::warning(this, tr("Import failed"),
|
||||
tr("Could not import theme from:\n%1").arg(path));
|
||||
const QString detail = errorMessage.isEmpty()
|
||||
? tr("Could not import theme from:\n%1").arg(path)
|
||||
: tr("Could not import theme from:\n%1\n\n%2").arg(path, errorMessage);
|
||||
QMessageBox::warning(this, tr("Import failed"), detail);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user