forked from qt-creator/qt-creator
QmlDesigner.itemLibrary: crash fix
This commit is contained in:
@@ -285,6 +285,8 @@ void ItemLibraryWidget::setSearchFilter(const QString &searchFilter)
|
|||||||
void ItemLibraryWidget::setModel(Model *model)
|
void ItemLibraryWidget::setModel(Model *model)
|
||||||
{
|
{
|
||||||
m_d->model = model;
|
m_d->model = model;
|
||||||
|
if (!model)
|
||||||
|
return;
|
||||||
setItemLibraryInfo(model->metaInfo().itemLibraryInfo());
|
setItemLibraryInfo(model->metaInfo().itemLibraryInfo());
|
||||||
updateModel();
|
updateModel();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user