summaryrefslogtreecommitdiffstats
path: root/src/gui/graphicsview/qgraphicslinearlayout.cpp
diff options
context:
space:
mode:
authorJan-Arve Sæther <jan-arve.saether@nokia.com>2010-06-16 08:05:44 (GMT)
committerJan-Arve Sæther <jan-arve.saether@nokia.com>2010-06-16 08:50:23 (GMT)
commit183abff6ffcb020b8f0c4041cc82bba0d3b03863 (patch)
tree7492fe295fdc966b72ba27f3c68ef5d7716e2801 /src/gui/graphicsview/qgraphicslinearlayout.cpp
parent17fbbdd3a081a66e1d2b26db7935111c49cea75e (diff)
downloadQt-183abff6ffcb020b8f0c4041cc82bba0d3b03863.zip
Qt-183abff6ffcb020b8f0c4041cc82bba0d3b03863.tar.gz
Qt-183abff6ffcb020b8f0c4041cc82bba0d3b03863.tar.bz2
Fixed problem with wrong size hints when items were removed.
The reason was that the row/column count was not updated after an item was removed. (Note that qgraphicslinearlayout already did this, so we just follow the same pattern, except that the code for QGraphicsGridLayout is a bit more complex... Task-number: QTBUG-10314 Reviewed-by: Alexis Menard
Diffstat (limited to 'src/gui/graphicsview/qgraphicslinearlayout.cpp')
-rw-r--r--src/gui/graphicsview/qgraphicslinearlayout.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/graphicsview/qgraphicslinearlayout.cpp b/src/gui/graphicsview/qgraphicslinearlayout.cpp
index 9722683..b828722 100644
--- a/src/gui/graphicsview/qgraphicslinearlayout.cpp
+++ b/src/gui/graphicsview/qgraphicslinearlayout.cpp
@@ -147,7 +147,7 @@ void QGraphicsLinearLayoutPrivate::removeGridItem(QGridLayoutItem *gridItem)
{
int index = gridItem->firstRow(orientation);
engine.removeItem(gridItem);
- engine.removeRow(index, orientation);
+ engine.removeRows(index, 1, orientation);
}
void QGraphicsLinearLayoutPrivate::fixIndex(int *index) const