Disable animation.
This commit is contained in:
parent
676cf35c3f
commit
651c3d238b
|
@ -303,28 +303,6 @@ Item {
|
||||||
|
|
||||||
onClicked: messageListView.positionViewAtBeginning()
|
onClicked: messageListView.positionViewAtBeginning()
|
||||||
}
|
}
|
||||||
|
|
||||||
NumberAnimation {
|
|
||||||
id: timelineAnimation
|
|
||||||
target: messageListView
|
|
||||||
property: "contentY"
|
|
||||||
easing.type: Easing.InOutQuad
|
|
||||||
duration: 500
|
|
||||||
}
|
|
||||||
|
|
||||||
function gotoIndex(idx) {
|
|
||||||
timelineAnimation.stop()
|
|
||||||
|
|
||||||
var pos = contentY
|
|
||||||
var destPos
|
|
||||||
|
|
||||||
positionViewAtIndex(idx, ListView.Contain)
|
|
||||||
destPos = contentY
|
|
||||||
|
|
||||||
timelineAnimation.from = pos
|
|
||||||
timelineAnimation.to = destPos
|
|
||||||
timelineAnimation.start()
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Control {
|
Control {
|
||||||
|
@ -372,8 +350,7 @@ Item {
|
||||||
var index = messageEventModel.eventIDToIndex(eventID)
|
var index = messageEventModel.eventIDToIndex(eventID)
|
||||||
if (index === -1) return
|
if (index === -1) return
|
||||||
// messageListView.currentIndex = sortedMessageEventModel.mapFromSource(index)
|
// messageListView.currentIndex = sortedMessageEventModel.mapFromSource(index)
|
||||||
// messageListView.positionViewAtIndex(sortedMessageEventModel.mapFromSource(index), ListView.Contain)
|
messageListView.positionViewAtIndex(sortedMessageEventModel.mapFromSource(index), ListView.Contain)
|
||||||
messageListView.gotoIndex(sortedMessageEventModel.mapFromSource(index))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function saveReadMarker(room) {
|
function saveReadMarker(room) {
|
||||||
|
|
Loading…
Reference in New Issue