diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2017-12-21 17:24:27 +0100 |
---|---|---|
committer | Paolo Angelelli <paolo.angelelli@qt.io> | 2018-01-10 17:31:34 +0000 |
commit | 0c00f73cebfcfe4308d46c67a6f3345886b9bccb (patch) | |
tree | 907c2518b68b88d00cdca2f34366dfa0504468c9 /src/plugins/geoservices/osm/qplacesearchreplyosm.cpp | |
parent | 8014727e52c65bf6496ad4adf6c8e7ec33250bb7 (diff) | |
download | qtlocation-0c00f73cebfcfe4308d46c67a6f3345886b9bccb.tar.gz |
Add debug parameter to OSM plugin to include the request url in results
Change-Id: Ib2c0ba380ed6f5eecc7eb6bec75037a4922a567f
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/plugins/geoservices/osm/qplacesearchreplyosm.cpp')
-rw-r--r-- | src/plugins/geoservices/osm/qplacesearchreplyosm.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp b/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp index cdb696dd..0228a975 100644 --- a/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp +++ b/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp @@ -192,6 +192,13 @@ QPlaceResult QPlaceSearchReplyOsm::parsePlaceResult(const QJsonObject &item) con place.setName(title); + if (!requestUrl.isEmpty()) { + QPlaceAttribute attribute; + attribute.setLabel("requestUrl"); + attribute.setText(requestUrl); + place.setExtendedAttribute("requestUrl", attribute); + } + QGeoAddress address; address.setCity(addressDetails.value(QStringLiteral("city")).toString()); address.setCountry(addressDetails.value(QStringLiteral("country")).toString()); |