mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-13 00:03:09 -04:00
Misc optimisations identified by clazy:
- call reserve on container classes where applicable - make sure Q_FOREACH uses references - remove dynamic casts to base classes - fix some implicit bool conversions
This commit is contained in:
parent
890dce86aa
commit
0caf944747
@ -532,7 +532,7 @@ class QgsGeometry
|
||||
public:
|
||||
Error();
|
||||
Error( QString m );
|
||||
Error( QString m, QgsPoint p );
|
||||
Error( QString m, const QgsPoint& p );
|
||||
|
||||
QString what();
|
||||
QgsPoint where();
|
||||
|
@ -47,10 +47,10 @@ class QgsLegendSettings
|
||||
int columnCount() const;
|
||||
void setColumnCount( int c );
|
||||
|
||||
int splitLayer() const;
|
||||
bool splitLayer() const;
|
||||
void setSplitLayer( bool s );
|
||||
|
||||
int equalColumnWidth() const;
|
||||
bool equalColumnWidth() const;
|
||||
void setEqualColumnWidth( bool s );
|
||||
|
||||
QColor fontColor() const;
|
||||
|
@ -190,7 +190,7 @@ class QgsVectorLayer : QgsMapLayer
|
||||
struct RangeData
|
||||
{
|
||||
RangeData();
|
||||
RangeData( QVariant theMin, QVariant theMax, QVariant theStep );
|
||||
RangeData( const QVariant& theMin, const QVariant& theMax, const QVariant& theStep );
|
||||
|
||||
QVariant mMin;
|
||||
QVariant mMax;
|
||||
|
@ -43,7 +43,8 @@ class QgsHeatmapRenderer : QgsFeatureRendererV2
|
||||
* @see setInvertRamp
|
||||
* @see colorRamp
|
||||
*/
|
||||
double invertRamp() const;
|
||||
bool invertRamp() const;
|
||||
|
||||
/** Sets whether the ramp is inverted
|
||||
* @param invert set to true to invert color ramp
|
||||
* @see invertRamp
|
||||
|
@ -274,7 +274,7 @@ class QgsFeatureRendererV2
|
||||
bool drawVertexMarker );
|
||||
|
||||
//! render editing vertex marker at specified point
|
||||
void renderVertexMarker( QPointF& pt, QgsRenderContext& context );
|
||||
void renderVertexMarker( const QPointF& pt, QgsRenderContext& context );
|
||||
//! render editing vertex marker for a polyline
|
||||
void renderVertexMarkerPolyline( QPolygonF& pts, QgsRenderContext& context );
|
||||
//! render editing vertex marker for a polygon
|
||||
|
@ -169,7 +169,7 @@ class QgsSymbolLayerV2Utils
|
||||
|
||||
|
||||
static void labelTextToSld( QDomDocument &doc, QDomElement &element, QString label,
|
||||
QFont font, QColor color = QColor(), double size = -1 );
|
||||
const QFont& font, QColor color = QColor(), double size = -1 );
|
||||
|
||||
/** Create ogr feature style string for pen */
|
||||
static QString ogrFeatureStylePen( double width, double mmScaleFactor, double mapUnitsScaleFactor, const QColor& c,
|
||||
|
@ -156,7 +156,7 @@ class QgsSymbolV2
|
||||
* @note added in QGIS 2.9
|
||||
* @see setClipFeaturesToExtent
|
||||
*/
|
||||
double clipFeaturesToExtent() const;
|
||||
bool clipFeaturesToExtent() const;
|
||||
|
||||
QSet<QString> usedAttributes() const;
|
||||
|
||||
|
@ -674,6 +674,7 @@ QList< QgsRelief::ReliefColor > QgsRelief::calculateOptimizedReliefClasses()
|
||||
colorList.push_back( QColor( 255, 133, 92 ) );
|
||||
colorList.push_back( QColor( 204, 204, 204 ) );
|
||||
|
||||
resultList.reserve( classBreaks.size() );
|
||||
for ( int i = 1; i < classBreaks.size(); ++i )
|
||||
{
|
||||
double minElevation = minMax[0] + classBreaks[i - 1] * frequencyClassRange;
|
||||
|
@ -614,6 +614,7 @@ QgsGeometry* QgsTransectSample::clipBufferLine( const QgsGeometry* stratumGeom,
|
||||
}
|
||||
|
||||
int size = bufferPolygon.size();
|
||||
mpl.reserve( size );
|
||||
for ( int j = 0; j < size; ++j )
|
||||
{
|
||||
mpl.append( bufferPolygon[j] );
|
||||
|
@ -329,7 +329,7 @@ void QgsAttributeTableDialog::columnBoxInit()
|
||||
|
||||
QList<QgsField> fields = mLayer->fields().toList();
|
||||
|
||||
Q_FOREACH ( const QgsField field, fields )
|
||||
Q_FOREACH ( const QgsField& field, fields )
|
||||
{
|
||||
int idx = mLayer->fieldNameIndex( field.name() );
|
||||
if ( idx < 0 )
|
||||
|
@ -75,6 +75,7 @@ void QgsConfigureShortcutsDialog::populateActions()
|
||||
QList<QAction*> actions = QgsShortcutsManager::instance()->listActions();
|
||||
|
||||
QList<QTreeWidgetItem *> items;
|
||||
items.reserve( actions.count() );
|
||||
for ( int i = 0; i < actions.count(); ++i )
|
||||
{
|
||||
QString actionText = actions[i]->text();
|
||||
|
@ -683,6 +683,9 @@ void QgsDiagramProperties::apply()
|
||||
QList<QColor> categoryColors;
|
||||
QList<QString> categoryAttributes;
|
||||
QList<QString> categoryLabels;
|
||||
categoryColors.reserve( mDiagramAttributesTreeWidget->topLevelItemCount() );
|
||||
categoryAttributes.reserve( mDiagramAttributesTreeWidget->topLevelItemCount() );
|
||||
categoryLabels.reserve( mDiagramAttributesTreeWidget->topLevelItemCount() );
|
||||
for ( int i = 0; i < mDiagramAttributesTreeWidget->topLevelItemCount(); ++i )
|
||||
{
|
||||
QColor color = mDiagramAttributesTreeWidget->topLevelItem( i )->background( 1 ).color();
|
||||
|
@ -61,6 +61,7 @@ void QgsLabelDialog::init()
|
||||
const QgsFields& myFields = mLabel->fields();
|
||||
QStringList myFieldStringList;
|
||||
myFieldStringList.append( "" );
|
||||
myFieldStringList.reserve( 1 + myFields.count() );
|
||||
for ( int i = 0; i < myFields.count(); ++i )
|
||||
{
|
||||
myFieldStringList.append( myFields[i].name() );
|
||||
|
@ -223,7 +223,7 @@ void QgsMapToolAddFeature::cadCanvasReleaseEvent( QgsMapMouseEvent* e )
|
||||
QgsCurveV2* curveToAdd = 0;
|
||||
if ( hasCurvedSegments && providerSupportsCurvedSegments )
|
||||
{
|
||||
curveToAdd = dynamic_cast<QgsCurveV2*>( captureCurve()->clone() );
|
||||
curveToAdd = captureCurve()->clone();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -134,7 +134,7 @@ void QgsMapToolAddPart::cadCanvasReleaseEvent( QgsMapMouseEvent * e )
|
||||
QgsCurveV2* curveToAdd = 0;
|
||||
if ( hasCurvedSegments && providerSupportsCurvedSegments )
|
||||
{
|
||||
curveToAdd = dynamic_cast<QgsCurveV2*>( captureCurve()->clone() );
|
||||
curveToAdd = captureCurve()->clone();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -92,7 +92,7 @@ void QgsMapToolAddRing::cadCanvasReleaseEvent( QgsMapMouseEvent * e )
|
||||
QgsCurveV2* curveToAdd = 0;
|
||||
if ( hasCurvedSegments && providerSupportsCurvedSegments )
|
||||
{
|
||||
curveToAdd = dynamic_cast<QgsCurveV2*>( captureCurve()->clone() );
|
||||
curveToAdd = captureCurve()->clone();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -449,6 +449,7 @@ QVariant QgsMergeAttributesDialog::sumAttribute( int col )
|
||||
QVariant QgsMergeAttributesDialog::concatenationAttribute( int col )
|
||||
{
|
||||
QStringList concatString;
|
||||
concatString.reserve( mFeatureList.size() );
|
||||
for ( int i = 0; i < mFeatureList.size(); ++i )
|
||||
{
|
||||
concatString << mTableWidget->item( i + 1, col )->text();
|
||||
|
@ -1911,6 +1911,7 @@ void QgsOptions::on_pbnExportScales_clicked()
|
||||
}
|
||||
|
||||
QStringList myScales;
|
||||
myScales.reserve( mListGlobalScales->count() );
|
||||
for ( int i = 0; i < mListGlobalScales->count(); ++i )
|
||||
{
|
||||
myScales.append( mListGlobalScales->item( i )->text() );
|
||||
|
@ -686,6 +686,7 @@ void QgsProjectProperties::apply()
|
||||
|
||||
//save project scales
|
||||
QStringList myScales;
|
||||
myScales.reserve( lstScales->count() );
|
||||
for ( int i = 0; i < lstScales->count(); ++i )
|
||||
{
|
||||
myScales.append( lstScales->item( i )->text() );
|
||||
|
@ -49,7 +49,7 @@ QString QgsAuthCertUtils::getSslProtocolName( QSsl::SslProtocol protocol )
|
||||
QMap<QString, QSslCertificate> QgsAuthCertUtils::mapDigestToCerts( QList<QSslCertificate> certs )
|
||||
{
|
||||
QMap<QString, QSslCertificate> digestmap;
|
||||
Q_FOREACH ( QSslCertificate cert, certs )
|
||||
Q_FOREACH ( const QSslCertificate& cert, certs )
|
||||
{
|
||||
digestmap.insert( shaHexForCert( cert ), cert );
|
||||
}
|
||||
@ -59,7 +59,7 @@ QMap<QString, QSslCertificate> QgsAuthCertUtils::mapDigestToCerts( QList<QSslCer
|
||||
QMap<QString, QList<QSslCertificate> > QgsAuthCertUtils::certsGroupedByOrg( QList<QSslCertificate> certs )
|
||||
{
|
||||
QMap< QString, QList<QSslCertificate> > orgcerts;
|
||||
Q_FOREACH ( QSslCertificate cert, certs )
|
||||
Q_FOREACH ( const QSslCertificate& cert, certs )
|
||||
{
|
||||
QString org( cert.subjectInfo( QSslCertificate::Organization ) );
|
||||
if ( org.isEmpty() )
|
||||
@ -73,7 +73,7 @@ QMap<QString, QList<QSslCertificate> > QgsAuthCertUtils::certsGroupedByOrg( QLis
|
||||
QMap<QString, QgsAuthConfigSslServer> QgsAuthCertUtils::mapDigestToSslConfigs( QList<QgsAuthConfigSslServer> configs )
|
||||
{
|
||||
QMap<QString, QgsAuthConfigSslServer> digestmap;
|
||||
Q_FOREACH ( QgsAuthConfigSslServer config, configs )
|
||||
Q_FOREACH ( const QgsAuthConfigSslServer& config, configs )
|
||||
{
|
||||
digestmap.insert( shaHexForCert( config.sslCertificate() ), config );
|
||||
}
|
||||
@ -83,7 +83,7 @@ QMap<QString, QgsAuthConfigSslServer> QgsAuthCertUtils::mapDigestToSslConfigs( Q
|
||||
QMap<QString, QList<QgsAuthConfigSslServer> > QgsAuthCertUtils::sslConfigsGroupedByOrg( QList<QgsAuthConfigSslServer> configs )
|
||||
{
|
||||
QMap< QString, QList<QgsAuthConfigSslServer> > orgconfigs;
|
||||
Q_FOREACH ( QgsAuthConfigSslServer config, configs )
|
||||
Q_FOREACH ( const QgsAuthConfigSslServer& config, configs )
|
||||
{
|
||||
QString org( config.sslCertificate().subjectInfo( QSslCertificate::Organization ) );
|
||||
if ( org.isEmpty() )
|
||||
@ -371,6 +371,7 @@ QString QgsAuthCertUtils::getColonDelimited( const QString &txt )
|
||||
// 64321c05b0ebab8e2b67ec0d7d9e2b6d4bc3c303
|
||||
// -> 64:32:1c:05:b0:eb:ab:8e:2b:67:ec:0d:7d:9e:2b:6d:4b:c3:c3:03
|
||||
QStringList sl;
|
||||
sl.reserve( txt.size() );
|
||||
for ( int i = 0; i < txt.size(); i += 2 )
|
||||
{
|
||||
sl << txt.mid( i, ( i + 2 > txt.size() ) ? -1 : 2 );
|
||||
@ -593,7 +594,7 @@ QList<QgsAuthCertUtils::CertUsageType> QgsAuthCertUtils::certificateUsageTypes(
|
||||
}
|
||||
|
||||
QList<QCA::ConstraintType> certconsts = qcacert.constraints();
|
||||
Q_FOREACH ( QCA::ConstraintType certconst, certconsts )
|
||||
Q_FOREACH ( const QCA::ConstraintType& certconst, certconsts )
|
||||
{
|
||||
if ( certconst.known() == QCA::KeyCertificateSign )
|
||||
{
|
||||
|
@ -285,7 +285,7 @@ const QgsPkiBundle QgsPkiBundle::fromPkcs12Paths( const QString &bundlepath,
|
||||
if ( cert_chain.size() > 1 )
|
||||
{
|
||||
QList<QSslCertificate> ca_chain;
|
||||
Q_FOREACH ( QCA::Certificate ca_cert, cert_chain )
|
||||
Q_FOREACH ( const QCA::Certificate& ca_cert, cert_chain )
|
||||
{
|
||||
if ( ca_cert != cert_chain.primary() )
|
||||
{
|
||||
|
@ -2328,7 +2328,7 @@ const QList<QSslCertificate> QgsAuthManager::getExtraFileCAs()
|
||||
filecerts = QgsAuthCertUtils::certsFromFile( cafile );
|
||||
}
|
||||
// only CAs or certs capable of signing other certs are allowed
|
||||
Q_FOREACH ( QSslCertificate cert, filecerts )
|
||||
Q_FOREACH ( const QSslCertificate& cert, filecerts )
|
||||
{
|
||||
if ( !allowinvalid.toBool() && !cert.isValid() )
|
||||
{
|
||||
|
@ -235,10 +235,10 @@ QString QgsComposerLegend::wrapChar() const {return mSettings.wrapChar(); }
|
||||
int QgsComposerLegend::columnCount() const { return mSettings.columnCount(); }
|
||||
void QgsComposerLegend::setColumnCount( int c ) { mSettings.setColumnCount( c ); }
|
||||
|
||||
int QgsComposerLegend::splitLayer() const { return mSettings.splitLayer(); }
|
||||
bool QgsComposerLegend::splitLayer() const { return mSettings.splitLayer(); }
|
||||
void QgsComposerLegend::setSplitLayer( bool s ) { mSettings.setSplitLayer( s ); }
|
||||
|
||||
int QgsComposerLegend::equalColumnWidth() const { return mSettings.equalColumnWidth(); }
|
||||
bool QgsComposerLegend::equalColumnWidth() const { return mSettings.equalColumnWidth(); }
|
||||
void QgsComposerLegend::setEqualColumnWidth( bool s ) { mSettings.setEqualColumnWidth( s ); }
|
||||
|
||||
|
||||
|
@ -150,10 +150,10 @@ class CORE_EXPORT QgsComposerLegend : public QgsComposerItem
|
||||
int columnCount() const;
|
||||
void setColumnCount( int c );
|
||||
|
||||
int splitLayer() const;
|
||||
bool splitLayer() const;
|
||||
void setSplitLayer( bool s );
|
||||
|
||||
int equalColumnWidth() const;
|
||||
bool equalColumnWidth() const;
|
||||
void setEqualColumnWidth( bool s );
|
||||
|
||||
void setComposerMap( const QgsComposerMap* map );
|
||||
|
@ -1425,6 +1425,7 @@ bool QgsComposerMap::readXML( const QDomElement& itemElem, const QDomDocument& d
|
||||
{
|
||||
QDomElement layerSetElem = layerSetNodeList.at( 0 ).toElement();
|
||||
QDomNodeList layerIdNodeList = layerSetElem.elementsByTagName( "Layer" );
|
||||
layerSet.reserve( layerIdNodeList.size() );
|
||||
for ( int i = 0; i < layerIdNodeList.size(); ++i )
|
||||
{
|
||||
const QDomElement& layerIdElement = layerIdNodeList.at( i ).toElement();
|
||||
|
@ -4127,7 +4127,7 @@ QString QgsDxfExport::layerName( const QString &id, const QgsFeature &f ) const
|
||||
|
||||
QString QgsDxfExport::dxfEncoding( const QString &name )
|
||||
{
|
||||
Q_FOREACH ( QByteArray codec, QTextCodec::availableCodecs() )
|
||||
Q_FOREACH ( const QByteArray& codec, QTextCodec::availableCodecs() )
|
||||
{
|
||||
if ( name != codec )
|
||||
continue;
|
||||
|
@ -358,7 +358,9 @@ QgsPolygonV2* QgsCurvePolygonV2::surfaceToPolygon() const
|
||||
QgsPolygonV2* polygon = new QgsPolygonV2();
|
||||
polygon->setExteriorRing( exteriorRing()->curveToLine() );
|
||||
QList<QgsCurveV2*> interiors;
|
||||
for ( int i = 0, n = numInteriorRings(); i < n; ++i )
|
||||
int n = numInteriorRings();
|
||||
interiors.reserve( n );
|
||||
for ( int i = 0; i < n; ++i )
|
||||
{
|
||||
interiors.append( interiorRing( i )->curveToLine() );
|
||||
}
|
||||
@ -681,6 +683,7 @@ double QgsCurvePolygonV2::vertexAngle( const QgsVertexId& vertex ) const
|
||||
{
|
||||
if ( !mExteriorRing || vertex.ring < 0 || vertex.ring >= 1 + mInteriorRings.size() )
|
||||
{
|
||||
//makes no sense - conversion of false to double!
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -100,7 +100,7 @@ class CORE_EXPORT QgsCurvePolygonV2: public QgsSurfaceV2
|
||||
|
||||
virtual int vertexCount( int /*part*/ = 0, int ring = 0 ) const override;
|
||||
virtual int ringCount( int /*part*/ = 0 ) const override { return ( mExteriorRing != 0 ) + mInteriorRings.size(); }
|
||||
virtual int partCount() const override { return ringCount() > 0; }
|
||||
virtual int partCount() const override { return ringCount() > 0 ? 1 : 0; }
|
||||
virtual QgsPointV2 vertexAt( const QgsVertexId& id ) const override;
|
||||
|
||||
protected:
|
||||
|
@ -92,8 +92,8 @@ class CORE_EXPORT QgsCurveV2: public QgsAbstractGeometryV2
|
||||
QgsAbstractGeometryV2* segmentize() const override;
|
||||
|
||||
virtual int vertexCount( int /*part*/ = 0, int /*ring*/ = 0 ) const override { return numPoints(); }
|
||||
virtual int ringCount( int /*part*/ = 0 ) const override { return numPoints() > 0; }
|
||||
virtual int partCount() const override { return numPoints() > 0; }
|
||||
virtual int ringCount( int /*part*/ = 0 ) const override { return numPoints() > 0 ? 1 : 0; }
|
||||
virtual int partCount() const override { return numPoints() > 0 ? 1 : 0; }
|
||||
virtual QgsPointV2 vertexAt( const QgsVertexId& id ) const override;
|
||||
};
|
||||
|
||||
|
@ -1415,6 +1415,7 @@ QList<QgsGeometry*> QgsGeometry::asGeometryCollection() const
|
||||
if ( gc )
|
||||
{
|
||||
int numGeom = gc->numGeometries();
|
||||
geometryList.reserve( numGeom );
|
||||
for ( int i = 0; i < numGeom; ++i )
|
||||
{
|
||||
geometryList.append( new QgsGeometry( gc->geometryN( i )->clone() ) );
|
||||
@ -1683,7 +1684,7 @@ int QgsGeometry::vertexNrFromVertexId( const QgsVertexId& id ) const
|
||||
{
|
||||
if ( !d || !d->geometry )
|
||||
{
|
||||
return false;
|
||||
return -1;
|
||||
}
|
||||
|
||||
QList< QList< QList< QgsPointV2 > > > coords;
|
||||
@ -1911,6 +1912,7 @@ QgsPolyline QgsGeometry::smoothLine( const QgsPolyline& polyline, const unsigned
|
||||
for ( unsigned int iteration = 0; iteration < iterations; ++iteration )
|
||||
{
|
||||
QgsPolyline outputLine = QgsPolyline();
|
||||
outputLine.reserve( 2 * ( result.count() - 1 ) );
|
||||
for ( int i = 0; i < result.count() - 1; i++ )
|
||||
{
|
||||
const QgsPoint& p1 = result.at( i );
|
||||
@ -1933,6 +1935,7 @@ QgsPolygon QgsGeometry::smoothPolygon( const QgsPolygon& polygon, const unsigned
|
||||
for ( unsigned int iteration = 0; iteration < iterations; ++iteration )
|
||||
{
|
||||
QgsPolyline outputRing = QgsPolyline();
|
||||
outputRing.reserve( 2 * ( resultRing.count() - 1 ) + 1 );
|
||||
for ( int i = 0; i < resultRing.count() - 1; ++i )
|
||||
{
|
||||
const QgsPoint& p1 = resultRing.at( i );
|
||||
|
@ -575,7 +575,7 @@ class CORE_EXPORT QgsGeometry
|
||||
public:
|
||||
Error() : message( "none" ), hasLocation( false ) {}
|
||||
explicit Error( QString m ) : message( m ), hasLocation( false ) {}
|
||||
Error( QString m, QgsPoint p ) : message( m ), location( p ), hasLocation( true ) {}
|
||||
Error( QString m, const QgsPoint& p ) : message( m ), location( p ), hasLocation( true ) {}
|
||||
|
||||
QString what() { return message; }
|
||||
QgsPoint where() { return location; }
|
||||
|
@ -42,6 +42,7 @@ int QgsGeometryEditUtils::addRing( QgsAbstractGeometryV2* geom, QgsCurveV2* ring
|
||||
}
|
||||
else if ( multiGeom )
|
||||
{
|
||||
polygonList.reserve( multiGeom->numGeometries() );
|
||||
for ( int i = 0; i < multiGeom->numGeometries(); ++i )
|
||||
{
|
||||
polygonList.append( dynamic_cast< QgsCurvePolygonV2* >( multiGeom->geometryN( i ) ) );
|
||||
|
@ -561,6 +561,7 @@ int QgsGeos::splitLinearGeometry( GEOSGeometry* splitLine, QList<QgsAbstractGeom
|
||||
if ( splitType == GEOS_MULTILINESTRING )
|
||||
{
|
||||
int nGeoms = GEOSGetNumGeometries_r( geosinit.ctxt, splitGeom );
|
||||
lineGeoms.reserve( nGeoms );
|
||||
for ( int i = 0; i < nGeoms; ++i )
|
||||
lineGeoms << GEOSGeom_clone_r( geosinit.ctxt, GEOSGetGeometryN_r( geosinit.ctxt, splitGeom, i ) );
|
||||
|
||||
@ -930,6 +931,7 @@ QgsLineStringV2* QgsGeos::sequenceToLinestring( const GEOSGeometry* geos, bool h
|
||||
const GEOSCoordSequence* cs = GEOSGeom_getCoordSeq_r( geosinit.ctxt, geos );
|
||||
unsigned int nPoints;
|
||||
GEOSCoordSeq_getSize_r( geosinit.ctxt, cs, &nPoints );
|
||||
pts.reserve( nPoints );
|
||||
for ( unsigned int i = 0; i < nPoints; ++i )
|
||||
{
|
||||
pts.push_back( coordSeqPoint( cs, i, hasZ, hasM ) );
|
||||
|
@ -107,5 +107,5 @@ unsigned char* QgsPolygonV2::asWkb( int& binarySize ) const
|
||||
|
||||
QgsPolygonV2* QgsPolygonV2::surfaceToPolygon() const
|
||||
{
|
||||
return dynamic_cast<QgsPolygonV2*>( clone() );
|
||||
return clone();
|
||||
}
|
||||
|
@ -970,7 +970,7 @@ namespace pal
|
||||
{
|
||||
ASSERT( a_node );
|
||||
|
||||
int firstTime = true;
|
||||
bool firstTime = true;
|
||||
Rect rect;
|
||||
InitRect( &rect );
|
||||
|
||||
|
@ -88,6 +88,7 @@ bool QgsConditionalLayerStyles::readXml( const QDomNode &node )
|
||||
QDomElement fieldel = nodelist.at( i ).toElement();
|
||||
QString fieldName = fieldel.attribute( "fieldname" );
|
||||
QDomNodeList stylenodelist = fieldel.toElement().elementsByTagName( "style" );
|
||||
styles.reserve( stylenodelist.count() );
|
||||
for ( int i = 0;i < stylenodelist.count(); i++ )
|
||||
{
|
||||
QDomElement styleElm = stylenodelist.at( i ).toElement();
|
||||
|
@ -548,6 +548,7 @@ void QgsLinearlyInterpolatedDiagramRenderer::writeXML( QDomElement& layerElem, Q
|
||||
QList< QgsLayerTreeModelLegendNode* > QgsDiagramSettings::legendItems( QgsLayerTreeLayer* nodeLayer ) const
|
||||
{
|
||||
QList< QgsLayerTreeModelLegendNode * > list;
|
||||
list.reserve( categoryLabels.size() );
|
||||
for ( int i = 0 ; i < categoryLabels.size(); ++i )
|
||||
{
|
||||
QPixmap pix( 16, 16 );
|
||||
|
@ -369,6 +369,7 @@ double QgsDistanceArea::measurePerimeter( const QgsGeometry* geometry ) const
|
||||
const QgsMultiSurfaceV2* multiSurf = dynamic_cast<const QgsMultiSurfaceV2*>( geomV2 );
|
||||
if ( multiSurf )
|
||||
{
|
||||
surfaces.reserve(( surf ? 1 : 0 ) + multiSurf->numGeometries() );
|
||||
for ( int i = 0; i < multiSurf->numGeometries(); ++i )
|
||||
{
|
||||
surfaces.append( static_cast<const QgsSurfaceV2*>( multiSurf->geometryN( i ) ) );
|
||||
@ -376,7 +377,6 @@ double QgsDistanceArea::measurePerimeter( const QgsGeometry* geometry ) const
|
||||
}
|
||||
|
||||
double length = 0;
|
||||
QList<QgsPointV2> pointList;
|
||||
QList<const QgsSurfaceV2*>::const_iterator surfaceIt = surfaces.constBegin();
|
||||
for ( ; surfaceIt != surfaces.constEnd(); ++surfaceIt )
|
||||
{
|
||||
|
@ -83,6 +83,7 @@ QList<double> QgsHistogram::binEdges( int bins ) const
|
||||
double binWidth = ( mMax - mMin ) / bins;
|
||||
|
||||
QList<double> edges;
|
||||
edges.reserve( bins + 1 );
|
||||
edges << mMin;
|
||||
double current = mMin;
|
||||
for ( int i = 0; i < bins; ++i )
|
||||
|
@ -79,6 +79,7 @@ bool QgsLabelSearchTree::insertLabel( LabelPosition* labelPos, int featureId, co
|
||||
labelPos->getBoundingBox( c_min, c_max );
|
||||
|
||||
QVector<QgsPoint> cornerPoints;
|
||||
cornerPoints.reserve( 4 );
|
||||
for ( int i = 0; i < 4; ++i )
|
||||
{
|
||||
cornerPoints.push_back( QgsPoint( labelPos->getX( i ), labelPos->getY( i ) ) );
|
||||
|
@ -70,10 +70,10 @@ class CORE_EXPORT QgsLegendSettings
|
||||
int columnCount() const { return mColumnCount; }
|
||||
void setColumnCount( int c ) { mColumnCount = c;}
|
||||
|
||||
int splitLayer() const { return mSplitLayer; }
|
||||
bool splitLayer() const { return mSplitLayer; }
|
||||
void setSplitLayer( bool s ) { mSplitLayer = s;}
|
||||
|
||||
int equalColumnWidth() const { return mEqualColumnWidth; }
|
||||
bool equalColumnWidth() const { return mEqualColumnWidth; }
|
||||
void setEqualColumnWidth( bool s ) { mEqualColumnWidth = s;}
|
||||
|
||||
QColor fontColor() const {return mFontColor;}
|
||||
|
@ -79,6 +79,7 @@ static QList<int> _makeNodeOrder( QgsLayerTreeLayer* nodeLayer )
|
||||
int numNodes = _originalLegendNodeCount( nodeLayer );
|
||||
|
||||
QList<int> order;
|
||||
order.reserve( numNodes );
|
||||
for ( int i = 0; i < numNodes; ++i )
|
||||
order << i;
|
||||
return order;
|
||||
@ -287,7 +288,7 @@ QList<QgsLayerTreeModelLegendNode*> QgsDefaultPluginLayerLegend::createLayerTree
|
||||
return nodes;
|
||||
|
||||
typedef QPair<QString, QPixmap> XY;
|
||||
Q_FOREACH ( XY item, symbologyList )
|
||||
Q_FOREACH ( const XY& item, symbologyList )
|
||||
{
|
||||
nodes << new QgsSimpleLegendNode( nodeLayer, item.first, QIcon( item.second ) );
|
||||
}
|
||||
|
@ -215,7 +215,7 @@ class CORE_EXPORT QgsPoint
|
||||
//! Assignment
|
||||
QgsPoint & operator=( const QgsPoint &other );
|
||||
|
||||
QgsVector operator-( QgsPoint p ) const { return QgsVector( m_x - p.m_x, m_y - p.m_y ); }
|
||||
QgsVector operator-( const QgsPoint& p ) const { return QgsVector( m_x - p.m_x, m_y - p.m_y ); }
|
||||
QgsPoint &operator+=( const QgsVector &v ) { *this = *this + v; return *this; }
|
||||
QgsPoint &operator-=( const QgsVector &v ) { *this = *this - v; return *this; }
|
||||
QgsPoint operator+( const QgsVector &v ) const { return QgsPoint( m_x + v.x(), m_y + v.y() ); }
|
||||
|
@ -678,7 +678,7 @@ class CORE_EXPORT QgsVectorLayer : public QgsMapLayer
|
||||
struct RangeData
|
||||
{
|
||||
RangeData() { mMin = QVariant( 0 ); mMax = QVariant( 5 ); mStep = QVariant( 1 );}
|
||||
RangeData( QVariant theMin, QVariant theMax, QVariant theStep )
|
||||
RangeData( const QVariant& theMin, const QVariant& theMax, const QVariant& theStep )
|
||||
: mMin( theMin ), mMax( theMax ), mStep( theStep ) {}
|
||||
|
||||
QVariant mMin;
|
||||
|
@ -215,7 +215,7 @@ QgsVectorLayerImport::importLayer( QgsVectorLayer* layer,
|
||||
{
|
||||
const QgsCoordinateReferenceSystem* outputCRS;
|
||||
QgsCoordinateTransform* ct = 0;
|
||||
int shallTransform = false;
|
||||
bool shallTransform = false;
|
||||
|
||||
if ( layer == NULL )
|
||||
{
|
||||
|
@ -335,6 +335,7 @@ QgsRasterFileWriter::WriterError QgsRasterFileWriter::writeDataRaster(
|
||||
int iterRows = 0;
|
||||
|
||||
QList<QgsRasterBlock*> blockList;
|
||||
blockList.reserve( nBands );
|
||||
for ( int i = 1; i <= nBands; ++i )
|
||||
{
|
||||
iter->startRasterRead( i, nCols, nRows, outputExtent );
|
||||
|
@ -1438,6 +1438,7 @@ bool QgsRasterLayer::readXml( const QDomNode& layer_node )
|
||||
|
||||
QDomNodeList rangeList = bandElement.elementsByTagName( "noDataRange" );
|
||||
|
||||
myNoDataRangeList.reserve( rangeList.size() );
|
||||
for ( int j = 0; j < rangeList.size(); ++j )
|
||||
{
|
||||
QDomElement rangeElement = rangeList.at( j ).toElement();
|
||||
|
@ -692,7 +692,9 @@ void QgsRasterProjector::insertRows( const QgsCoordinateTransform* ct )
|
||||
{
|
||||
QList<QgsPoint> myRow;
|
||||
QList<bool> myLegalRow;
|
||||
for ( int c = 0; c < mCPCols; c++ )
|
||||
myRow.reserve( mCPCols );
|
||||
myLegalRow.reserve( mCPCols );
|
||||
for ( int c = 0; c < mCPCols; ++c )
|
||||
{
|
||||
myRow.append( QgsPoint() );
|
||||
myLegalRow.append( false );
|
||||
|
@ -178,6 +178,7 @@ void QgsRasterShader::readXML( const QDomElement& elem )
|
||||
QColor itemColor;
|
||||
|
||||
QDomNodeList itemNodeList = colorRampShaderElem.elementsByTagName( "item" );
|
||||
itemList.reserve( itemNodeList.size() );
|
||||
for ( int i = 0; i < itemNodeList.size(); ++i )
|
||||
{
|
||||
itemElem = itemNodeList.at( i ).toElement();
|
||||
|
@ -522,6 +522,7 @@ QgsSymbolV2List QgsCategorizedSymbolRendererV2::symbols( QgsRenderContext &conte
|
||||
{
|
||||
Q_UNUSED( context );
|
||||
QgsSymbolV2List lst;
|
||||
lst.reserve( mCategories.count() );
|
||||
for ( int i = 0; i < mCategories.count(); i++ )
|
||||
lst.append( mCategories[i].symbol() );
|
||||
return lst;
|
||||
@ -697,6 +698,7 @@ QgsLegendSymbologyList QgsCategorizedSymbolRendererV2::legendSymbologyItems( QSi
|
||||
{
|
||||
QgsLegendSymbologyList lst;
|
||||
int count = categories().count();
|
||||
lst.reserve( count );
|
||||
for ( int i = 0; i < count; i++ )
|
||||
{
|
||||
const QgsRendererCategoryV2& cat = categories()[i];
|
||||
|
@ -683,6 +683,7 @@ bool QgsEllipseSymbolLayerV2::writeDxf( QgsDxfExport& e, double mmMapUnitScaleFa
|
||||
else
|
||||
{
|
||||
QgsPolyline line;
|
||||
line.reserve( 40 );
|
||||
double stepsize = 2 * M_PI / 40;
|
||||
for ( int i = 0; i < 39; ++i )
|
||||
{
|
||||
|
@ -549,6 +549,7 @@ QgsSymbolV2List QgsGraduatedSymbolRendererV2::symbols( QgsRenderContext &context
|
||||
{
|
||||
Q_UNUSED( context );
|
||||
QgsSymbolV2List lst;
|
||||
lst.reserve( mRanges.count() );
|
||||
for ( int i = 0; i < mRanges.count(); i++ )
|
||||
lst.append( mRanges[i].symbol() );
|
||||
return lst;
|
||||
@ -566,6 +567,7 @@ static QList<double> _calcEqualIntervalBreaks( double minimum, double maximum, i
|
||||
|
||||
QList<double> breaks;
|
||||
double value = minimum;
|
||||
breaks.reserve( classes );
|
||||
for ( int i = 0; i < classes; i++ )
|
||||
{
|
||||
value += step;
|
||||
@ -601,6 +603,7 @@ static QList<double> _calcQuantileBreaks( QList<double> values, int classes )
|
||||
int n = values.count();
|
||||
double Xq = n > 0 ? values[0] : 0.0;
|
||||
|
||||
breaks.reserve( classes );
|
||||
for ( int i = 1; i < classes; i++ )
|
||||
{
|
||||
if ( n > 1 )
|
||||
@ -1167,6 +1170,7 @@ QgsLegendSymbologyList QgsGraduatedSymbolRendererV2::legendSymbologyItems( QSize
|
||||
{
|
||||
QgsLegendSymbologyList lst;
|
||||
int count = ranges().count();
|
||||
lst.reserve( count );
|
||||
for ( int i = 0; i < count; i++ )
|
||||
{
|
||||
const QgsRendererRangeV2& range = ranges()[i];
|
||||
|
@ -72,7 +72,8 @@ class CORE_EXPORT QgsHeatmapRenderer : public QgsFeatureRendererV2
|
||||
* @see setInvertRamp
|
||||
* @see colorRamp
|
||||
*/
|
||||
double invertRamp() const { return mInvertRamp; }
|
||||
bool invertRamp() const { return mInvertRamp; }
|
||||
|
||||
/** Sets whether the ramp is inverted
|
||||
* @param invert set to true to invert color ramp
|
||||
* @see invertRamp
|
||||
|
@ -699,7 +699,7 @@ bool QgsFeatureRendererV2::willRenderFeature( QgsFeature &feat, QgsRenderContext
|
||||
return symbolForFeature( feat, context ) != NULL;
|
||||
}
|
||||
|
||||
void QgsFeatureRendererV2::renderVertexMarker( QPointF& pt, QgsRenderContext& context )
|
||||
void QgsFeatureRendererV2::renderVertexMarker( const QPointF &pt, QgsRenderContext& context )
|
||||
{
|
||||
QgsVectorLayer::drawVertexMarker( pt.x(), pt.y(), *context.painter(),
|
||||
( QgsVectorLayer::VertexMarkerType ) mCurrentVertexMarkerType,
|
||||
@ -708,20 +708,20 @@ void QgsFeatureRendererV2::renderVertexMarker( QPointF& pt, QgsRenderContext& co
|
||||
|
||||
void QgsFeatureRendererV2::renderVertexMarkerPolyline( QPolygonF& pts, QgsRenderContext& context )
|
||||
{
|
||||
Q_FOREACH ( QPointF pt, pts )
|
||||
Q_FOREACH ( const QPointF& pt, pts )
|
||||
renderVertexMarker( pt, context );
|
||||
}
|
||||
|
||||
void QgsFeatureRendererV2::renderVertexMarkerPolygon( QPolygonF& pts, QList<QPolygonF>* rings, QgsRenderContext& context )
|
||||
{
|
||||
Q_FOREACH ( QPointF pt, pts )
|
||||
Q_FOREACH ( const QPointF& pt, pts )
|
||||
renderVertexMarker( pt, context );
|
||||
|
||||
if ( rings )
|
||||
{
|
||||
Q_FOREACH ( QPolygonF ring, *rings )
|
||||
Q_FOREACH ( const QPolygonF& ring, *rings )
|
||||
{
|
||||
Q_FOREACH ( QPointF pt, ring )
|
||||
Q_FOREACH ( const QPointF& pt, ring )
|
||||
renderVertexMarker( pt, context );
|
||||
}
|
||||
}
|
||||
|
@ -322,7 +322,7 @@ class CORE_EXPORT QgsFeatureRendererV2
|
||||
bool drawVertexMarker );
|
||||
|
||||
//! render editing vertex marker at specified point
|
||||
void renderVertexMarker( QPointF& pt, QgsRenderContext& context );
|
||||
void renderVertexMarker( const QPointF& pt, QgsRenderContext& context );
|
||||
//! render editing vertex marker for a polyline
|
||||
void renderVertexMarkerPolyline( QPolygonF& pts, QgsRenderContext& context );
|
||||
//! render editing vertex marker for a polygon
|
||||
|
@ -733,6 +733,7 @@ static QPolygonF makeOffsetGeometry( const QgsPolyline& polyline )
|
||||
static QList<QPolygonF> makeOffsetGeometry( const QgsPolygon& polygon )
|
||||
{
|
||||
QList<QPolygonF> resultGeom;
|
||||
resultGeom.reserve( polygon.size() );
|
||||
for ( int ring = 0; ring < polygon.size(); ++ring )
|
||||
resultGeom.append( makeOffsetGeometry( polygon[ ring ] ) );
|
||||
return resultGeom;
|
||||
@ -793,7 +794,7 @@ QList<QPolygonF> offsetLine( QPolygonF polyline, double dist, QGis::GeometryType
|
||||
else if ( QGis::flatType( tempGeometry->wkbType() ) == QGis::WKBMultiLineString )
|
||||
{
|
||||
QgsMultiPolyline tempMPolyline = tempGeometry->asMultiPolyline();
|
||||
|
||||
resultLine.reserve( tempMPolyline.count() );
|
||||
for ( int part = 0; part < tempMPolyline.count(); ++part )
|
||||
{
|
||||
resultLine.append( makeOffsetGeometry( tempMPolyline[ part ] ) );
|
||||
@ -804,7 +805,7 @@ QList<QPolygonF> offsetLine( QPolygonF polyline, double dist, QGis::GeometryType
|
||||
else if ( QGis::flatType( tempGeometry->wkbType() ) == QGis::WKBMultiPolygon )
|
||||
{
|
||||
QgsMultiPolygon tempMPolygon = tempGeometry->asMultiPolygon();
|
||||
|
||||
resultLine.reserve( tempMPolygon.count() );
|
||||
for ( int part = 0; part < tempMPolygon.count(); ++part )
|
||||
{
|
||||
resultLine.append( makeOffsetGeometry( tempMPolygon[ part ] ) );
|
||||
@ -2316,7 +2317,7 @@ bool QgsSymbolLayerV2Utils::displacementFromSldElement( QDomElement &element, QP
|
||||
}
|
||||
|
||||
void QgsSymbolLayerV2Utils::labelTextToSld( QDomDocument &doc, QDomElement &element,
|
||||
QString label, QFont font,
|
||||
QString label, const QFont& font,
|
||||
QColor color, double size )
|
||||
{
|
||||
QDomElement labelElem = doc.createElement( "se:Label" );
|
||||
@ -3967,6 +3968,7 @@ QList<double> QgsSymbolLayerV2Utils::prettyBreaks( double minimum, double maximu
|
||||
//double maximumBreak = end * unit;
|
||||
int count = end - start;
|
||||
|
||||
breaks.reserve( count );
|
||||
for ( int i = 1; i < count + 1; i++ )
|
||||
{
|
||||
breaks.append( minimumBreak + i * unit );
|
||||
|
@ -221,7 +221,7 @@ class CORE_EXPORT QgsSymbolLayerV2Utils
|
||||
|
||||
|
||||
static void labelTextToSld( QDomDocument &doc, QDomElement &element, QString label,
|
||||
QFont font, QColor color = QColor(), double size = -1 );
|
||||
const QFont &font, QColor color = QColor(), double size = -1 );
|
||||
|
||||
/** Create ogr feature style string for pen */
|
||||
static QString ogrFeatureStylePen( double width, double mmScaleFactor, double mapUnitsScaleFactor, const QColor& c,
|
||||
|
@ -213,7 +213,7 @@ class CORE_EXPORT QgsSymbolV2
|
||||
* @note added in QGIS 2.9
|
||||
* @see setClipFeaturesToExtent
|
||||
*/
|
||||
double clipFeaturesToExtent() const { return mClipFeaturesToExtent; }
|
||||
bool clipFeaturesToExtent() const { return mClipFeaturesToExtent; }
|
||||
|
||||
QSet<QString> usedAttributes() const;
|
||||
|
||||
|
@ -340,7 +340,8 @@ QList<QColor> QgsVectorRandomColorRampV2::randomColors( int count,
|
||||
//start hue at random angle
|
||||
double currentHueAngle = 360.0 * ( double )qrand() / RAND_MAX;
|
||||
|
||||
for ( int i = 0; i < count; i++ )
|
||||
colors.reserve( count );
|
||||
for ( int i = 0; i < count; ++i )
|
||||
{
|
||||
//increment hue by golden ratio (approx 137.507 degrees)
|
||||
//as this minimises hue nearness as count increases
|
||||
|
@ -450,7 +450,9 @@ QModelIndexList QgsAttributeTableModel::idToIndexList( QgsFeatureId id ) const
|
||||
QModelIndexList indexes;
|
||||
|
||||
int row = idToRow( id );
|
||||
for ( int column = 0; column < columnCount(); ++column )
|
||||
int columns = columnCount();
|
||||
indexes.reserve( columns );
|
||||
for ( int column = 0; column < columns; ++column )
|
||||
{
|
||||
indexes.append( index( row, column ) );
|
||||
}
|
||||
|
@ -171,7 +171,9 @@ QModelIndexList QgsFeatureSelectionModel::expandIndexToRow( const QModelIndex& i
|
||||
if ( !model )
|
||||
return indexes;
|
||||
|
||||
for ( int column = 0; column < model->columnCount(); ++column )
|
||||
int columns = model->columnCount();
|
||||
indexes.reserve( columns );
|
||||
for ( int column = 0; column < columns; ++column )
|
||||
{
|
||||
indexes.append( model->index( row, column ) );
|
||||
}
|
||||
|
@ -276,7 +276,7 @@ void QgsAuthAuthoritiesEditor::appendCertsToItem( QList<QSslCertificate> certs,
|
||||
QStringList untrustedids = mCertTrustCache.value( QgsAuthCertUtils::Untrusted );
|
||||
|
||||
// Columns: Common Name, Serial #, Expiry Date
|
||||
Q_FOREACH ( QSslCertificate cert, certs )
|
||||
Q_FOREACH ( const QSslCertificate& cert, certs )
|
||||
{
|
||||
QString id( QgsAuthCertUtils::shaHexForCert( cert ) );
|
||||
|
||||
@ -694,7 +694,7 @@ void QgsAuthAuthoritiesEditor::on_btnCaFile_clicked()
|
||||
if ( dlg->certTrustPolicy() != QgsAuthCertUtils::DefaultTrust )
|
||||
{
|
||||
QList<QSslCertificate> certs( QgsAuthManager::instance()->getExtraFileCAs() );
|
||||
Q_FOREACH ( QSslCertificate cert, certs )
|
||||
Q_FOREACH ( const QSslCertificate& cert, certs )
|
||||
{
|
||||
if ( !QgsAuthManager::instance()->storeCertTrustPolicy( cert, dlg->certTrustPolicy() ) )
|
||||
{
|
||||
|
@ -774,7 +774,7 @@ void QgsAuthCertInfo::populateInfoDetailsSection()
|
||||
QStringList keyusage;
|
||||
QStringList extkeyusage;
|
||||
QList<QCA::ConstraintType> certconsts = mCurrentACert.constraints();
|
||||
Q_FOREACH ( QCA::ConstraintType certconst, certconsts )
|
||||
Q_FOREACH ( const QCA::ConstraintType& certconst, certconsts )
|
||||
{
|
||||
if ( certconst.section() == QCA::ConstraintType::KeyUsage )
|
||||
{
|
||||
|
@ -195,7 +195,7 @@ void QgsAuthIdentitiesEditor::appendIdentitiesToItem( QList<QSslCertificate> cer
|
||||
QBrush redb( QgsAuthGuiUtils::redColor() );
|
||||
|
||||
// Columns: Common Name, Serial #, Expiry Date
|
||||
Q_FOREACH ( QSslCertificate cert, certs )
|
||||
Q_FOREACH ( const QSslCertificate& cert, certs )
|
||||
{
|
||||
QString id( QgsAuthCertUtils::shaHexForCert( cert ) );
|
||||
|
||||
|
@ -414,7 +414,7 @@ bool QgsAuthImportIdentityDialog::validatePkiPkcs12()
|
||||
QList<QSslCertificate> ca_certs;
|
||||
if ( cert_chain.size() > 1 )
|
||||
{
|
||||
Q_FOREACH ( QCA::Certificate ca_cert, cert_chain )
|
||||
Q_FOREACH ( const QCA::Certificate& ca_cert, cert_chain )
|
||||
{
|
||||
if ( ca_cert != cert_chain.primary() )
|
||||
{
|
||||
|
@ -195,7 +195,7 @@ void QgsAuthServersEditor::appendSslConfigsToItem( QList<QgsAuthConfigSslServer>
|
||||
QBrush redb( QgsAuthGuiUtils::redColor() );
|
||||
|
||||
// Columns: Common Name, Host, Expiry Date
|
||||
Q_FOREACH ( QgsAuthConfigSslServer config, configs )
|
||||
Q_FOREACH ( const QgsAuthConfigSslServer& config, configs )
|
||||
{
|
||||
QSslCertificate cert( config.sslCertificate() );
|
||||
QString id( QgsAuthCertUtils::shaHexForCert( cert ) );
|
||||
|
@ -188,7 +188,7 @@ void QgsAuthTrustedCAsDialog::appendCertsToItem( QList<QSslCertificate> certs,
|
||||
QBrush redb( QgsAuthGuiUtils::redColor() );
|
||||
|
||||
// Columns: Common Name, Serial #, Expiry Date
|
||||
Q_FOREACH ( QSslCertificate cert, certs )
|
||||
Q_FOREACH ( const QSslCertificate& cert, certs )
|
||||
{
|
||||
QString id( QgsAuthCertUtils::shaHexForCert( cert ) );
|
||||
|
||||
|
@ -146,6 +146,7 @@ QgsEditorWidgetConfig QgsRelationReferenceConfigDlg::config()
|
||||
if ( mFilterGroupBox->isChecked() )
|
||||
{
|
||||
QStringList filterFields;
|
||||
filterFields.reserve( mFilterFieldsList->count() );
|
||||
for ( int i = 0; i < mFilterFieldsList->count(); i++ )
|
||||
{
|
||||
filterFields << mFilterFieldsList->item( i )->data( Qt::UserRole ).toString();
|
||||
|
@ -53,6 +53,7 @@ QgsEditorWidgetConfig QgsRelationReferenceFactory::readConfig( const QDomElement
|
||||
{
|
||||
QStringList filterFields;
|
||||
QDomNodeList fieldNodes = filterNode.toElement().elementsByTagName( "field" );
|
||||
filterFields.reserve( fieldNodes.size() );
|
||||
for ( int i = 0; i < fieldNodes.size(); i++ )
|
||||
{
|
||||
QDomElement fieldElement = fieldNodes.at( i ).toElement();
|
||||
|
@ -87,7 +87,7 @@ namespace QgisGui
|
||||
{
|
||||
// get a list of supported output image types
|
||||
QMap<QString, QString> filterMap;
|
||||
Q_FOREACH ( QByteArray format, QImageWriter::supportedImageFormats() )
|
||||
Q_FOREACH ( const QByteArray& format, QImageWriter::supportedImageFormats() )
|
||||
{
|
||||
//svg doesnt work so skip it
|
||||
if ( format == "svg" )
|
||||
|
@ -274,7 +274,7 @@ void QgsCollapsibleGroupBoxBasic::toggleCollapsed()
|
||||
{
|
||||
if ( grpbox->syncGroup() == syncGroup() && grpbox->isEnabled() )
|
||||
{
|
||||
if ( mShiftDown && grpbox == dynamic_cast<QgsCollapsibleGroupBoxBasic *>( this ) )
|
||||
if ( mShiftDown && grpbox == this )
|
||||
{
|
||||
// expand current group box on shift-click
|
||||
setCollapsed( false );
|
||||
|
@ -643,6 +643,7 @@ void QgsDataDefinedButton::registerEnabledWidget( QWidget* wdgt )
|
||||
QList<QWidget*> QgsDataDefinedButton::registeredEnabledWidgets()
|
||||
{
|
||||
QList<QWidget*> wdgtList;
|
||||
wdgtList.reserve( mEnabledWidgets.size() );
|
||||
for ( int i = 0; i < mEnabledWidgets.size(); ++i )
|
||||
{
|
||||
wdgtList << mEnabledWidgets.at( i );
|
||||
@ -678,6 +679,7 @@ void QgsDataDefinedButton::registerCheckedWidget( QWidget* wdgt )
|
||||
QList<QWidget*> QgsDataDefinedButton::registeredCheckedWidgets()
|
||||
{
|
||||
QList<QWidget*> wdgtList;
|
||||
wdgtList.reserve( mCheckedWidgets.size() );
|
||||
for ( int i = 0; i < mCheckedWidgets.size(); ++i )
|
||||
{
|
||||
wdgtList << mCheckedWidgets.at( i );
|
||||
|
@ -285,6 +285,7 @@ void QgsExpressionBuilderWidget::loadFieldNames( const QgsFields& fields )
|
||||
|
||||
QStringList fieldNames;
|
||||
//Q_FOREACH ( const QgsField& field, fields )
|
||||
fieldNames.reserve( fields.count() );
|
||||
for ( int i = 0; i < fields.count(); ++i )
|
||||
{
|
||||
QString fieldName = fields[i].name();
|
||||
|
@ -83,6 +83,7 @@ void QgsManageConnectionsDialog::doExportImport()
|
||||
}
|
||||
|
||||
QStringList items;
|
||||
items.reserve( selection.size() );
|
||||
for ( int i = 0; i < selection.size(); ++i )
|
||||
{
|
||||
items.append( selection.at( i )->text() );
|
||||
|
@ -130,7 +130,7 @@ void QgsMessageBar::popItem( QgsMessageBarItem *item )
|
||||
{
|
||||
if ( mCurrentItem )
|
||||
{
|
||||
QWidget *widget = dynamic_cast<QWidget*>( mCurrentItem );
|
||||
QWidget *widget = mCurrentItem;
|
||||
mLayout->removeWidget( widget );
|
||||
mCurrentItem->hide();
|
||||
disconnect( mCurrentItem, SIGNAL( styleChanged( QString ) ), this, SLOT( setStyleSheet( QString ) ) );
|
||||
|
@ -718,7 +718,9 @@ QgsRasterRangeList QgsRasterLayerSaveAsDialog::noData() const
|
||||
if ( ! mNoDataGroupBox->isChecked() )
|
||||
return noDataList;
|
||||
|
||||
for ( int r = 0 ; r < mNoDataTableWidget->rowCount(); r++ )
|
||||
int rows = mNoDataTableWidget->rowCount();
|
||||
noDataList.reserve( rows );
|
||||
for ( int r = 0 ; r < rows; r++ )
|
||||
{
|
||||
QgsRasterRange noData( noDataCellValue( r, 0 ), noDataCellValue( r, 1 ) );
|
||||
noDataList.append( noData );
|
||||
|
@ -126,7 +126,9 @@ QList< QgsRelation > QgsRelationManagerDialog::relations()
|
||||
{
|
||||
QList< QgsRelation > relations;
|
||||
|
||||
for ( int i = 0; i < mRelationsTable->rowCount(); ++i )
|
||||
int rows = mRelationsTable->rowCount();
|
||||
relations.reserve( rows );
|
||||
for ( int i = 0; i < rows; ++i )
|
||||
{
|
||||
QgsRelation relation = mRelationsTable->item( i, 0 )->data( Qt::UserRole ).value<QgsRelation>();
|
||||
// The name can be editted in the table, so apply this one
|
||||
|
@ -252,6 +252,7 @@ void QgsSingleBandPseudoColorRendererWidget::on_mClassifyButton_clicked()
|
||||
if ( colorRamp )
|
||||
{
|
||||
numberOfEntries = colorRamp->count();
|
||||
entryValues.reserve( colorRamp->count() );
|
||||
for ( int i = 0; i < colorRamp->count(); ++i )
|
||||
{
|
||||
double value = colorRamp->value( i );
|
||||
@ -278,6 +279,7 @@ void QgsSingleBandPseudoColorRendererWidget::on_mClassifyButton_clicked()
|
||||
intervalDiff = max - min;
|
||||
}
|
||||
|
||||
entryValues.reserve( numberOfEntries );
|
||||
for ( int i = 0; i < numberOfEntries; ++i )
|
||||
{
|
||||
entryValues.push_back( currentValue );
|
||||
@ -309,6 +311,7 @@ void QgsSingleBandPseudoColorRendererWidget::on_mClassifyButton_clicked()
|
||||
colorDiff = ( int )( 255 / numberOfEntries );
|
||||
}
|
||||
|
||||
entryColors.reserve( numberOfEntries );
|
||||
for ( int i = 0; i < numberOfEntries; ++i )
|
||||
{
|
||||
QColor currentColor;
|
||||
@ -319,6 +322,7 @@ void QgsSingleBandPseudoColorRendererWidget::on_mClassifyButton_clicked()
|
||||
}
|
||||
else
|
||||
{
|
||||
entryColors.reserve( numberOfEntries );
|
||||
for ( int i = 0; i < numberOfEntries; ++i )
|
||||
{
|
||||
int idx = mInvertCheckBox->isChecked() ? numberOfEntries - i - 1 : i;
|
||||
|
@ -359,8 +359,7 @@ void QgsCptCityColorRampV2Dialog::on_pbtnLicenseDetails_pressed()
|
||||
QString path, title, copyFile, descFile;
|
||||
|
||||
// get basic information, depending on if is color ramp or directory
|
||||
QgsCptCityDataItem *item =
|
||||
dynamic_cast< QgsCptCityDataItem* >( mModel->dataItem( mTreeFilter->mapToSource( mTreeView->currentIndex() ) ) );
|
||||
QgsCptCityDataItem *item = mModel->dataItem( mTreeFilter->mapToSource( mTreeView->currentIndex() ) );
|
||||
if ( ! item )
|
||||
return;
|
||||
|
||||
|
@ -204,6 +204,7 @@ void QgsVectorGradientColorRampV2Dialog::updatePreview()
|
||||
if ( groupStops->isChecked() )
|
||||
{
|
||||
int count = treeStops->topLevelItemCount();
|
||||
stops.reserve( count );
|
||||
for ( int i = 0; i < count; i++ )
|
||||
{
|
||||
QTreeWidgetItem* item = treeStops->topLevelItem( i );
|
||||
|
@ -366,7 +366,7 @@ void QgsGeometryCheckerResultTab::highlightErrors( bool current )
|
||||
{
|
||||
double cx = 0., cy = 0.;
|
||||
QgsRectangle pointExtent( errorPositions.first(), errorPositions.first() );
|
||||
foreach ( QgsPoint p, errorPositions )
|
||||
foreach ( const QgsPoint& p, errorPositions )
|
||||
{
|
||||
cx += p.x();
|
||||
cy += p.y();
|
||||
|
@ -105,7 +105,7 @@ QString QgsGrassModule::findExec( QString file )
|
||||
#endif
|
||||
|
||||
// Search for module
|
||||
foreach ( QString path, QgsGrass::grassModulesPaths() )
|
||||
foreach ( const QString& path, QgsGrass::grassModulesPaths() )
|
||||
{
|
||||
QString full = path + "/" + file;
|
||||
if ( QFile::exists( full ) )
|
||||
@ -712,7 +712,7 @@ void QgsGrassModule::run()
|
||||
|
||||
// Print some important variables
|
||||
variables << "QGIS_PREFIX_PATH" << "QGIS_GRASS_CRS" << "GRASS_REGION";
|
||||
foreach ( QString v, variables )
|
||||
foreach ( const QString& v, variables )
|
||||
{
|
||||
mOutputTextBrowser->append( v + "=" + environment.value( v ) + "<BR>" );
|
||||
}
|
||||
|
@ -95,7 +95,7 @@ void QgsGrassModuleInputModel::onDirectoryChanged( const QString & path )
|
||||
}
|
||||
}
|
||||
|
||||
foreach ( QString dirName, dirNames )
|
||||
foreach ( const QString& dirName, dirNames )
|
||||
{
|
||||
// Add to watcher in any case, either for WIND, cellhd or vector
|
||||
QString dirPath = locationPath + "/" + dirName;
|
||||
@ -175,7 +175,7 @@ void QgsGrassModuleInputModel::refreshMapset( QStandardItem *mapsetItem, const Q
|
||||
{
|
||||
QStringList maps = QgsGrass::grassObjects( QgsGrass::getDefaultGisdbase() + "/" + QgsGrass::getDefaultLocation() + "/" + mapset, type );
|
||||
QStringList mapNames;
|
||||
foreach ( QString map, maps )
|
||||
foreach ( const QString& map, maps )
|
||||
{
|
||||
if ( map.startsWith( "qgis_import_tmp_" ) )
|
||||
{
|
||||
@ -237,7 +237,7 @@ void QgsGrassModuleInputModel::reload()
|
||||
mLocationPath = QgsGrass::getDefaultLocationPath();
|
||||
|
||||
QStringList mapsets = QgsGrass::mapsets( QgsGrass::getDefaultGisdbase(), QgsGrass::getDefaultLocation() );
|
||||
foreach ( QString mapset, mapsets )
|
||||
foreach ( const QString& mapset, mapsets )
|
||||
{
|
||||
addMapset( mapset );
|
||||
}
|
||||
@ -246,7 +246,7 @@ void QgsGrassModuleInputModel::reload()
|
||||
|
||||
// Watching all dirs in location because a dir may become a mapset later, when WIND is created
|
||||
QStringList dirNames = locationDirNames();
|
||||
foreach ( QString dirName, dirNames )
|
||||
foreach ( const QString& dirName, dirNames )
|
||||
{
|
||||
QString dirPath = mLocationPath + "/" + dirName;
|
||||
// Watch the dir in any case, WIND mabe created later
|
||||
@ -769,7 +769,7 @@ QgsGrassModuleInput::QgsGrassModuleInput( QgsGrassModule *module,
|
||||
{
|
||||
int mask = 0;
|
||||
|
||||
foreach ( QString typeName, opt.split( "," ) )
|
||||
foreach ( const QString& typeName, opt.split( "," ) )
|
||||
{
|
||||
mask |= QgsGrass::vectorType( typeName );
|
||||
}
|
||||
|
@ -1094,7 +1094,8 @@ QStringList QgsGrass::vectors( const QString& mapsetPath )
|
||||
QDir d = QDir( mapsetPath + "/vector" );
|
||||
d.setFilter( QDir::NoDotAndDotDot | QDir::Dirs );
|
||||
|
||||
for ( unsigned int i = 0; i < d.count(); i++ )
|
||||
list.reserve( d.count() );
|
||||
for ( unsigned int i = 0; i < d.count(); ++i )
|
||||
{
|
||||
/*
|
||||
if ( QFile::exists ( mapsetPath + "/vector/" + d[i] + "/head" ) )
|
||||
@ -1268,7 +1269,8 @@ QStringList QgsGrass::rasters( const QString& mapsetPath )
|
||||
QDir d = QDir( mapsetPath + "/cellhd" );
|
||||
d.setFilter( QDir::Files );
|
||||
|
||||
for ( unsigned int i = 0; i < d.count(); i++ )
|
||||
list.reserve( d.count() );
|
||||
for ( unsigned int i = 0; i < d.count(); ++i )
|
||||
{
|
||||
list.append( d[i] );
|
||||
}
|
||||
@ -1316,7 +1318,8 @@ QStringList QgsGrass::elements( const QString& mapsetPath, const QString& elem
|
||||
d.setFilter( QDir::Files );
|
||||
}
|
||||
|
||||
for ( unsigned int i = 0; i < d.count(); i++ )
|
||||
list.reserve( d.count() );
|
||||
for ( unsigned int i = 0; i < d.count(); ++i )
|
||||
{
|
||||
list.append( d[i] );
|
||||
}
|
||||
@ -1729,7 +1732,7 @@ QProcess *QgsGrass::startModule( const QString& gisdbase, const QString& locati
|
||||
QString ownedMapset = mapset;
|
||||
if ( ownedMapset.isEmpty() )
|
||||
{
|
||||
Q_FOREACH ( QString ms, mapsets( gisdbase, location ) )
|
||||
Q_FOREACH ( const QString& ms, mapsets( gisdbase, location ) )
|
||||
{
|
||||
if ( isOwner( gisdbase, location, ms ) )
|
||||
{
|
||||
@ -2193,7 +2196,7 @@ void QgsGrass::insertRow( dbDriver *driver, const QString tableName,
|
||||
}
|
||||
|
||||
QStringList valuesStringList;
|
||||
foreach ( QVariant attribute, attributes )
|
||||
foreach ( const QVariant& attribute, attributes )
|
||||
{
|
||||
QString valueString;
|
||||
|
||||
|
@ -72,7 +72,7 @@ void QgsGrassImportProgress::onReadyReadStandardError()
|
||||
{
|
||||
// TODO: parse better progress output
|
||||
QString output = QString::fromLocal8Bit( mProcess->readAllStandardError() );
|
||||
Q_FOREACH ( QString line, output.split( "\n" ) )
|
||||
Q_FOREACH ( const QString& line, output.split( "\n" ) )
|
||||
{
|
||||
QgsDebugMsg( "line = '" + line + "'" );
|
||||
QString text, html;
|
||||
@ -500,7 +500,9 @@ QStringList QgsGrassRasterImport::extensions( QgsRasterDataProvider* provider )
|
||||
QStringList list;
|
||||
if ( provider && provider->bandCount() > 1 )
|
||||
{
|
||||
for ( int band = 1; band <= provider->bandCount(); band++ )
|
||||
int bands = provider->bandCount();
|
||||
list.reserve( bands );
|
||||
for ( int band = 1; band <= bands; ++band )
|
||||
{
|
||||
list << QString( ".%1" ).arg( band );
|
||||
}
|
||||
@ -513,7 +515,7 @@ QStringList QgsGrassRasterImport::names() const
|
||||
QStringList list;
|
||||
if ( mPipe && mPipe->provider() )
|
||||
{
|
||||
foreach ( QString ext, extensions( mPipe->provider() ) )
|
||||
foreach ( const QString& ext, extensions( mPipe->provider() ) )
|
||||
{
|
||||
list << mGrassObject.name() + ext;
|
||||
}
|
||||
|
@ -328,7 +328,7 @@ QVector<QgsDataItem*>QgsGrassLocationItem::createChildren()
|
||||
QDir dir( mDirPath );
|
||||
|
||||
QStringList entries = dir.entryList( QDir::Dirs | QDir::NoDotAndDotDot, QDir::Name );
|
||||
foreach ( QString name, entries )
|
||||
foreach ( const QString& name, entries )
|
||||
{
|
||||
QString path = dir.absoluteFilePath( name );
|
||||
|
||||
@ -420,7 +420,7 @@ QVector<QgsDataItem*> QgsGrassMapsetItem::createChildren()
|
||||
QVector<QgsDataItem*> items;
|
||||
|
||||
QStringList vectorNames = QgsGrass::vectors( mDirPath );
|
||||
Q_FOREACH ( QString name, vectorNames )
|
||||
Q_FOREACH ( const QString& name, vectorNames )
|
||||
{
|
||||
if ( mRefreshLater )
|
||||
{
|
||||
@ -509,7 +509,7 @@ QVector<QgsDataItem*> QgsGrassMapsetItem::createChildren()
|
||||
//map->setCapabilities( QgsDataItem::NoCapabilities ); // disable fertility
|
||||
map = new QgsGrassVectorItem( this, vectorObject, mapPath );
|
||||
}
|
||||
foreach ( QString layerName, layerNames )
|
||||
foreach ( const QString& layerName, layerNames )
|
||||
{
|
||||
// don't use QDir::separator(), windows work with '/' and backslash may be lost if
|
||||
// somewhere not properly escaped (there was bug in QgsMimeDataUtils for example)
|
||||
@ -548,7 +548,7 @@ QVector<QgsDataItem*> QgsGrassMapsetItem::createChildren()
|
||||
|
||||
QStringList rasterNames = QgsGrass::rasters( mDirPath );
|
||||
|
||||
foreach ( QString name, rasterNames )
|
||||
foreach ( const QString& name, rasterNames )
|
||||
{
|
||||
if ( mRefreshLater )
|
||||
{
|
||||
@ -571,7 +571,7 @@ QVector<QgsDataItem*> QgsGrassMapsetItem::createChildren()
|
||||
}
|
||||
|
||||
QStringList groupNames = QgsGrass::groups( mDirPath );
|
||||
foreach ( QString name, groupNames )
|
||||
foreach ( const QString& name, groupNames )
|
||||
{
|
||||
if ( mRefreshLater )
|
||||
{
|
||||
@ -819,7 +819,7 @@ bool QgsGrassMapsetItem::handleDrop( const QMimeData * data, Qt::DropAction )
|
||||
|
||||
// delete existing files (confirmed before in dialog)
|
||||
bool deleteOk = true;
|
||||
foreach ( QString name, import->names() )
|
||||
foreach ( const QString& name, import->names() )
|
||||
{
|
||||
QgsGrassObject obj( import->grassObject() );
|
||||
obj.setName( name );
|
||||
|
@ -587,7 +587,7 @@ QDateTime QgsGrassRasterProvider::dataTimestamp() const
|
||||
QString mapset = mGisdbase + "/" + mLocation + "/" + mMapset;
|
||||
QStringList dirs;
|
||||
dirs << "cell" << "colr";
|
||||
foreach ( QString dir, dirs )
|
||||
foreach ( const QString& dir, dirs )
|
||||
{
|
||||
QString path = mapset + "/" + dir + "/" + mMapName;
|
||||
QFileInfo fi( path );
|
||||
|
@ -613,6 +613,7 @@ QgsAbstractGeometryV2 * QgsGrassVectorMap::lineGeometry( int id )
|
||||
|
||||
int type = Vect_read_line( mMap, points, 0, id );
|
||||
QList<QgsPointV2> pointList;
|
||||
pointList.reserve( points->n_points );
|
||||
for ( int i = 0; i < points->n_points; i++ )
|
||||
{
|
||||
pointList << QgsPointV2( is3d() ? QgsWKBTypes::PointZ : QgsWKBTypes::Point, points->x[i], points->y[i], points->z[i] );
|
||||
@ -664,6 +665,7 @@ QgsAbstractGeometryV2 * QgsGrassVectorMap::areaGeometry( int id )
|
||||
Vect_get_area_points( mMap, id, points );
|
||||
|
||||
QList<QgsPointV2> pointList;
|
||||
pointList.reserve( points->n_points );
|
||||
for ( int i = 0; i < points->n_points; i++ )
|
||||
{
|
||||
pointList << QgsPointV2( is3d() ? QgsWKBTypes::PointZ : QgsWKBTypes::Point, points->x[i], points->y[i], points->z[i] );
|
||||
@ -680,6 +682,7 @@ QgsAbstractGeometryV2 * QgsGrassVectorMap::areaGeometry( int id )
|
||||
int isle = Vect_get_area_isle( mMap, id, i );
|
||||
Vect_get_isle_points( mMap, isle, points );
|
||||
|
||||
pointList.reserve( points->n_points );
|
||||
for ( int i = 0; i < points->n_points; i++ )
|
||||
{
|
||||
pointList << QgsPointV2( is3d() ? QgsWKBTypes::PointZ : QgsWKBTypes::Point, points->x[i], points->y[i], points->z[i] );
|
||||
|
@ -746,7 +746,7 @@ void QgsGrassVectorMapLayer::deleteColumn( const QgsField &field, QString &error
|
||||
queries << QString( "CREATE UNIQUE INDEX %1_%2 ON %1 (%2)" ).arg( mFieldInfo->table ).arg( mFieldInfo->key );
|
||||
queries << "COMMIT";
|
||||
// Execute one after another to get possible error
|
||||
Q_FOREACH ( QString query, queries )
|
||||
Q_FOREACH ( const QString& query, queries )
|
||||
{
|
||||
QgsDebugMsg( "query = " + query );
|
||||
executeSql( query, error );
|
||||
@ -832,7 +832,8 @@ void QgsGrassVectorMapLayer::insertAttributes( int cat, const QgsFeature &featur
|
||||
if ( error.isEmpty() )
|
||||
{
|
||||
QList<QVariant> values;
|
||||
for ( int i = 0; i < mAttributeFields.size(); i++ )
|
||||
values.reserve( mAttributeFields.size() );
|
||||
for ( int i = 0; i < mAttributeFields.size(); ++i )
|
||||
{
|
||||
values << QVariant();
|
||||
}
|
||||
|
@ -198,7 +198,8 @@ QVector<QgsDataItem*> QgsOgrDataCollectionItem::createChildren()
|
||||
return children;
|
||||
int numLayers = OGR_DS_GetLayerCount( hDataSource );
|
||||
|
||||
for ( int i = 0; i < numLayers; i++ )
|
||||
children.reserve( numLayers );
|
||||
for ( int i = 0; i < numLayers; ++i )
|
||||
{
|
||||
QgsOgrLayerItem* item = dataItemForLayer( this, QString(), mPath, hDataSource, i );
|
||||
children.append( item );
|
||||
|
@ -1087,6 +1087,7 @@ PGresult *QgsPostgresConn::PQexecPrepared( QString stmtName, const QStringList &
|
||||
const char **param = new const char *[ params.size()];
|
||||
QList<QByteArray> qparam;
|
||||
|
||||
qparam.reserve( params.size() );
|
||||
for ( int i = 0; i < params.size(); i++ )
|
||||
{
|
||||
qparam << params[i].toUtf8();
|
||||
|
@ -1847,6 +1847,7 @@ bool QgsPostgresProvider::addFeatures( QgsFeatureList &flist )
|
||||
appendGeomParam( features->constGeometry(), params );
|
||||
}
|
||||
|
||||
params.reserve( fieldId.size() );
|
||||
for ( int i = 0; i < fieldId.size(); i++ )
|
||||
{
|
||||
int attrIdx = fieldId[i];
|
||||
@ -2432,6 +2433,7 @@ bool QgsPostgresProvider::changeGeometryValues( QgsGeometryMap & geometry_map )
|
||||
QgsAttributeList QgsPostgresProvider::attributeIndexes()
|
||||
{
|
||||
QgsAttributeList lst;
|
||||
lst.reserve( mAttributeFields.count() );
|
||||
for ( int i = 0; i < mAttributeFields.count(); ++i )
|
||||
lst.append( i );
|
||||
return lst;
|
||||
|
@ -3101,7 +3101,7 @@ void QgsWmsProvider::getLegendGraphicReplyFinished( const QImage& img )
|
||||
if ( ! img.isNull() )
|
||||
{
|
||||
mGetLegendGraphicImage = img;
|
||||
mGetLegendGraphicExtent = QgsRectangle( reply->property( "legendExtent" ).value<QRectF>() );
|
||||
mGetLegendGraphicExtent = QgsRectangle( reply->property( "legendExtent" ).toRectF() );
|
||||
mGetLegendGraphicScale = reply->property( "legendScale" ).value<double>();
|
||||
|
||||
#ifdef QGISDEBUG
|
||||
|
Loading…
x
Reference in New Issue
Block a user