fix Warning

This commit is contained in:
berrux-dev committed 2026-10-03 09:20:13 +02:00
1 parent 593c221d23
commit 8345470273
316 files changed
+1246 -929

No files matched your search

@@ -6,6 +6,7 @@
*/
#include "icons.h"
#include <utility>
#include "polygons.h"
#include <AreaEffectSimulation/aes.hpp>
@@ -54,7 +55,7 @@ static QPixmap pixmapFromPolygons(const QVector<PolygonData> &datas,
for (const PolygonData &data : datas)
{
polyUtm.clear();
for (const QPointF &point : qAsConst(data.poly))
for (const QPointF &point : std::as_const(data.poly))
{
LtsCoordTrans::UtmCoordinate pointUtm = LtsCoordTrans::UtmCoordinate::fromGeographic(point, zone);
polyUtm << QPointF(pointUtm.x, pointUtm.y);
@@ -66,7 +67,7 @@ static QPixmap pixmapFromPolygons(const QVector<PolygonData> &datas,
bounding.reserve(4 * datas.size());
// Does not matter, how the total polygon looks as we just need the bounding rect.
// << is cheaper than .united()
for (const QPolygonF &polyUtmLocal : qAsConst(polysUtm))
for (const QPolygonF &polyUtmLocal : std::as_const(polysUtm))
bounding << polyUtmLocal;
// center to center / Todo:: Does it always work?
@@ -89,7 +90,7 @@ static QPixmap pixmapFromPolygons(const QVector<PolygonData> &datas,
QPainter p(&pix);
int i = 0;
for (const PolygonData &d : qAsConst(datas))
for (const PolygonData &d : std::as_const(datas))
{
QPolygonF mPoly = mTrans.map(polysUtm.at(i++));
mPoly = mScale.map(mPoly);