Only create consent sheet if required

This commit is contained in:
Tobias Fella
2023-06-12 13:20:24 +02:00
parent 32ff22ba89
commit 80b451c27b

View File

@@ -259,8 +259,9 @@ Kirigami.ApplicationWindow {
}
function onUserConsentRequired(url) {
consentSheet.url = url
consentSheet.open()
let consent = consentSheetComponent.createObject(QQC2.ApplicationWindow.overlay)
consent.url = url
consent.open()
}
}
@@ -301,6 +302,8 @@ Kirigami.ApplicationWindow {
}
}
Component {
id: consentSheetComponent
Kirigami.OverlaySheet {
id: consentSheet
@@ -320,6 +323,7 @@ Kirigami.ApplicationWindow {
onClicked: UrlHelper.openUrl(consentSheet.url)
}
}
}
Component {
id: createRoomDialog