QmlDesigner: Do not open another QML file in fake project mode

If a fake project is is opened the user has already opened
the "correct" .ui.qml file. We do not have to open another one.

Change-Id: Ib7e838118a9162cdc7b7aba05c51a9271503a103
Reviewed-by: Burak Hancerli <burak.hancerli@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
Thomas Hartmann
2024-09-05 16:13:03 +02:00
parent 269694eb10
commit cce0bf2a65

View File

@@ -380,6 +380,9 @@ Utils::FilePath QmlBuildSystem::getStartupQmlFileWithFallback() const
if (!target())
return {};
if (projectFilePath().endsWith(Constants::fakeProjectName))
return {};
const auto getFirstFittingFile = [](const Utils::FilePaths &files) -> Utils::FilePath {
for (const auto &file : files) {
if (file.exists())