Fix broken infinite scroll.
This commit is contained in:
parent
c8184929e4
commit
c77a2535e5
|
@ -21,7 +21,8 @@ RoomPanelForm {
|
||||||
property int largestVisibleIndex: messageListView.count > 0 ? messageListView.indexAt(messageListView.contentX, messageListView.contentY + messageListView.height - 1) : -1
|
property int largestVisibleIndex: messageListView.count > 0 ? messageListView.indexAt(messageListView.contentX, messageListView.contentY + messageListView.height - 1) : -1
|
||||||
|
|
||||||
onContentYChanged: {
|
onContentYChanged: {
|
||||||
if(messageListView.verticalVelocity < 0 && messageListView.contentY - 5000 < messageListView.originY)
|
console.log("Content Y changed.")
|
||||||
|
if(currentRoom && messageListView.contentY - 5000 < messageListView.originY)
|
||||||
currentRoom.getPreviousContent(50);
|
currentRoom.getPreviousContent(50);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue