on xenial help sign in
LVWPH: cull lost items
7dc5cc4Albert Astals
plugins/DashViews/listviewwithpageheader.cpp+1
@@ -847,6 +847,7 @@ ListViewWithPageHeader::ListItem *ListViewWithPageHeader::createItem(int modelIn
847 }
847 }
848 }
848 }
849 if (lostItem) {
849 if (lostItem) {
850+ listItem->setCulled(true);
850 releaseItem(listItem);
851 releaseItem(listItem);
851 listItem = nullptr;
852 listItem = nullptr;
852 } else {
853 } else {
tests/plugins/DashViews/listviewwithpageheadertest.cpp+4
@@ -32,6 +32,10 @@
32#include <private/qquickitem_p.h>
32#include <private/qquickitem_p.h>
33#pragma GCC diagnostic pop
33#pragma GCC diagnostic pop
34
34
35+// TODO Think on how doing a test for lost items
36+// particullary making sure that lost items are culled
37+// and then removed in the next updatePolish cycle
38+
35class ListViewWithPageHeaderTest : public QObject
39class ListViewWithPageHeaderTest : public QObject
36{
40{
37 Q_OBJECT
41 Q_OBJECT