Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.12.0
-
None
-
-
0af21b1f95180949f75ee2933d4147f610a29b6b (qt/qtlocation/5.12)
Description
In my project, I used nested MapItemView to show some map items. When running, it works ok. But App crashed when closing.
Here, show simple codes which can reproduce this problem.
import QtQuick 2.12 import QtQuick.Window 2.2 import QtLocation 5.12 import QtPositioning 5.12 Window { visible: true width: 640 height: 480 title: qsTr("Hello World") Plugin { id: mapPlugin name: "esri" // "mapboxgl", "esri", ... } Map { anchors.fill: parent plugin: mapPlugin //center: QtPositioning.coordinate(59.91, 10.75) // Oslo zoomLevel: 10 center: QtPositioning.coordinate(31, 116); ListModel { id: testModelaaa; ListElement{aa: "iii"} } ListModel { id: testModelbbb; ListElement{aa: "iii"} } Component { id: testCom; MapItemView { model: testModelbbb;//routeModel; delegate: MapCircle { visible: true; color: "red" radius: 10000; center: QtPositioning.coordinate(31, 116); Component.onCompleted: { console.log(testModelbbb.count) } } } } MapItemView { id: routeListView; model: testModelaaa; delegate: testCom Component.onCompleted: { console.log(testModelaaa.count) } } } }