Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.4.0 Beta
-
None
-
Qt 5.4.0
MacOS X 10.10
-
9d1cd3098a066c7b6689d4776bfd3a25621a26fc
Description
QQuickRepeater::setModel calls ::clear which iterates all items from 0 to size and emites 'removed' signal for all of them.
The problem is that if we have 3 items the order of signals is the following:
1. removed(0);
2. removed(1);
3. removed(2); // Oops, size is 1 and we already don't have item at index 1
Looks like items have to be iterated in reverse order or removed signal argument should be fixed accordingly to current number of elements.
Attachments
For Gerrit Dashboard: QTBUG-42243 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
98901,3 | QQuickRepeater::clear: Remove items from the end backwards. | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |