diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2018-06-28 10:45:16 +0200 |
---|---|---|
committer | Paolo Angelelli <paolo.angelelli@qt.io> | 2018-08-24 11:54:22 +0000 |
commit | 0a6315b7a2a00d56a101c4a2ea165242d356e024 (patch) | |
tree | c7b9a313f4e001d243d7b796129894b026a53be2 /src/imports/location | |
parent | 34ee76720ee09ac692ea149ce44413cb5c0c7b99 (diff) | |
download | qtlocation-0a6315b7a2a00d56a101c4a2ea165242d356e024.tar.gz |
Add support for route legs
This patch adds support for route legs, that are the portions
of a route between one waypoint and the next.
QGeoRouteLeg in particular can be seen as an API addition
to QGeoRoute in that it uses and exposes additional methods
added to QGeoRoutePrivate but not used in QGeoRoute.
Currently the request for legs is set to be the same
as the request for the entire route.
Finding the related bounding waypoints has to be done
programmatically using the legIndex property.
Change-Id: If462b1dc6348be16dc96b167db5500f079fe0a64
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/imports/location')
-rw-r--r-- | src/imports/location/location.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/imports/location/location.cpp b/src/imports/location/location.cpp index 62debb1d..2c2331bf 100644 --- a/src/imports/location/location.cpp +++ b/src/imports/location/location.cpp @@ -191,6 +191,8 @@ public: qmlRegisterType<QDeclarativeGeoMapItemView, 12>(uri, major, minor, "MapItemView"); qmlRegisterType<QDeclarativeSearchResultModel, 12>(uri, major, minor, "PlaceSearchModel"); qmlRegisterType<QDeclarativeGeoMap, 12>(uri, major, minor, "Map"); + qmlRegisterType<QDeclarativeGeoRoute, 12>(uri, major, minor, "Route"); + qmlRegisterType<QDeclarativeGeoRouteLeg, 12>(uri, major, minor, "RouteLeg"); // Register the latest Qt version as QML type version qmlRegisterModule(uri, QT_VERSION_MAJOR, QT_VERSION_MINOR); |