diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2016-12-01 12:50:30 +0100 |
---|---|---|
committer | Paolo Angelelli <paolo.angelelli@qt.io> | 2016-12-07 11:48:10 +0000 |
commit | 7656821275de8b932c75063adfcdf8deb968db84 (patch) | |
tree | 993adbf164d02349b88d3308f7a8df629921562c /tests | |
parent | 9e71adaf31fe50e9966a6b09619968ae2b1176b6 (diff) | |
download | qtlocation-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 'tests')
-rw-r--r-- | tests/auto/qgeocircle/tst_qgeocircle.cpp | 10 | ||||
-rw-r--r-- | tests/auto/qgeorectangle/tst_qgeorectangle.cpp | 10 |
2 files changed, 10 insertions, 10 deletions
diff --git a/tests/auto/qgeocircle/tst_qgeocircle.cpp b/tests/auto/qgeocircle/tst_qgeocircle.cpp index fb2f248b..8777e7d9 100644 --- a/tests/auto/qgeocircle/tst_qgeocircle.cpp +++ b/tests/auto/qgeocircle/tst_qgeocircle.cpp @@ -63,8 +63,8 @@ private slots: void boundingGeoRectangle_data(); void boundingGeoRectangle(); - void extendShape(); - void extendShape_data(); + void extendCircle(); + void extendCircle_data(); void areaComparison(); void areaComparison_data(); @@ -343,7 +343,7 @@ void tst_QGeoCircle::boundingGeoRectangle() QCOMPARE(box.contains(probe), result); } -void tst_QGeoCircle::extendShape() +void tst_QGeoCircle::extendCircle() { QFETCH(QGeoCircle, circle); QFETCH(QGeoCoordinate, coord); @@ -351,12 +351,12 @@ void tst_QGeoCircle::extendShape() QFETCH(bool, containsExtended); QCOMPARE(circle.contains(coord), containsFirst); - circle.extendShape(coord); + circle.extendCircle(coord); QCOMPARE(circle.contains(coord), containsExtended); } -void tst_QGeoCircle::extendShape_data() +void tst_QGeoCircle::extendCircle_data() { QTest::addColumn<QGeoCircle>("circle"); QTest::addColumn<QGeoCoordinate>("coord"); diff --git a/tests/auto/qgeorectangle/tst_qgeorectangle.cpp b/tests/auto/qgeorectangle/tst_qgeorectangle.cpp index 06b65e86..01f0104b 100644 --- a/tests/auto/qgeorectangle/tst_qgeorectangle.cpp +++ b/tests/auto/qgeorectangle/tst_qgeorectangle.cpp @@ -86,8 +86,8 @@ private slots: void unite(); void unite_data(); - void extendShape(); - void extendShape_data(); + void extendRectangle(); + void extendRectangle_data(); void areaComparison(); void areaComparison_data(); @@ -2226,17 +2226,17 @@ void tst_QGeoRectangle::unite_data() } -void tst_QGeoRectangle::extendShape() +void tst_QGeoRectangle::extendRectangle() { QFETCH(QGeoRectangle, box); QFETCH(QGeoCoordinate, coord); QFETCH(QGeoRectangle, out); - box.extendShape(coord); + box.extendRectangle(coord); QCOMPARE(box, out); } -void tst_QGeoRectangle::extendShape_data() +void tst_QGeoRectangle::extendRectangle_data() { QTest::addColumn<QGeoRectangle>("box"); QTest::addColumn<QGeoCoordinate>("coord"); |