diff options
author | Paolo Angelelli <paolo.angelelli@qt.io> | 2019-04-10 22:57:45 +0200 |
---|---|---|
committer | paolo <paolo.angelelli@qt.io> | 2019-06-21 22:56:05 +0200 |
commit | 6ddffc8a4eb50164389c55c2ddad9239dab07b8c (patch) | |
tree | c0208a549f972e514a0987849f123394048694ef /src/imports | |
parent | ac899dcc40bb3ad09307583fb7e6befd45a77b33 (diff) | |
download | qtlocation-6ddffc8a4eb50164389c55c2ddad9239dab07b8c.tar.gz |
Move PluginParameter into PositioningQuick, expose also in QtPositioning
With this patch the QDeclarativeGeoServiceProviderParameter in the
location-private module becomes QDeclarativePluginParameter in the
positioningquick-private module.
This renamed class is then registered, under the same QML typename
"PluginParameter" both in QtPositioning and QtLocation qml plugins.
In this way it will become possible to use the same type both inside
QtLocation "Plugin" and inside QtPositioning "PositionSource",
and regardless of which is the QML plugin that provides
"PluginParameter", this will translate into the same cpp type.
[ChangeLog][QtPositioning] Exposed PluginParameter also from
QtPositioning qml plugin, to be used in PositionSource as replacement
of environment variables.
Task-number: QTBUG-66304
Change-Id: I1d982ff689130ae896c616480567aa12d9b49c3a
Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/imports')
-rw-r--r-- | src/imports/location/location.cpp | 3 | ||||
-rw-r--r-- | src/imports/location/location.pro | 2 | ||||
-rw-r--r-- | src/imports/positioning/positioning.cpp | 7 |
3 files changed, 8 insertions, 4 deletions
diff --git a/src/imports/location/location.cpp b/src/imports/location/location.cpp index 422b4c72..fccb628d 100644 --- a/src/imports/location/location.cpp +++ b/src/imports/location/location.cpp @@ -35,6 +35,7 @@ ****************************************************************************/ #include <QtLocation/private/qdeclarativegeoserviceprovider_p.h> +#include <QtPositioningQuick/private/qdeclarativepluginparameter_p.h> #include <QtLocation/private/qdeclarativegeomap_p.h> #include <QtLocation/private/qdeclarativegeoroute_p.h> @@ -97,7 +98,7 @@ public: // 5.0 is silent and not advertised qmlRegisterType<QDeclarativeGeoServiceProvider >(uri, major, minor, "Plugin"); - qmlRegisterType<QDeclarativeGeoServiceProviderParameter >(uri, major, minor, "PluginParameter"); + qmlRegisterType<QDeclarativePluginParameter >(uri, major, minor, "PluginParameter"); qmlRegisterUncreatableType<QDeclarativeGeoServiceProviderRequirements>(uri, major, minor, "PluginRequirements", QStringLiteral("PluginRequirements is not intended instantiable by developer.")); qmlRegisterType<QDeclarativeGeoMap >(uri, major, minor, "Map"); diff --git a/src/imports/location/location.pro b/src/imports/location/location.pro index dec1149b..40605806 100644 --- a/src/imports/location/location.pro +++ b/src/imports/location/location.pro @@ -1,4 +1,4 @@ -QT += quick-private network positioning-private location-private qml-private core-private gui-private +QT += quick-private network positioning-private positioningquick-private location-private qml-private core-private gui-private SOURCES += \ location.cpp diff --git a/src/imports/positioning/positioning.cpp b/src/imports/positioning/positioning.cpp index 4349f63b..38b9378a 100644 --- a/src/imports/positioning/positioning.cpp +++ b/src/imports/positioning/positioning.cpp @@ -41,9 +41,9 @@ #include <QtPositioningQuick/private/qdeclarativegeoaddress_p.h> #include <QtPositioningQuick/private/qdeclarativegeolocation_p.h> #include <QtPositioning/private/qwebmercator_p.h> - -#include <QtPositioningQuick/private/qdeclarativepositionsource_p.h> #include <QtPositioningQuick/private/qdeclarativeposition_p.h> +#include <QtPositioningQuick/private/qdeclarativepositionsource_p.h> +#include <QtPositioningQuick/private/qdeclarativepluginparameter_p.h> #include <QtPositioningQuick/private/qquickgeocoordinateanimation_p.h> #include "locationsingleton.h" @@ -616,6 +616,9 @@ public: minor = 13; qmlRegisterType<QDeclarativeGeoLocation, 13>(uri, major, minor, "Location"); + minor = 14; + qmlRegisterType<QDeclarativePluginParameter >(uri, major, minor, "PluginParameter"); + // Register the latest Qt version as QML type version qmlRegisterModule(uri, QT_VERSION_MAJOR, QT_VERSION_MINOR); } else { |