Make QGraphicsItemAnimationPrivate::Pair a (C++98) POD
There's no value in the ctor and it might be inhibiting some C++98 POD-only compiler optimizations. Change-Id: I6887afcd2af9805251eac2d8dfe4ced5b54bff85 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This commit is contained in:
parent
26281561fe
commit
1a1ca59e2d
@ -116,7 +116,6 @@ public:
|
||||
qreal step;
|
||||
|
||||
struct Pair {
|
||||
Pair(qreal a, qreal b) : step(a), value(b) {}
|
||||
bool operator <(const Pair &other) const
|
||||
{ return step < other.step; }
|
||||
bool operator==(const Pair &other) const
|
||||
@ -174,7 +173,7 @@ void QGraphicsItemAnimationPrivate::insertUniquePair(qreal step, qreal value, QV
|
||||
if (!check_step_valid(step, method))
|
||||
return;
|
||||
|
||||
Pair pair(step, value);
|
||||
const Pair pair = { step, value };
|
||||
|
||||
const QVector<Pair>::iterator result = std::lower_bound(binList->begin(), binList->end(), pair);
|
||||
if ((result != binList->end()) && !(pair < *result))
|
||||
|
Loading…
Reference in New Issue
Block a user