summaryrefslogtreecommitdiff
path: root/src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp
diff options
context:
space:
mode:
authorAaron McCarthy <aaron.mccarthy@jollamobile.com>2014-01-16 14:32:21 +1000
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-20 02:11:24 +0100
commit1d0966c6924876655c52725e779a7aa24866ff60 (patch)
treebb7220ab3ccce1d057b80af33dbb8dd784d5782e /src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp
parent86db3df8cea7b9ac1e4ae078639de5fb5a43ca69 (diff)
downloadqtlocation-1d0966c6924876655c52725e779a7aa24866ff60.tar.gz
Remove offset attribute from place search requests.
Not all service providers support arbitrary search offsets. The offset attribute has been removed, instead service providers can supply a previous and next search query in the form of a QPlaceSearchRequest. Change-Id: If68e969b06f909f3fa62718656cbef70d1bf84a6 Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
Diffstat (limited to 'src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp')
-rw-r--r--src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp10
1 files changed, 0 insertions, 10 deletions
diff --git a/src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp b/src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp
index 0d2d3953..c0b265d2 100644
--- a/src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp
+++ b/src/plugins/geoservices/nokia/qplacemanagerengine_nokiav2.cpp
@@ -379,8 +379,6 @@ QPlaceSearchReply *QPlaceManagerEngineNokiaV2::search(const QPlaceSearchRequest
unsupported |= query.visibilityScope() != QLocation::UnspecifiedVisibility &&
query.visibilityScope() != QLocation::PublicVisibility;
- unsupported |= !query.searchTerm().isEmpty() && query.offset() > 0;
-
// Both a search term and search categories are not supported.
unsupported |= !query.searchTerm().isEmpty() && !query.categories().isEmpty();
@@ -432,9 +430,6 @@ QPlaceSearchReply *QPlaceManagerEngineNokiaV2::search(const QPlaceSearchRequest
if (query.limit() > 0)
queryItems.addQueryItem(QStringLiteral("size"), QString::number(query.limit()));
- if (query.offset() > -1)
- queryItems.addQueryItem(QStringLiteral("offset"), QString::number(query.offset()));
-
u.setQuery(queryItems);
networkReply = sendRequest(u);
@@ -493,10 +488,6 @@ QPlaceSearchReply *QPlaceManagerEngineNokiaV2::search(const QPlaceSearchRequest
queryItems.addQueryItem(QLatin1String("size"),
QString::number(query.limit()));
}
- if (query.offset() > -1) {
- queryItems.addQueryItem(QLatin1String("offset"),
- QString::number(query.offset()));
- }
requestUrl.setQuery(queryItems);
@@ -518,7 +509,6 @@ QPlaceSearchSuggestionReply *QPlaceManagerEngineNokiaV2::searchSuggestions(const
unsupported |= query.visibilityScope() != QLocation::UnspecifiedVisibility &&
query.visibilityScope() != QLocation::PublicVisibility;
- unsupported |= query.offset() > 0;
unsupported |= !query.categories().isEmpty();
unsupported |= !query.recommendationId().isEmpty();