[ubuntu] Avoid slow transition to opened article
Fixes: https://github.com/mardy/ttrss/issues/10
This commit is contained in:
parent
21aea47514
commit
d42992cb57
1 changed files with 4 additions and 6 deletions
|
|
@ -16,7 +16,7 @@ Page {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property bool isCat: false
|
property bool isCat: false
|
||||||
property var model
|
property alias model: listView.model
|
||||||
property int currentIndex: -1
|
property int currentIndex: -1
|
||||||
property alias currentItem: listView.currentItem
|
property alias currentItem: listView.currentItem
|
||||||
|
|
||||||
|
|
@ -45,7 +45,7 @@ Page {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
orientation: ListView.Horizontal
|
orientation: ListView.Horizontal
|
||||||
snapMode: ListView.SnapOneItem
|
snapMode: ListView.SnapOneItem
|
||||||
highlightFollowsCurrentItem: false
|
highlightFollowsCurrentItem: true
|
||||||
highlightRangeMode: ListView.StrictlyEnforceRange
|
highlightRangeMode: ListView.StrictlyEnforceRange
|
||||||
|
|
||||||
delegate: FeedItem {
|
delegate: FeedItem {
|
||||||
|
|
@ -73,11 +73,9 @@ Page {
|
||||||
}
|
}
|
||||||
|
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
/* For some reason, unless this is done here, the ListView would
|
/* We don't use an alias on the current index, in order to perform the
|
||||||
* instantiate all the delegates when the page is first shown. */
|
* autoread action when the index changes. */
|
||||||
listView.model = root.model
|
|
||||||
listView.currentIndex = root.currentIndex
|
listView.currentIndex = root.currentIndex
|
||||||
listView.highlightFollowsCurrentItem = true
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Timer {
|
Timer {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue