diff options
| author | abcd <qt-info@nokia.com> | 2010-08-04 19:47:13 +1000 |
|---|---|---|
| committer | abcd <qt-info@nokia.com> | 2010-08-04 19:47:13 +1000 |
| commit | f73b9155e7995e510711d57b629fd8efcdcc7b51 (patch) | |
| tree | ae2b0e877d71e15200f87436cf8daac3f834e383 | |
| parent | e484e65d50ad4a2f667caf666bf06caff7bb88c6 (diff) | |
Revert "Remove platform attributes."
This reverts commit c97747cea2a2627f6912658677f38ca3aaabed7f.
| -rw-r--r-- | plugins/landmarks/sqlite/qlandmarkmanagerengine_sqlite.cpp | 20 | ||||
| -rw-r--r-- | src/location/landmarks/qlandmarkmanager.cpp | 23 | ||||
| -rw-r--r-- | src/location/landmarks/qlandmarkmanager.h | 3 | ||||
| -rw-r--r-- | src/location/landmarks/qlandmarkmanagerengine.h | 3 |
4 files changed, 49 insertions, 0 deletions
diff --git a/plugins/landmarks/sqlite/qlandmarkmanagerengine_sqlite.cpp b/plugins/landmarks/sqlite/qlandmarkmanagerengine_sqlite.cpp index b79c468b5b..bccf12dd1e 100644 --- a/plugins/landmarks/sqlite/qlandmarkmanagerengine_sqlite.cpp +++ b/plugins/landmarks/sqlite/qlandmarkmanagerengine_sqlite.cpp @@ -3509,6 +3509,8 @@ bool QLandmarkManagerEngineSqlite::isFeatureSupported(QLandmarkManager::Landmark switch(feature) { case (QLandmarkManager::GenericLandmarkAttributes): case (QLandmarkManager::GenericCategoryAttributes): + case (QLandmarkManager::PlatformLandmarkAttributes): + case (QLandmarkManager::PlatformCategoryAttributes): return false; break; default: @@ -3516,6 +3518,24 @@ bool QLandmarkManagerEngineSqlite::isFeatureSupported(QLandmarkManager::Landmark } } +QStringList QLandmarkManagerEngineSqlite::platformLandmarkAttributeKeys(QLandmarkManager::Error *error, QString *errorString) const +{ + Q_ASSERT(error); + Q_ASSERT(errorString); + *error = QLandmarkManager::NoError; + *errorString = ""; + return QStringList(); +} + +QStringList QLandmarkManagerEngineSqlite::platformCategoryAttributeKeys(QLandmarkManager::Error *error, QString *errorString) const +{ + Q_ASSERT(error); + Q_ASSERT(errorString); + *error = QLandmarkManager::NoError; + *errorString = ""; + return QStringList(); +} + bool QLandmarkManagerEngineSqlite::isReadOnly(QLandmarkManager::Error *error, QString *errorString) const { Q_ASSERT(error); diff --git a/src/location/landmarks/qlandmarkmanager.cpp b/src/location/landmarks/qlandmarkmanager.cpp index 83271229cb..661cb32e23 100644 --- a/src/location/landmarks/qlandmarkmanager.cpp +++ b/src/location/landmarks/qlandmarkmanager.cpp @@ -855,6 +855,29 @@ QLandmarkManager::FilterSupportLevel QLandmarkManager::filterSupportLevel(const return d->engine->filterSupportLevel(filter, &(d->errorCode), &(d->errorString)); } +QStringList QLandmarkManager::platformLandmarkAttributeKeys() const +{ + Q_D(const QLandmarkManager); + + if (!d->engine) { + d->errorCode = QLandmarkManager::InvalidManagerError; + d->errorString = QString("Invalid Manager"); + } + + return d->engine->platformLandmarkAttributeKeys(&(d->errorCode), &(d->errorString)); +} + +QStringList QLandmarkManager::platformCategoryAttributeKeys() const +{ + Q_D(const QLandmarkManager); + + if (!d->engine) { + d->errorCode = QLandmarkManager::InvalidManagerError; + d->errorString = QString("Invalid Manager"); + } + return d->engine->platformCategoryAttributeKeys(&(d->errorCode), &(d->errorString)); +} + /*! Returns true if the manager is entirely read-only. Meaning landmarks and categories cannot be added, modified or removed. diff --git a/src/location/landmarks/qlandmarkmanager.h b/src/location/landmarks/qlandmarkmanager.h index abe7909128..dfc2107e34 100644 --- a/src/location/landmarks/qlandmarkmanager.h +++ b/src/location/landmarks/qlandmarkmanager.h @@ -148,6 +148,9 @@ public: FilterSupportLevel filterSupportLevel(const QLandmarkFilter &filter) const; bool isFeatureSupported(LandmarkFeature feature) const; + QStringList platformLandmarkAttributeKeys() const; + QStringList platformCategoryAttributeKeys() const; + bool isReadOnly() const; bool isReadOnly(const QLandmarkId &id) const; bool isReadOnly(const QLandmarkCategoryId &id) const; diff --git a/src/location/landmarks/qlandmarkmanagerengine.h b/src/location/landmarks/qlandmarkmanagerengine.h index 905790dcd5..86613ed0f6 100644 --- a/src/location/landmarks/qlandmarkmanagerengine.h +++ b/src/location/landmarks/qlandmarkmanagerengine.h @@ -136,6 +136,9 @@ public: virtual bool isReadOnly(const QLandmarkId &landmarkId, QLandmarkManager::Error *error, QString *errorString) const = 0; virtual bool isReadOnly(const QLandmarkCategoryId &categoryId, QLandmarkManager::Error *error, QString *errorString) const = 0; + virtual QStringList platformLandmarkAttributeKeys(QLandmarkManager::Error *error, QString *errorString) const = 0; + virtual QStringList platformCategoryAttributeKeys(QLandmarkManager::Error *error, QString *errorString) const = 0; + /* Asynchronous Request Support */ virtual void requestDestroyed(QLandmarkAbstractRequest* request) = 0; virtual bool startRequest(QLandmarkAbstractRequest* request) = 0; |
