Fix opening a second invitation

This commit is contained in:
Tobias Fella
2021-02-10 23:13:16 +01:00
parent b84375749b
commit 9432e28685

View File

@@ -65,7 +65,7 @@ Kirigami.ScrollablePage {
property var id
visible: currentRoom.isInvite
visible: currentRoom && currentRoom.isInvite
anchors.centerIn: parent
text: i18n("Accept this invitation?")
RowLayout {
@@ -86,12 +86,20 @@ Kirigami.ScrollablePage {
onClicked: {
currentRoom.acceptInvitation();
invitation.id = currentRoom.id
invitation.visible = false
currentRoom = null
}
}
}
}
Kirigami.PlaceholderMessage {
anchors.centerIn: parent
visible: page.currentRoom === null || (messageListView.count === 0 && !page.currentRoom.allHistoryLoaded && !page.currentRoom.isInvite)
QQC2.BusyIndicator {
running: true
}
}
focus: true
Keys.onTabPressed: {
@@ -160,14 +168,6 @@ Kirigami.ScrollablePage {
room: currentRoom
}
Kirigami.PlaceholderMessage {
anchors.centerIn: parent
visible: messageListView.count === 0 && !currentRoom.allHistoryLoaded
QQC2.BusyIndicator {
running: true
}
}
QQC2.Popup {
anchors.centerIn: parent