QmlDesigner: Reset quick3D importer between each file

Quick3D importer caches various things when it does the import, making
reusing the instance for multiple imports error prone.

Change-Id: I6e8e3dedf579683cdda58624172395a392f4e567
Fixes: QDS-1960
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
Miikka Heikkinen
2020-04-21 16:45:48 +03:00
parent 0cac09e757
commit d39f89d13b

View File

@@ -315,6 +315,9 @@ void ItemLibraryAssetImporter::parseQuick3DAsset(const QString &file, const QVar
return;
}
// The importer is reset after every import to avoid issues with it caching various things
m_quick3DAssetImporter.reset(new QSSGAssetImportManager);
if (originalAssetName != assetName) {
// Fix the generated qml file name
const QString assetQml = originalAssetName + ".qml";