From 38cf58d0cac0de123d8bc699053d66f2062dfc62 Mon Sep 17 00:00:00 2001 From: Mahmoud Badri Date: Tue, 28 Mar 2023 11:54:12 +0300 Subject: [PATCH] QmlDesigner: Emit changed signal after updating m_matBundleExists Fixes: QDS-9516 Change-Id: I905aff3a526d913d3eb56ae556cbebd7d7e67c5b Reviewed-by: Miikka Heikkinen --- .../contentlibrary/contentlibrarymaterialsmodel.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/plugins/qmldesigner/components/contentlibrary/contentlibrarymaterialsmodel.cpp b/src/plugins/qmldesigner/components/contentlibrary/contentlibrarymaterialsmodel.cpp index 937152603a6..c2883ce5d3b 100644 --- a/src/plugins/qmldesigner/components/contentlibrary/contentlibrarymaterialsmodel.cpp +++ b/src/plugins/qmldesigner/components/contentlibrary/contentlibrarymaterialsmodel.cpp @@ -249,8 +249,6 @@ void ContentLibraryMaterialsModel::loadMaterialBundle(const QDir &matBundleDir) } } - m_matBundleExists = true; - QString bundleId = m_matBundleObj.value("id").toString(); const QJsonObject catsObj = m_matBundleObj.value("categories").toObject(); @@ -304,6 +302,9 @@ void ContentLibraryMaterialsModel::loadMaterialBundle(const QDir &matBundleDir) } else { createImporter(matBundleDir.path(), bundleId, sharedFiles); } + + m_matBundleExists = true; + emit matBundleExistsChanged(); } bool ContentLibraryMaterialsModel::hasRequiredQuick3DImport() const