diff options
Diffstat (limited to 'src/declarative/qml/qdeclarativeimport.cpp')
-rw-r--r-- | src/declarative/qml/qdeclarativeimport.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/declarative/qml/qdeclarativeimport.cpp b/src/declarative/qml/qdeclarativeimport.cpp index 44fc849..734d63e 100644 --- a/src/declarative/qml/qdeclarativeimport.cpp +++ b/src/declarative/qml/qdeclarativeimport.cpp @@ -361,8 +361,11 @@ bool QDeclarativeImportsPrivate::importExtension(const QString &absoluteFilePath Q_ASSERT(typeLoader); const QDeclarativeDirParser *qmldirParser = typeLoader->qmlDirParser(absoluteFilePath); if (qmldirParser->hasError()) { - if (errorString) - *errorString = QDeclarativeImportDatabase::tr("module \"%1\" definition \"%2\" not readable").arg(uri).arg(absoluteFilePath); + if (errorString) { + const QList<QDeclarativeError> qmldirErrors = qmldirParser->errors(uri); + for (int i = 0; i < qmldirErrors.size(); ++i) + *errorString += qmldirErrors.at(i).description(); + } return false; } @@ -1022,7 +1025,7 @@ bool QDeclarativeImportDatabase::importPlugin(const QString &filePath, const QSt if (!engineInitialized || !typesRegistered) { if (!QDeclarative_isFileCaseCorrect(absoluteFilePath)) { if (errorString) - *errorString = tr("File name case mismatch for \"%2\"").arg(absoluteFilePath); + *errorString = tr("File name case mismatch for \"%1\"").arg(absoluteFilePath); return false; } QPluginLoader loader(absoluteFilePath); |