diff options
author | Jedi18 <targetakhil@gmail.com> | 2021-02-16 00:47:17 +0530 |
---|---|---|
committer | Jedi18 <targetakhil@gmail.com> | 2021-02-16 00:50:28 +0530 |
commit | 19dbbb2c6cffdf0697635f08acf3af9138aed7b9 (patch) | |
tree | efdb6a1d7d776daec8cd8edb8d202a50f0da2935 /resources/qml/Completer.qml | |
parent | Add double tap to reply feature (diff) | |
download | nheko-19dbbb2c6cffdf0697635f08acf3af9138aed7b9.tar.xz |
add rooms model, add room delegate for completer
Diffstat (limited to 'resources/qml/Completer.qml')
-rw-r--r-- | resources/qml/Completer.qml | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/resources/qml/Completer.qml b/resources/qml/Completer.qml index 27322172..f77f50e9 100644 --- a/resources/qml/Completer.qml +++ b/resources/qml/Completer.qml @@ -154,6 +154,35 @@ Popup { } + DelegateChoice { + roleValue: "room" + + RowLayout { + id: del + + anchors.centerIn: parent + + Avatar { + height: 24 + width: 24 + url: model.avatarUrl.replace("mxc://", "image://MxcImage/") + onClicked: popup.completionClicked(completer.completionAt(model.index)) + } + + Label { + text: model.roomName + color: model.index == popup.currentIndex ? colors.highlightedText : colors.text + } + + Label { + text: "(" + model.roomAlias + ")" + color: model.index == popup.currentIndex ? colors.highlightedText : colors.buttonText + } + + } + + } + } } |