Details
-
Bug
-
Resolution: Unresolved
-
P4: Low
-
None
-
5.6.0, 5.7.0, 5.9.0 Alpha
-
None
-
osx, windows
Description
In our original application, the contentY of the ListView takes a negative value after updating a delegate item (by updating model content from c++) That causes a jump above listview begin automatically although we're not touching contentY or trying to move ListView in some other way.
import QtQuick 2.7 import QtQuick.Controls 1.5 import QtQuick.Dialogs 1.2 ApplicationWindow { visible: true width: 640 height: 480 ListView { id: listView anchors.fill: parent model: testModel delegate: Text { id: delegateItem width: listView.width height: 40 horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter text: name_role Repeater { model: 10 delegate: Image { source: "qrc:///test.png" cache: false visible: false } } } } Button { id: button anchors.right: parent.right anchors.bottom: parent.bottom anchors.margins: 10 text: "test bug" onClicked: { testModel.modifyName(40, "asdasdads") testModel.removeRow(30) } } }
By a repeater we tried to simulate that delegate is heavier. On windows its diffucult to reproduce this problem (but it appears in some cases) on osx you shall see the same issue as on attached movie. "Test bug" button doesn't seems to cause an issue but in our original project - idea of updating delegate remains nearly the same
everything works fine on Qt 5.5
Attachments
Issue Links
- relates to
-
QTBUG-64219 [REG 5.5.1->5.6.0] Removing and adding rows breaks ListView content positioning
- Reported