forked from qt-creator/qt-creator
QmlDesigner: Fix crash on exit
Change-Id: I26f3c1154d8cdef9cf76b6f608634067b099ea0e Reviewed-by: Marco Bubke <marco.bubke@qt.io> Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
This commit is contained in:
@@ -740,7 +740,8 @@ void MaterialEditorView::modelAboutToBeDetached(Model *model)
|
||||
{
|
||||
AbstractView::modelAboutToBeDetached(model);
|
||||
m_dynamicPropertiesModel->reset();
|
||||
m_qmlBackEnd->materialEditorTransaction()->end();
|
||||
if (auto transaction = m_qmlBackEnd->materialEditorTransaction())
|
||||
transaction->end();
|
||||
m_qmlBackEnd->contextObject()->setHasMaterialLibrary(false);
|
||||
m_selectedMaterial = {};
|
||||
}
|
||||
|
Reference in New Issue
Block a user