forked from qt-creator/qt-creator
QmlDesigner: Fix crash
We have to check if the view is actually detached. Change-Id: I160c1a15f921092ef66999ed6a27ffcdbbe205d9 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
This commit is contained in:
@@ -131,8 +131,10 @@ void DynamicPropertiesModel::resetModel()
|
||||
setHorizontalHeaderLabels(
|
||||
QStringList({tr("Item"), tr("Property"), tr("Property Type"), tr("Property Value")}));
|
||||
|
||||
for (const ModelNode modelNode : connectionView()->selectedModelNodes())
|
||||
addModelNode(modelNode);
|
||||
if (connectionView()->isAttached()) {
|
||||
for (const ModelNode modelNode : connectionView()->selectedModelNodes())
|
||||
addModelNode(modelNode);
|
||||
}
|
||||
|
||||
endResetModel();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user