summary refs log tree commit diff
path: root/resources/qml/MessageView.qml
diff options
context:
space:
mode:
authorThulinma <jaron@vietors.com>2021-09-16 01:41:55 +0200
committerThulinma <jaron@vietors.com>2021-09-16 02:17:07 +0200
commit1d5bf56cf9dc8aea4aa849ef5f0f580c1eae4cdd (patch)
tree6ac1329f05c014027285cad360ec0c09b972ffdc /resources/qml/MessageView.qml
parentWorkaround for broken fetchMore() with reuseItems (diff)
downloadnheko-1d5bf56cf9dc8aea4aa849ef5f0f580c1eae4cdd.tar.xz
Improvements for linking to events
- Fixes scrolling to an event not being reliable
- Adds new /goto command that can open URLs, go to events, or go to message indexes.
- Refactored ChatPage::handleMatrixUri() to contain the handling originally in Nheko::openLink(), and makes it return a boolean based on whether the URL was handled internally or not.
Diffstat (limited to '')
-rw-r--r--resources/qml/MessageView.qml5
1 files changed, 4 insertions, 1 deletions
diff --git a/resources/qml/MessageView.qml b/resources/qml/MessageView.qml

index d80d274d..e4e58845 100644 --- a/resources/qml/MessageView.qml +++ b/resources/qml/MessageView.qml
@@ -20,6 +20,9 @@ ScrollView { ListView { id: chat + + displayMarginBeginning: height/2 + displayMarginEnd: height/2 property int delegateMaxWidth: ((Settings.timelineMaxWidth > 100 && Settings.timelineMaxWidth < parent.availableWidth) ? Settings.timelineMaxWidth : parent.availableWidth) - parent.padding * 2 @@ -276,7 +279,7 @@ ScrollView { } function onScrollToIndex(index) { - chat.positionViewAtIndex(index, ListView.Visible); + chat.positionViewAtIndex(index, ListView.Center); } target: chat.model