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>
This commit is contained in:
parent
c3bd4d08b0
commit
ff2dbe609e
@ -379,6 +379,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;
|
||||
}
|
||||
|
@ -2502,9 +2502,6 @@ void tst_QGraphicsProxyWidget::popup_basic()
|
||||
|
||||
void tst_QGraphicsProxyWidget::popup_subwidget()
|
||||
{
|
||||
#ifdef Q_OS_WIN
|
||||
QSKIP("This test crashes on Windows, QTBUG-33213");
|
||||
#endif
|
||||
QGroupBox *groupBox = new QGroupBox;
|
||||
groupBox->setTitle("GroupBox");
|
||||
groupBox->setCheckable(true);
|
||||
@ -3183,10 +3180,6 @@ void tst_QGraphicsProxyWidget::actionsContextMenu()
|
||||
|
||||
void tst_QGraphicsProxyWidget::deleteProxyForChildWidget()
|
||||
{
|
||||
#if defined(Q_OS_WIN)
|
||||
QSKIP("This test is crashing on windows, it needs to be fixed. QTBUG-29684");
|
||||
#endif
|
||||
|
||||
QDialog dialog;
|
||||
dialog.resize(320, 120);
|
||||
dialog.move(80, 40);
|
||||
|
Loading…
Reference in New Issue
Block a user