diff options
-rw-r--r-- | dist/changes-5.13.2 | 20 | ||||
-rw-r--r-- | src/location/declarativemaps/qdeclarativegeomap.cpp | 39 | ||||
-rw-r--r-- | src/location/declarativemaps/qdeclarativegeomapitembase.cpp | 13 | ||||
-rw-r--r-- | src/location/declarativemaps/qdeclarativegeomapparameter.cpp | 14 | ||||
-rw-r--r-- | src/location/declarativemaps/qquickgeomapgesturearea.cpp | 2 | ||||
-rw-r--r-- | src/location/labs/qdeclarativenavigator.cpp | 3 | ||||
-rw-r--r-- | src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp | 2 | ||||
-rw-r--r-- | src/plugins/geoservices/osm/qplacesearchreplyosm.cpp | 2 | ||||
-rw-r--r-- | tests/auto/declarative_core/BLACKLIST | 6 |
9 files changed, 72 insertions, 29 deletions
diff --git a/dist/changes-5.13.2 b/dist/changes-5.13.2 new file mode 100644 index 00000000..e3bb833f --- /dev/null +++ b/dist/changes-5.13.2 @@ -0,0 +1,20 @@ +Qt 5.13.2 is a bug-fix release. It maintains both forward and backward +compatibility (source and binary) with Qt 5.13.0 through 5.13.1. + +For more details, refer to the online documentation included in this +distribution. The documentation is also available online: + +https://doc.qt.io/qt-5/index.html + +The Qt version 5.13 series is binary compatible with the 5.12.x series. +Applications compiled for 5.12 will continue to run with 5.13. + +Some of the changes listed in this file include issue tracking numbers +corresponding to tasks in the Qt Bug Tracker: + +https://bugreports.qt.io/ + +Each of these identifiers can be entered in the bug tracker to obtain more +information about a particular change. + + - This release contains only minor code improvements. diff --git a/src/location/declarativemaps/qdeclarativegeomap.cpp b/src/location/declarativemaps/qdeclarativegeomap.cpp index 1da71fb2..c3a87495 100644 --- a/src/location/declarativemaps/qdeclarativegeomap.cpp +++ b/src/location/declarativemaps/qdeclarativegeomap.cpp @@ -623,6 +623,15 @@ void QDeclarativeGeoMap::mappingManagerInitialized() if (!m_map) return; + // Any map items that were added before the plugin was ready + // need to have setMap called again + for (const QPointer<QDeclarativeGeoMapItemBase> &item : qAsConst(m_mapItems)) { + if (item) { + item->setMap(this, m_map); + m_map->addMapItem(item.data()); // m_map filters out what is not supported. + } + } + /* COPY NOTICE SETUP */ m_copyrights = new QDeclarativeGeoMapCopyrightNotice(this); m_copyrights->setCopyrightsZ(m_maxChildZ + 1); @@ -706,15 +715,6 @@ void QDeclarativeGeoMap::mappingManagerInitialized() emit supportedMapTypesChanged(); emit activeMapTypeChanged(); - // Any map items that were added before the plugin was ready - // need to have setMap called again - for (const QPointer<QDeclarativeGeoMapItemBase> &item : qAsConst(m_mapItems)) { - if (item) { - item->setMap(this, m_map); - m_map->addMapItem(item.data()); // m_map filters out what is not supported. - } - } - // Any map item groups that were added before the plugin was ready // DO NOT need to have setMap called again on their children map items // because they have been added to m_mapItems, which is processed right above. @@ -1436,6 +1436,14 @@ void QDeclarativeGeoMap::setVisibleArea(const QRectF &visibleArea) if (m_initialized) { m_map->setVisibleArea(visibleArea); + const QRectF newVisibleArea = QDeclarativeGeoMap::visibleArea(); + if (newVisibleArea != oldVisibleArea) { + // polish map items + for (const QPointer<QDeclarativeGeoMapItemBase> &i: qAsConst(m_mapItems)) { + if (i) + i->visibleAreaChanged(); + } + } } else { m_visibleArea = visibleArea; const QRectF newVisibleArea = QDeclarativeGeoMap::visibleArea(); @@ -1757,6 +1765,11 @@ void QDeclarativeGeoMap::onCameraDataChanged(const QGeoCameraData &cameraData) bool zoomHasChanged = cameraData.zoomLevel() != m_cameraData.zoomLevel(); m_cameraData = cameraData; + // polish map items + for (const QPointer<QDeclarativeGeoMapItemBase> &i: qAsConst(m_mapItems)) { + if (i) + i->baseCameraDataChanged(m_cameraData); // Consider optimizing this further, removing the contained duplicate if conditions. + } if (centerHasChanged) emit centerChanged(m_cameraData.center()); @@ -2241,7 +2254,13 @@ void QDeclarativeGeoMap::geometryChanged(const QRectF &newGeometry, const QRectF QGeoCoordinate coord = cameraData.center(); coord.setLatitude(qBound(m_minimumViewportLatitude, coord.latitude(), m_maximumViewportLatitude)); cameraData.setCenter(coord); - m_map->setCameraData(cameraData); + m_map->setCameraData(cameraData); // this polishes map items + } else if (oldGeometry.size() != newGeometry.size()) { + // polish map items + for (const QPointer<QDeclarativeGeoMapItemBase> &i: qAsConst(m_mapItems)) { + if (i) + i->polishAndUpdate(); + } } } diff --git a/src/location/declarativemaps/qdeclarativegeomapitembase.cpp b/src/location/declarativemaps/qdeclarativegeomapitembase.cpp index 9a2ae50b..23993faf 100644 --- a/src/location/declarativemaps/qdeclarativegeomapitembase.cpp +++ b/src/location/declarativemaps/qdeclarativegeomapitembase.cpp @@ -126,21 +126,14 @@ void QDeclarativeGeoMapItemBase::setMap(QDeclarativeGeoMap *quickMap, QGeoMap *m return; if (quickMap && quickMap_) return; // don't allow association to more than one map - if (quickMap_) - quickMap_->disconnect(this); - if (map_) - map_->disconnect(this); quickMap_ = quickMap; map_ = map; if (map_ && quickMap_) { - connect(map_, SIGNAL(cameraDataChanged(QGeoCameraData)), - this, SLOT(baseCameraDataChanged(QGeoCameraData))); - connect(map_, SIGNAL(visibleAreaChanged()), - this, SLOT(visibleAreaChanged())); - connect(quickMap, SIGNAL(heightChanged()), this, SLOT(polishAndUpdate())); - connect(quickMap, SIGNAL(widthChanged()), this, SLOT(polishAndUpdate())); + // For performance reasons we're not connecting map_'s and quickMap_'s signals to this. + // Rather, the handling of cameraDataChanged, visibleAreaChanged, heightChanged and widthChanged is done explicitly in QDeclarativeGeoMap by directly calling methods on the items. + // See QTBUG-76950 lastSize_ = QSizeF(quickMap_->width(), quickMap_->height()); lastCameraData_ = map_->cameraData(); } diff --git a/src/location/declarativemaps/qdeclarativegeomapparameter.cpp b/src/location/declarativemaps/qdeclarativegeomapparameter.cpp index 2408e1c7..77a78aee 100644 --- a/src/location/declarativemaps/qdeclarativegeomapparameter.cpp +++ b/src/location/declarativemaps/qdeclarativegeomapparameter.cpp @@ -68,7 +68,7 @@ Q_SIGNALS: \since QtLocation 5.9 \deprecated - Use \l DynamicParameter instead. + This type is deprecated and has been remamed into \l DynamicParameter. */ /*! @@ -78,9 +78,11 @@ Q_SIGNALS: \ingroup qml-QtLocation5-maps \since Qt Location 5.11 - \brief The DynamicParameter type represents a parameter for a Map element. - This type provides a mean to specify plugin-dependent optional parameters - for a map. + \brief The DynamicParameter (previously \l MapParameter ) type represents a parameter for a Map element, + or other elements used in a Map (such as map items, etc.). + This type provides a mean to specify plugin-dependent optional dynamic parameters that allow a plugin to + extend the runtime API of the module. + DynamicParameters by default contain only the \l type property, and are highly plugin-dependent. @@ -89,8 +91,8 @@ Q_SIGNALS: What properties have to be put inside a particular DynamicParameter type for a particular plugin can be found in the documentation of the plugin. - Note that DynamicParameters are \b optional. - By not specifying any of them, the Map will have the default behavior. + \note DynamicParameters are \b optional. + By not specifying any of them, the Map, or other container elements, will have the default behavior. */ /*! diff --git a/src/location/declarativemaps/qquickgeomapgesturearea.cpp b/src/location/declarativemaps/qquickgeomapgesturearea.cpp index a33db67a..a9406ff4 100644 --- a/src/location/declarativemaps/qquickgeomapgesturearea.cpp +++ b/src/location/declarativemaps/qquickgeomapgesturearea.cpp @@ -401,7 +401,7 @@ QT_BEGIN_NAMESPACE starts from the point where the mouse or touch was released, while still in motion. - The corresponding handler is \c onFlichStarted. + The corresponding handler is \c onFlickStarted. */ /*! diff --git a/src/location/labs/qdeclarativenavigator.cpp b/src/location/labs/qdeclarativenavigator.cpp index b266779c..a4caca85 100644 --- a/src/location/labs/qdeclarativenavigator.cpp +++ b/src/location/labs/qdeclarativenavigator.cpp @@ -590,6 +590,7 @@ QDeclarativeNavigationBasicDirections::QDeclarativeNavigationBasicDirections(QDe \qmlproperty Route Qt.labs.location::Navigator::directions.currentRoute \qmlproperty RouteLeg Qt.labs.location::Navigator::directions.currentRouteLeg \qmlproperty int Qt.labs.location::Navigator::directions.currentSegment + \qmlproperty model Qt.labs.location::Navigator::directions.alternativeRoutes These read-only properties are part of the \e directions property group. This property group holds the navigation progress information that can be @@ -628,6 +629,8 @@ QDeclarativeNavigationBasicDirections::QDeclarativeNavigationBasicDirections(QDe holds the same route as \c currentRoute. \li The \c currentSegment property holds the index of the current RouteSegment in the \c currentRoute. + \li The \c alternativeRoutes property holds the list of alternative routes provided by + the engine. If no alternative routes are present, the model will be empty. \endlist \sa directions.waypointReached(), directions.destinationReached(), Route, RouteLeg, RouteSegment, Waypoint diff --git a/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp b/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp index b0967499..9c088f2f 100644 --- a/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp +++ b/src/plugins/geoservices/mapboxgl/qgeomapmapboxgl.cpp @@ -234,7 +234,7 @@ void QGeoMapMapboxGLPrivate::addMapItem(QDeclarativeGeoMapItemBase *item) QObject::connect(mapItem, &QQuickItem::visibleChanged, q, &QGeoMapMapboxGL::onMapItemPropertyChanged); QObject::connect(mapItem, &QDeclarativeGeoMapItemBase::mapItemOpacityChanged, q, &QGeoMapMapboxGL::onMapItemPropertyChanged); QObject::connect(mapItem, &QDeclarativePolygonMapItem::pathChanged, q, &QGeoMapMapboxGL::onMapItemGeometryChanged); - QObject::connect(mapItem, &QDeclarativePolygonMapItem::colorChanged, q, &QGeoMapMapboxGL::onMapItemGeometryChanged); + QObject::connect(mapItem, &QDeclarativePolygonMapItem::colorChanged, q, &QGeoMapMapboxGL::onMapItemPropertyChanged); QObject::connect(mapItem->border(), &QDeclarativeMapLineProperties::colorChanged, q, &QGeoMapMapboxGL::onMapItemSubPropertyChanged); QObject::connect(mapItem->border(), &QDeclarativeMapLineProperties::widthChanged, q, &QGeoMapMapboxGL::onMapItemUnsupportedPropertyChanged); } break; diff --git a/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp b/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp index d65b0735..366ff852 100644 --- a/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp +++ b/src/plugins/geoservices/osm/qplacesearchreplyosm.cpp @@ -184,7 +184,7 @@ QPlaceResult QPlaceSearchReplyOsm::parsePlaceResult(const QJsonObject &item) con //double importance = item.value(QStringLiteral("importance")).toDouble(); place.setAttribution(item.value(QStringLiteral("licence")).toString()); - place.setPlaceId(item.value(QStringLiteral("place_id")).toString()); + place.setPlaceId(QString::number(item.value(QStringLiteral("place_id")).toInt())); QVariantMap iconParameters; iconParameters.insert(QPlaceIcon::SingleUrl, diff --git a/tests/auto/declarative_core/BLACKLIST b/tests/auto/declarative_core/BLACKLIST new file mode 100644 index 00000000..99b4d786 --- /dev/null +++ b/tests/auto/declarative_core/BLACKLIST @@ -0,0 +1,6 @@ +# QTBUG-59074 flaky test +[CoordinateAnimation::test_west_direction_coordinate_animation] +osx +# QTBUG-59074 flaky test +[CoordinateAnimation::test_east_direction_coordinate_animation] +osx |