Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.10.1
Description
Problem
When a Repeater model is refreshed and the repeated item has states, then we have a memory leak.
Reproduce
Execute and watch the memory grow:
import QtQuick 2.10 import QtQuick.Window 2.10 import QtQuick.Controls 2.3 Window { visible: true Repeater { id: repeater model: range(1, 1000) Label { id: label text: modelData states: State { PropertyChanges { target: label } } } } function range(min, max) { var list = []; for (var i = min; i <= max; i++) { list.push(i); } return list; } Timer { running: true repeat: true interval: 1 onTriggered: { repeater.model = repeater.model.reverse() } } }