summaryrefslogtreecommitdiff
path: root/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
diff options
context:
space:
mode:
authorPaolo Angelelli <paolo.angelelli@qt.io>2019-01-21 15:50:52 +0100
committerPaolo Angelelli <paolo.angelelli@qt.io>2019-01-29 18:56:52 +0000
commit1ac41150501d3c5cc4a9a6ed9c93729687666553 (patch)
tree885594e1dca7cfe9c739fd036c108d4ab0d9bf07 /src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
parentdba67b9f0130dd680dc728524323af664158e230 (diff)
downloadqtlocation-1ac41150501d3c5cc4a9a6ed9c93729687666553.tar.gz
Fix crash when removing items from MapboxGL maps
Triggered by usage of a virtual method in superclass destructor. Change-Id: If99e523e42fd13686ae43c0083a74e1b68221fc7 Fixes: QTBUG-67638 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'src/location/declarativemaps/qdeclarativegeomapquickitem.cpp')
-rw-r--r--src/location/declarativemaps/qdeclarativegeomapquickitem.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp b/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
index 5f9ecc8a..f7409788 100644
--- a/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
+++ b/src/location/declarativemaps/qdeclarativegeomapquickitem.cpp
@@ -135,6 +135,7 @@ QDeclarativeGeoMapQuickItem::QDeclarativeGeoMapQuickItem(QQuickItem *parent)
: QDeclarativeGeoMapItemBase(parent), zoomLevel_(0.0),
mapAndSourceItemSet_(false), updatingGeometry_(false), matrix_(nullptr)
{
+ m_itemType = QGeoMap::MapQuickItem;
setFlag(ItemHasContents, true);
opacityContainer_ = new QQuickItem(this);
opacityContainer_->setParentItem(this);
@@ -362,11 +363,6 @@ void QDeclarativeGeoMapQuickItem::setGeoShape(const QGeoShape &shape)
}
-QGeoMap::ItemType QDeclarativeGeoMapQuickItem::itemType() const
-{
- return QGeoMap::MapQuickItem;
-}
-
/*!
\internal
*/