summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Angelelli <paolo.angelelli@qt.io>2017-05-30 16:51:15 +0200
committerPaolo Angelelli <paolo.angelelli@qt.io>2017-06-07 11:13:08 +0000
commit9e566cc5035493a7be8f7496bed57fe6e4060b2d (patch)
tree0102289ab1ae3c725e4593df810ecfe5fd23acf0
parente8dedcd7c621715813b7b954bb7f64c88aa6523d (diff)
downloadqtlocation-9e566cc5035493a7be8f7496bed57fe6e4060b2d.tar.gz
Add TrafficFeature to QGeoRouteRequest/RouteQuery
[ChangeLog][QtLocation][QGeoRouteRequest/RouteQuery] Add TrafficFeature to the query features. Change-Id: I50243865da97e302943f43b0eda430e9d8383880 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
-rw-r--r--src/location/declarativemaps/qdeclarativegeoroutemodel.cpp1
-rw-r--r--src/location/declarativemaps/qdeclarativegeoroutemodel_p.h3
-rw-r--r--src/location/maps/qgeorouterequest.cpp2
-rw-r--r--src/location/maps/qgeorouterequest.h3
-rw-r--r--src/plugins/geoservices/nokia/qgeoroutingmanagerengine_nokia.cpp1
5 files changed, 8 insertions, 2 deletions
diff --git a/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp b/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp
index 94bd63c8..0383c0c4 100644
--- a/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp
+++ b/src/location/declarativemaps/qdeclarativegeoroutemodel.cpp
@@ -722,6 +722,7 @@ void QDeclarativeGeoRouteQuery::componentComplete()
\li RouteQuery.DirtRoadFeature - Consider dirt roads when planning the route
\li RouteQuery.ParksFeature - Consider parks when planning the route
\li RouteQuery.MotorPoolLaneFeature - Consider motor pool lanes when planning the route
+ \li RouteQuery.TrafficFeature - Consider traffic when planning the route
\endlist
\sa setFeatureWeight, featureWeight
diff --git a/src/location/declarativemaps/qdeclarativegeoroutemodel_p.h b/src/location/declarativemaps/qdeclarativegeoroutemodel_p.h
index 3dfd2ce6..18486ac8 100644
--- a/src/location/declarativemaps/qdeclarativegeoroutemodel_p.h
+++ b/src/location/declarativemaps/qdeclarativegeoroutemodel_p.h
@@ -238,7 +238,8 @@ public:
TunnelFeature = QGeoRouteRequest::TunnelFeature,
DirtRoadFeature = QGeoRouteRequest::DirtRoadFeature,
ParksFeature = QGeoRouteRequest::ParksFeature,
- MotorPoolLaneFeature = QGeoRouteRequest::MotorPoolLaneFeature
+ MotorPoolLaneFeature = QGeoRouteRequest::MotorPoolLaneFeature,
+ TrafficFeature = QGeoRouteRequest::TrafficFeature
};
Q_DECLARE_FLAGS(FeatureTypes, FeatureType)
diff --git a/src/location/maps/qgeorouterequest.cpp b/src/location/maps/qgeorouterequest.cpp
index 753d2ee9..a1b32d85 100644
--- a/src/location/maps/qgeorouterequest.cpp
+++ b/src/location/maps/qgeorouterequest.cpp
@@ -134,6 +134,8 @@ QT_BEGIN_NAMESPACE
Consider parks when planning the route.
\value MotorPoolLaneFeature
Consider motor pool lanes when planning the route.
+ \value TrafficFeature
+ Consider the current traffic situation when planning the route. Since QtLocation 5.10
*/
/*!
diff --git a/src/location/maps/qgeorouterequest.h b/src/location/maps/qgeorouterequest.h
index 6fcc7ad3..cf89d13d 100644
--- a/src/location/maps/qgeorouterequest.h
+++ b/src/location/maps/qgeorouterequest.h
@@ -70,7 +70,8 @@ public:
TunnelFeature = 0x00000010,
DirtRoadFeature = 0x00000020,
ParksFeature = 0x00000040,
- MotorPoolLaneFeature = 0x00000080
+ MotorPoolLaneFeature = 0x00000080,
+ TrafficFeature = 0x00000100
};
Q_DECLARE_FLAGS(FeatureTypes, FeatureType)
diff --git a/src/plugins/geoservices/nokia/qgeoroutingmanagerengine_nokia.cpp b/src/plugins/geoservices/nokia/qgeoroutingmanagerengine_nokia.cpp
index a33d1ba8..d7e4cf8d 100644
--- a/src/plugins/geoservices/nokia/qgeoroutingmanagerengine_nokia.cpp
+++ b/src/plugins/geoservices/nokia/qgeoroutingmanagerengine_nokia.cpp
@@ -360,6 +360,7 @@ QString QGeoRoutingManagerEngineNokia::modesRequestString(const QGeoRouteRequest
case QGeoRouteRequest::PublicTransitFeature:
case QGeoRouteRequest::ParksFeature:
case QGeoRouteRequest::MotorPoolLaneFeature:
+ case QGeoRouteRequest::TrafficFeature:
case QGeoRouteRequest::NoFeature:
break;
}