diff options
author | Tobias Hunger <tobias.hunger@digia.com> | 2013-08-29 11:40:48 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-09-02 13:07:21 +0200 |
commit | 585758389c64e556ef4808308dee27e19241581e (patch) | |
tree | f1e68e5bbafcb3d7008519f5ad64ddda83ee7414 /src/widgets/graphicsview | |
parent | 1b5848957b2a1798af6fc2027a08387fc6732029 (diff) |
Graphicsview: Simplify code
order is either Ascending or Descending (0 or 1), so this comparison is
unnecessary.
Change-Id: Ieceacf18f1bf3c7a7555205a140b738daa92bd04
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Diffstat (limited to 'src/widgets/graphicsview')
-rw-r--r-- | src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp b/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp index f70e66f685..7598163f2d 100644 --- a/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp +++ b/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp @@ -567,10 +567,7 @@ QList<QGraphicsItem *> QGraphicsSceneBspTreeIndex::items(Qt::SortOrder order) co itemList << item; } } - if (order != -1) { - //We sort descending order - d->sortItems(&itemList, order, d->sortCacheEnabled); - } + d->sortItems(&itemList, order, d->sortCacheEnabled); return itemList; } |