forked from qt-creator/qt-creator
QmlDesigner: Fix crash on shutdown
Change-Id: I95c37a33d7ad346b9d5d031bbfe022527c70e253 Reviewed-by: Henning Gründl <henning.gruendl@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
@@ -89,6 +89,7 @@ void TimelineView::modelAttached(Model *model)
|
|||||||
|
|
||||||
void TimelineView::modelAboutToBeDetached(Model *model)
|
void TimelineView::modelAboutToBeDetached(Model *model)
|
||||||
{
|
{
|
||||||
|
if (!m_timelineWidget)
|
||||||
m_timelineWidget->reset();
|
m_timelineWidget->reset();
|
||||||
const bool empty = getTimelines().isEmpty();
|
const bool empty = getTimelines().isEmpty();
|
||||||
if (!empty)
|
if (!empty)
|
||||||
|
@@ -100,7 +100,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
TimelineWidget *createWidget();
|
TimelineWidget *createWidget();
|
||||||
TimelineWidget *m_timelineWidget = nullptr;
|
QPointer<TimelineWidget> m_timelineWidget;
|
||||||
bool hasQtQuickTimelineImport();
|
bool hasQtQuickTimelineImport();
|
||||||
void ensureQtQuickTimelineImport();
|
void ensureQtQuickTimelineImport();
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user