summary refs log tree commit diff
diff options
context:
space:
mode:
authorLoren Burkholder <computersemiexpert@outlook.com>2021-09-07 20:38:39 -0400
committerLoren Burkholder <computersemiexpert@outlook.com>2021-09-11 19:35:31 -0400
commit96edc0bb7522fb6ada70c34bb503e3eb3eb1fa92 (patch)
tree341a7d6def3613df16aef21e6ed19b756c6bcdd5
parentAdd direct chat handling for previews and invites (diff)
downloadnheko-96edc0bb7522fb6ada70c34bb503e3eb3eb1fa92.tar.xz
Use correct form of roomId
-rw-r--r--resources/qml/CommunitiesList.qml2
-rw-r--r--resources/qml/TimelineView.qml4
-rw-r--r--resources/qml/TopBar.qml15
3 files changed, 12 insertions, 9 deletions
diff --git a/resources/qml/CommunitiesList.qml b/resources/qml/CommunitiesList.qml

index 121eb7db..ff9b7da7 100644 --- a/resources/qml/CommunitiesList.qml +++ b/resources/qml/CommunitiesList.qml
@@ -130,7 +130,7 @@ Page { else return "image://colorimage/" + model.avatarUrl + "?" + communityItem.unimportantText; } - roomid: model.roomid + roomid: model.id displayName: model.displayName color: communityItem.background } diff --git a/resources/qml/TimelineView.qml b/resources/qml/TimelineView.qml
index b38df44f..91bbca5b 100644 --- a/resources/qml/TimelineView.qml +++ b/resources/qml/TimelineView.qml
@@ -137,7 +137,7 @@ Item { ColumnLayout { id: preview - property string roomid: room ? room.roomid : (roomPreview ? roomPreview.roomid : "") + property string roomId: room ? room.roomId : (roomPreview ? roomPreview.roomId : "") property string roomName: room ? room.roomName : (roomPreview ? roomPreview.roomName : "") property string roomTopic: room ? room.roomTopic : (roomPreview ? roomPreview.roomTopic : "") property string avatarUrl: room ? room.roomAvatarUrl : (roomPreview ? roomPreview.roomAvatarUrl : "") @@ -154,7 +154,7 @@ Item { Avatar { url: parent.avatarUrl.replace("mxc://", "image://MxcImage/") - roomid: parent.roomid + roomid: parent.roomId displayName: parent.roomName height: 130 width: 130 diff --git a/resources/qml/TopBar.qml b/resources/qml/TopBar.qml
index a8a53a24..05c61d99 100644 --- a/resources/qml/TopBar.qml +++ b/resources/qml/TopBar.qml
@@ -13,10 +13,13 @@ Rectangle { property bool showBackButton: false property string roomName: room ? room.roomName : qsTr("No room selected") + property string roomId: room ? room.roomId : "" property string avatarUrl: room ? room.roomAvatarUrl : "" property string roomTopic: room ? room.roomTopic : "" property bool isEncrypted: room ? room.isEncrypted : false property int trustlevel: room ? room.trustlevel : Crypto.Unverified + property bool isDirect: room ? room.isDirect : false + property string directChatOtherUserId: room ? room.directChatOtherUserId : "" Layout.fillWidth: true implicitHeight: topLayout.height + Nheko.paddingMedium * 2 @@ -65,12 +68,12 @@ Rectangle { width: Nheko.avatarSize height: Nheko.avatarSize url: avatarUrl.replace("mxc://", "image://MxcImage/") - roomid: room.roomId - userid: room.isDirect ? room.directChatOtherUserId : "" + roomid: roomId + userid: isDirect ? directChatOtherUserId : "" displayName: roomName onClicked: { if (room) - TimelineManager.openRoomSettings(room.roomId); + TimelineManager.openRoomSettings(roomId); } } @@ -137,7 +140,7 @@ Rectangle { Platform.MenuItem { visible: room ? room.permissions.canInvite() : false text: qsTr("Invite users") - onTriggered: TimelineManager.openInviteUsers(room.roomId) + onTriggered: TimelineManager.openInviteUsers(roomId) } Platform.MenuItem { @@ -147,12 +150,12 @@ Rectangle { Platform.MenuItem { text: qsTr("Leave room") - onTriggered: TimelineManager.openLeaveRoomDialog(room.roomId) + onTriggered: TimelineManager.openLeaveRoomDialog(roomId) } Platform.MenuItem { text: qsTr("Settings") - onTriggered: TimelineManager.openRoomSettings(room.roomId) + onTriggered: TimelineManager.openRoomSettings(roomId) } }