summaryrefslogtreecommitdiff
path: root/src/positioning/qgeorectangle.cpp
diff options
context:
space:
mode:
authorPaolo Angelelli <paolo.angelelli@qt.io>2016-12-01 12:50:30 +0100
committerPaolo Angelelli <paolo.angelelli@qt.io>2016-12-07 11:48:10 +0000
commit7656821275de8b932c75063adfcdf8deb968db84 (patch)
tree993adbf164d02349b88d3308f7a8df629921562c /src/positioning/qgeorectangle.cpp
parent9e71adaf31fe50e9966a6b09619968ae2b1176b6 (diff)
downloadqtlocation-7656821275de8b932c75063adfcdf8deb968db84.tar.gz
Deprecate QGeoShape::extendShape
As the collection of QGeoShapes grows, this method loses its scope, as it would have undefined behavior for certain shapes (polygon, or polyline, for example). Therefore the base class virtual method is now deprecated, with the documentation pointing to the specific implementations instead. Change-Id: I9717df092b8686b5413556858e9dfe7eaa92dd80 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/positioning/qgeorectangle.cpp')
-rw-r--r--src/positioning/qgeorectangle.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/positioning/qgeorectangle.cpp b/src/positioning/qgeorectangle.cpp
index e74beee3..1453a6a8 100644
--- a/src/positioning/qgeorectangle.cpp
+++ b/src/positioning/qgeorectangle.cpp
@@ -782,6 +782,17 @@ QGeoRectangle QGeoRectangle::translated(double degreesLatitude, double degreesLo
}
/*!
+ Extends the geo rectangle to also cover the coordinate \a coordinate
+
+ \since 5.9
+*/
+void QGeoRectangle::extendRectangle(const QGeoCoordinate &coordinate)
+{
+ Q_D(QGeoRectangle);
+ d->extendShape(coordinate);
+}
+
+/*!
Returns the smallest geo rectangle which contains both this geo rectangle and \a rectangle.
If the centers of the two geo rectangles are separated by exactly 180.0 degrees then the