From 604dfa57efbf39a3edee7a205fb6692c01e5b50a Mon Sep 17 00:00:00 2001 From: Sami Shalayel Date: Tue, 20 Aug 2024 17:36:13 +0200 Subject: [PATCH] Reset qml code model after build Reset the code model after a build, so it can re-scan the build folder for changed .qmltypes files. This fixes the issue of the QtC embedded code model not recognizing modules and .qmltypes files after a build on qmake projects. Fixes: QTCREATORBUG-24428 Change-Id: I1e584addd2fe9b0918a8fd9b372b4fa23b72f36b Reviewed-by: Fabian Kosmale Reviewed-by: Semih Yavuz Reviewed-by: Christian Kandeler --- src/plugins/qmakeprojectmanager/qmakeproject.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/plugins/qmakeprojectmanager/qmakeproject.cpp b/src/plugins/qmakeprojectmanager/qmakeproject.cpp index c118ba1920e..53e80f482b2 100644 --- a/src/plugins/qmakeprojectmanager/qmakeproject.cpp +++ b/src/plugins/qmakeprojectmanager/qmakeproject.cpp @@ -745,8 +745,10 @@ void QmakeBuildSystem::asyncUpdate() void QmakeBuildSystem::buildFinished(bool success) { - if (success) + if (success) { m_invalidateQmakeVfsContents = true; + updateQmlJSCodeModel(); + } } Tasks QmakeProject::projectIssues(const Kit *k) const