diff options
author | Friedemann Kleint <Friedemann.Kleint@digia.com> | 2014-04-14 15:02:42 (GMT) |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-04-15 07:06:08 (GMT) |
commit | 01fd1edbb074b26a054bb545ffed979100f6be12 (patch) | |
tree | 08dfdacf593ff9fef4c6f41107f333298947e991 /src/gui/graphicsview | |
parent | 68a911862e05400ced87971c43fb27fb5d5d8ebd (diff) | |
download | Qt-01fd1edbb074b26a054bb545ffed979100f6be12.zip Qt-01fd1edbb074b26a054bb545ffed979100f6be12.tar.gz Qt-01fd1edbb074b26a054bb545ffed979100f6be12.tar.bz2 |
Fix crash when deleting top level windows embedded into QGraphicsProxyWidget.
Clear proxyWidget pointer in slot
QGraphicsProxyWidgetPrivate::_q_removeWidgetSlot().
Task-number: QTBUG-29684
Task-number: QTBUG-33213
Change-Id: Ibdbd52aa810ca908e3d98daa00954345e7a93a48
Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
(cherry picked from qtbase/ff2dbe609ef4482d66d1ecd135b4f53f6aff7e60)
Diffstat (limited to 'src/gui/graphicsview')
-rw-r--r-- | src/gui/graphicsview/qgraphicsproxywidget.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gui/graphicsview/qgraphicsproxywidget.cpp b/src/gui/graphicsview/qgraphicsproxywidget.cpp index e9bbf04..b3ea09c 100644 --- a/src/gui/graphicsview/qgraphicsproxywidget.cpp +++ b/src/gui/graphicsview/qgraphicsproxywidget.cpp @@ -412,6 +412,10 @@ QWidget *QGraphicsProxyWidgetPrivate::findFocusChild(QWidget *child, bool next) void QGraphicsProxyWidgetPrivate::_q_removeWidgetSlot() { Q_Q(QGraphicsProxyWidget); + if (!widget.isNull()) { + if (QWExtra *extra = widget->d_func()->extra) + extra->proxyWidget = 0; + } widget = 0; delete q; } |