Skip to content

Commit

Permalink
fix build errors (followup 13e37d4)
Browse files Browse the repository at this point in the history
  • Loading branch information
jef-n committed Sep 12, 2016
1 parent 13e37d4 commit 93afbe1
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions src/core/dxf/qgsdxfexport.cpp
Expand Up @@ -3781,12 +3781,12 @@ void QgsDxfExport::addFeature( QgsSymbolRenderContext& ctx, const QString& layer

if ( penStyle != Qt::NoPen )
{
const QgsAbstractGeometryV2 *tempGeom = geom;
const QgsAbstractGeometry *tempGeom = geom;

switch ( QgsWkbTypes::flatType( geometryType ) )
{
case QgsWkbTypes::CircularString:
case QgsWkbypes::CompoundCurve:
case QgsWkbTypes::CompoundCurve:
tempGeom = geom->segmentize();
FALLTHROUGH;
case QgsWkbTypes::LineString:
Expand Down Expand Up @@ -3819,7 +3819,7 @@ void QgsDxfExport::addFeature( QgsSymbolRenderContext& ctx, const QString& layer
tempGeom = geom;
}

const QgsCoordinateSequenceV2 &cs = tempGeom->coordinateSequence();
const QgsCoordinateSequence &cs = tempGeom->coordinateSequence();
for ( int i = 0; i < cs.size(); i++ )
{
writePolyline( cs.at( i ).at( 0 ), layer, lineStyleName, penColor, width );
Expand All @@ -3843,7 +3843,7 @@ void QgsDxfExport::addFeature( QgsSymbolRenderContext& ctx, const QString& layer
tempGeom = geom;
}

const QgsCoordinateSequenceV2 &cs = tempGeom->coordinateSequence();
const QgsCoordinateSequence &cs = tempGeom->coordinateSequence();
for ( int i = 0; i < cs.at( 0 ).size(); i++ )
{
writePolyline( cs.at( 0 ).at( i ), layer, lineStyleName, penColor, width );
Expand All @@ -3864,7 +3864,7 @@ void QgsDxfExport::addFeature( QgsSymbolRenderContext& ctx, const QString& layer
tempGeom = geom;
}

const QgsCoordinateSequenceV2 &cs = tempGeom->coordinateSequence();
const QgsCoordinateSequence &cs = tempGeom->coordinateSequence();
for ( int i = 0; i < cs.size(); i++ )
for ( int j = 0; j < cs.at( i ).size(); j++ )
writePolyline( cs.at( i ).at( j ), layer, lineStyleName, penColor, width );
Expand All @@ -3882,7 +3882,7 @@ void QgsDxfExport::addFeature( QgsSymbolRenderContext& ctx, const QString& layer

if ( brushStyle != Qt::NoBrush )
{
const QgsAbstractGeometryV2 *tempGeom = geom;
const QgsAbstractGeometry *tempGeom = geom;

switch ( QgsWkbTypes::flatType( geometryType ) )
{
Expand All @@ -3893,12 +3893,15 @@ void QgsDxfExport::addFeature( QgsSymbolRenderContext& ctx, const QString& layer
writePolygon( tempGeom->coordinateSequence().at( 0 ), layer, "SOLID", brushColor );
break;

case QgsWKBTypes::MultiPolygon:
const QgsCoordinateSequenceV2 &cs = geom->coordinateSequence();
case QgsWkbTypes::MultiPolygon:
{
const QgsCoordinateSequence &cs = geom->coordinateSequence();
for ( int i = 0; i < cs.size(); i++ )
{
writePolygon( cs.at( i ), layer, "SOLID", brushColor );
}
break;
}

default:
break;
Expand Down

0 comments on commit 93afbe1

Please sign in to comment.