forked from qt-creator/qt-creator
QmlDesigner: Fix crash
The buildsystem might be missing. Change-Id: I05e03f59a2fcb49ce1ff7a2521ed1af165730b51 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
committed by
Tim Jenssen
parent
c940cc5466
commit
bcd74a2fad
@@ -64,6 +64,10 @@ static Utils::FilePath getMainUiFile()
|
|||||||
|
|
||||||
auto qmlBuildSystem = qobject_cast<QmlProjectManager::QmlBuildSystem *>(
|
auto qmlBuildSystem = qobject_cast<QmlProjectManager::QmlBuildSystem *>(
|
||||||
project->activeTarget()->buildSystem());
|
project->activeTarget()->buildSystem());
|
||||||
|
|
||||||
|
if (!qmlBuildSystem)
|
||||||
|
return {};
|
||||||
|
|
||||||
return qmlBuildSystem->mainUiFilePath();
|
return qmlBuildSystem->mainUiFilePath();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user