diff options
author | abcd <qt-info@nokia.com> | 2011-09-01 19:50:34 +1000 |
---|---|---|
committer | abcd <qt_abcd1@ovi.com> | 2011-09-02 08:22:39 +0200 |
commit | 8d19e5e93a848deeda722b846c8dd1811018b9de (patch) | |
tree | f9899b45bbe36712bb6f8dda6e31e1a9d9481c3c /tests | |
parent | f7067ee52733c8561d0b13707d816aea307f6f94 (diff) | |
download | qtlocation-8d19e5e93a848deeda722b846c8dd1811018b9de.tar.gz |
Rename PlaceSaveReply to PlaceIdReply
The id reply is meant for operation in which we return an id
such as saving a place, removing a category etc.
The id reply has an operationType() property which tells us what
the operation was.
We don't use the QPlaceReply::type() to hold the operation type
because the reply type should indicate the contents of the reply,
eg the content reply holds place content, the search reply
holds search results therefore the id reply holds an id.
Change-Id: I3aa0b45c648186ee78297620896420966e42afa3
Reviewed-on: http://codereview.qt.nokia.com/4061
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Aaron McCarthy <aaron.mccarthy@nokia.com>
Reviewed-by: abcd <qt_abcd1@ovi.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/geotestplugin/qplacemanagerengine_test.h | 2 | ||||
-rw-r--r-- | tests/auto/qplacemanager_jsondb/tst_qplacemanager_jsondb.cpp | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/tests/auto/geotestplugin/qplacemanagerengine_test.h b/tests/auto/geotestplugin/qplacemanagerengine_test.h index 8e971e9a..120d85c3 100644 --- a/tests/auto/geotestplugin/qplacemanagerengine_test.h +++ b/tests/auto/geotestplugin/qplacemanagerengine_test.h @@ -130,7 +130,7 @@ public: return QPlaceManager::OnlineMode; } - QPlaceSaveReply *savePlace(const QGeoPlace &place, QPlaceManager::VisibilityScope scope) + QPlaceIdReply *savePlace(const QGeoPlace &place, QPlaceManager::VisibilityScope scope) { Q_UNUSED(place) Q_UNUSED(scope) diff --git a/tests/auto/qplacemanager_jsondb/tst_qplacemanager_jsondb.cpp b/tests/auto/qplacemanager_jsondb/tst_qplacemanager_jsondb.cpp index 1f2358a0..db05e061 100644 --- a/tests/auto/qplacemanager_jsondb/tst_qplacemanager_jsondb.cpp +++ b/tests/auto/qplacemanager_jsondb/tst_qplacemanager_jsondb.cpp @@ -45,7 +45,7 @@ Q_DECLARE_METATYPE(QPlaceReply::Error); Q_DECLARE_METATYPE(QPlaceReply *); -Q_DECLARE_METATYPE(QPlaceSaveReply *); +Q_DECLARE_METATYPE(QPlaceIdReply *); QT_USE_NAMESPACE @@ -110,7 +110,7 @@ void tst_QPlaceManagerJsonDb::initTestCase() { qRegisterMetaType<QPlaceReply::Error>(); qRegisterMetaType<QPlaceReply *>(); - qRegisterMetaType<QPlaceSaveReply *>(); + qRegisterMetaType<QPlaceIdReply *>(); QStringList providers = QGeoServiceProvider::availableServiceProviders(); providers.contains("nokia_places_jsondb"); @@ -649,17 +649,17 @@ bool tst_QPlaceManagerJsonDb::doSavePlace(const QGeoPlace &place, QString *placeId, QPlaceManager::VisibilityScope scope) { - QPlaceSaveReply *saveReply = placeManager->savePlace(place,scope); + QPlaceIdReply *saveReply = placeManager->savePlace(place,scope); bool isSuccessful = false; isSuccessful = checkSignals(saveReply, expectedError); if (placeId != 0) - *placeId = saveReply->placeId(); + *placeId = saveReply->id(); return isSuccessful; } void tst_QPlaceManagerJsonDb::doSavePlaces(QList<QGeoPlace> &places) { - QPlaceSaveReply *saveReply; + QPlaceIdReply *saveReply; foreach (QGeoPlace place, places) { saveReply = placeManager->savePlace(place); |