[Qt5] PathView flicks very very slow at some point
-
The code works well when Qt 4.
It's like an advertising column.
@
import QtQuick 2.0Rectangle {
id: desktop
width: 1258
height: 697
color: "red"ListModel {
id: ads_model
ListElement {
color: "green"
}
ListElement {
color: "blue"
}
ListElement {
color: "yellow"
}
}PathView {
id: path_view
anchors.fill: parent
model: ads_model
delegate: Rectangle {
id: homepage_game
width: 878;
height: 405
z: 2 + index / 10
scale: PathView.scale
color: model.color
}focus: true
preferredHighlightBegin: 0.5 preferredHighlightEnd: 0.5
flickDeceleration: 380
path: Path {
startX: 180 - (ads_model.count - 1) * 440; startY: 280
PathAttribute { name: "scale"; value: 0.618 }
PathLine { x: desktop.width / 2; y: 280 }
PathAttribute { name: "scale"; value: 1.0 }
PathLine { x: desktop.width - 180 + (ads_model.count - 1) * 440; y: 280 }
}
}
}
@There are 3 rectangles that can be horizontally dragged. Whenever releasing the mouse, the rectangle flicks to the left or right (according to its position)
Normally, it works well. But occasionally there's a problem:
I try to drag a rectangle to such a position, that about half of this rectangle can be seen ( the other half is clipped by the window ), then the rectangle moves to the destination position at a very low speed.
This position is not easy to be found so the 'low speed situation' is not easy to reproduce. I can reproduce it after trying about 5 times. The 'slow' is quite obvious compared to the normal situation.
When I'm using Qt4, there's no such situation.. Is it a bug of Qt5, or the usage of PathView changed in Qt5 ?
I'm using WinXP.
Thanks in advance