Suppress memory allocation due to temporary container
Change-Id: I337c3f7ed63444ac0950a30298eb619f462b7a16 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
This commit is contained in:
parent
588338b65b
commit
d55b685d23
@ -2239,7 +2239,7 @@ bool QGraphicsAnchorLayoutPrivate::calculateTrunk(Orientation orientation, const
|
|||||||
Q_ASSERT(path.positives.count() == 1);
|
Q_ASSERT(path.positives.count() == 1);
|
||||||
Q_ASSERT(path.negatives.count() == 0);
|
Q_ASSERT(path.negatives.count() == 0);
|
||||||
|
|
||||||
AnchorData *ad = path.positives.toList()[0];
|
AnchorData *ad = *path.positives.cbegin();
|
||||||
ad->sizeAtMinimum = ad->minSize;
|
ad->sizeAtMinimum = ad->minSize;
|
||||||
ad->sizeAtPreferred = ad->prefSize;
|
ad->sizeAtPreferred = ad->prefSize;
|
||||||
ad->sizeAtMaximum = ad->maxSize;
|
ad->sizeAtMaximum = ad->maxSize;
|
||||||
|
Loading…
Reference in New Issue
Block a user