QmlDesigner: Compile fix after source-incompatible changes in Qt

The use of 'auto' here is the simplest way out and should not be
taked a precedence for other code.

Change-Id: I4435e7211139bccfca4b10ed2407ba39afe0b400
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
(cherry picked from commit b852886763)
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
hjk
2022-09-21 14:44:23 +02:00
committed by Eike Ziller
parent fec59c21df
commit 9ac27ad8aa

View File

@@ -133,7 +133,7 @@ void MaterialBrowserBundleModel::loadMaterialBundle()
QStringList files;
const QJsonArray assetsArr = matObj.value("files").toArray();
for (const QJsonValueRef &asset : assetsArr)
for (const auto /*QJson{Const,}ValueRef*/ &asset : assetsArr)
files.append(asset.toString());
auto bundleMat = new BundleMaterial(category, mat, matObj.value("qml").toString(),
@@ -146,7 +146,7 @@ void MaterialBrowserBundleModel::loadMaterialBundle()
QStringList sharedFiles;
const QJsonArray sharedFilesArr = m_matBundleObj.value("sharedFiles").toArray();
for (const QJsonValueRef &file : sharedFilesArr)
for (const auto /*QJson{Const,}ValueRef*/ &file : sharedFilesArr)
sharedFiles.append(file.toString());
m_importer = new Internal::BundleImporter(matBundleDir.path(), "MaterialBundle", sharedFiles);