summaryrefslogtreecommitdiffstats
path: root/doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp
diff options
context:
space:
mode:
authorabcd <qt-info@nokia.com>2010-08-10 15:09:18 +1000
committerabcd <qt-info@nokia.com>2010-08-10 15:09:18 +1000
commitdb31fd2f853d6e85c55570377fc9b71171f244c9 (patch)
tree09fd6e4ede808447f964c667afeb5edfbfa08c73 /doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp
parentaad22ed0635fe50f85bd41b9d61013b896e9703f (diff)
Change order of paging and sort order parameters
For landmarks sort orders are unlikely to be used since the most important use case would be to show landmarks on a map
Diffstat (limited to 'doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp')
-rw-r--r--doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp b/doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp
index e6ce005262..5e8ba68626 100644
--- a/doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp
+++ b/doc/src/snippets/qtlandmarksdocsample/qtlandmarksdocsample.cpp
@@ -362,7 +362,7 @@ void landmarkFetch(QLandmarkManager *lm)
//retrieval via ids
QList<QLandmarkId> landmarkIds;
QLandmarkNameSort sortOrder(Qt::AscendingOrder);
- landmarkIds = lm->landmarkIds(filter, sortOrder);
+ landmarkIds = lm->landmarkIds(filter, -1, 0, sortOrder);
foreach(QLandmarkId id, landmarkIds) {
qDebug() << "Found landmark:" << lm->landmark(id).name();
}
@@ -370,7 +370,7 @@ void landmarkFetch(QLandmarkManager *lm)
//! [Retrieve landmarks synchronously]
QList<QLandmark> landmarks;
- landmarks = lm->landmarks(filter, sortOrder);
+ landmarks = lm->landmarks(filter, -1, 0, sortOrder);
foreach(QLandmark landmark, landmarks) {
qDebug() << "Found landmark:" << landmark.name();
}
@@ -388,7 +388,7 @@ void landmarkFetch(QLandmarkManager *lm)
QLandmarkNameSort nameSort;
nameSort.setDirection(Qt::AscendingOrder);
- landmarkManager->landmarks(filter, sortOrder, 5);
+ landmarkManager->landmarks(filter, 5, 0, sortOrder);
//! [Retrieve landmarks by proximity synchronously]
//! [Retrieve all landmarks synchronously]
@@ -415,7 +415,7 @@ void filterByProximity(QLandmarkManager *lm)
QGeoCoordinate origin(41,74);
QLandmarkProximityFilter filter(origin, 5000);
QLandmarkNameSort sort(Qt::AscendingOrder);
- QList<QLandmarkId> matchingIds = lm->landmarkIds(filter, sort);
+ QList<QLandmarkId> matchingIds = lm->landmarkIds(filter, -1, 0, sort);
if(matchingIds.count() == 0) {
qDebug() << "No matches found";