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>
This commit is contained in:
parent
1b5848957b
commit
585758389c
@ -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);
|
||||
}
|
||||
return itemList;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user