Skip to content

Commit 3d0d7aa

Browse files
committedSep 19, 2017
Remove unused QgsGeometryFactory::fromRect method
1 parent 9b6e79c commit 3d0d7aa

File tree

2 files changed

+0
-17
lines changed

2 files changed

+0
-17
lines changed
 

‎src/core/geometry/qgsgeometryfactory.cpp

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -196,21 +196,6 @@ std::unique_ptr< QgsMultiPolygonV2 > QgsGeometryFactory::fromMultiPolygon( const
196196
return mp;
197197
}
198198

199-
std::unique_ptr<QgsPolygonV2> QgsGeometryFactory::fromRect( const QgsRectangle &rect )
200-
{
201-
QgsPolyline ring;
202-
ring.append( QgsPointXY( rect.xMinimum(), rect.yMinimum() ) );
203-
ring.append( QgsPointXY( rect.xMaximum(), rect.yMinimum() ) );
204-
ring.append( QgsPointXY( rect.xMaximum(), rect.yMaximum() ) );
205-
ring.append( QgsPointXY( rect.xMinimum(), rect.yMaximum() ) );
206-
ring.append( QgsPointXY( rect.xMinimum(), rect.yMinimum() ) );
207-
208-
QgsPolygon polygon;
209-
polygon.append( ring );
210-
211-
return fromPolygon( polygon );
212-
}
213-
214199
std::unique_ptr<QgsLineString> QgsGeometryFactory::linestringFromPolyline( const QgsPolyline &polyline )
215200
{
216201
QVector< double > x;

‎src/core/geometry/qgsgeometryfactory.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,6 @@ class CORE_EXPORT QgsGeometryFactory
7373
static std::unique_ptr<QgsPolygonV2> fromPolygon( const QgsPolygon &polygon );
7474
//! Construct geometry from a multipolygon
7575
static std::unique_ptr<QgsMultiPolygonV2> fromMultiPolygon( const QgsMultiPolygon &multipoly );
76-
//! Construct geometry from a rectangle
77-
static std::unique_ptr<QgsPolygonV2> fromRect( const QgsRectangle &rect );
7876
//! Return empty geometry from wkb type
7977
static std::unique_ptr< QgsAbstractGeometry > geomFromWkbType( QgsWkbTypes::Type t );
8078

0 commit comments

Comments
 (0)
Please sign in to comment.