forked from qt-creator/qt-creator
QmlDesigner: Fix crash
The gradient can be an expression. Change-Id: Ib48661f87862f63e5234bbd92ca2117457a0c84c Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
@@ -322,7 +322,7 @@ void GradientModel::setAnchorBackend(const QVariant &anchorBackend)
|
|||||||
m_itemNode = backendCasted->getItemNode();
|
m_itemNode = backendCasted->getItemNode();
|
||||||
|
|
||||||
if (m_itemNode.isValid()
|
if (m_itemNode.isValid()
|
||||||
&& m_itemNode.modelNode().hasProperty(gradientPropertyName().toUtf8()))
|
&& m_itemNode.modelNode().hasNodeProperty(gradientPropertyName().toUtf8()))
|
||||||
m_gradientTypeName = m_itemNode.modelNode().nodeProperty(gradientPropertyName().toUtf8()).modelNode().simplifiedTypeName();
|
m_gradientTypeName = m_itemNode.modelNode().nodeProperty(gradientPropertyName().toUtf8()).modelNode().simplifiedTypeName();
|
||||||
|
|
||||||
setupModel();
|
setupModel();
|
||||||
|
Reference in New Issue
Block a user