diff options
author | Bjørn Erik Nilsen <bjorn.nilsen@nokia.com> | 2009-08-19 08:39:40 (GMT) |
---|---|---|
committer | Bjørn Erik Nilsen <bjorn.nilsen@nokia.com> | 2009-08-19 08:39:40 (GMT) |
commit | 928f902015a0ad97279ce6e2ac4cb85e5baed684 (patch) | |
tree | c3afd6f5b72b32136ab9d40788e1cf05d7b91763 /src/gui/graphicsview/qgraphicswidget.cpp | |
parent | 17d6f2a59fe2b170087cdf7074807c6a2dce1043 (diff) | |
parent | 5fb5c01bd0ac234eaca890d97053c7b0772861a3 (diff) | |
download | Qt-928f902015a0ad97279ce6e2ac4cb85e5baed684.zip Qt-928f902015a0ad97279ce6e2ac4cb85e5baed684.tar.gz Qt-928f902015a0ad97279ce6e2ac4cb85e5baed684.tar.bz2 |
Merge commit 'qt/master' into kinetic-graphicseffect
Conflicts:
src/gui/graphicsview/qgraphicsitem_p.h
Diffstat (limited to 'src/gui/graphicsview/qgraphicswidget.cpp')
-rw-r--r-- | src/gui/graphicsview/qgraphicswidget.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/graphicsview/qgraphicswidget.cpp b/src/gui/graphicsview/qgraphicswidget.cpp index 64881b5..a833d4b 100644 --- a/src/gui/graphicsview/qgraphicswidget.cpp +++ b/src/gui/graphicsview/qgraphicswidget.cpp @@ -74,7 +74,6 @@ QT_BEGIN_NAMESPACE \brief The QGraphicsWidget class is the base class for all widget items in a QGraphicsScene. \since 4.4 - \ingroup multimedia \ingroup graphicsview-api QGraphicsWidget is an extended base item that provides extra functionality @@ -258,7 +257,7 @@ QGraphicsWidget::~QGraphicsWidget() //we check if we have a layout previously if (d->layout) { - delete d->layout; + QGraphicsLayout *temp = d->layout; foreach (QGraphicsItem * item, childItems()) { // In case of a custom layout which doesn't remove and delete items, we ensure that // the parent layout item does not point to the deleted layout. This code is here to @@ -269,6 +268,8 @@ QGraphicsWidget::~QGraphicsWidget() widget->setParentLayoutItem(0); } } + d->layout = 0; + delete temp; } // Remove this graphics widget from widgetStyles |