diff --git a/qt6/src/qml/AboutDialog.qml b/qt6/src/qml/AboutDialog.qml index 3cef98ea..006d7d9a 100644 --- a/qt6/src/qml/AboutDialog.qml +++ b/qt6/src/qml/AboutDialog.qml @@ -31,6 +31,12 @@ DialogWindow { id: contentView width: parent.width implicitHeight: contentLayout.implicitHeight + + D.LicenseInfoProvider { + id: licensePathChecker + path: control.licensePath + } + ColumnLayout { id: contentLayout spacing: 0 @@ -138,7 +144,13 @@ DialogWindow { } Label { id: acknowledgmentsLabel - text: qsTr("Sincerely appreciate the %1 used.").arg(control.__websiteLinkTemplate.arg("-").arg(qsTr("open-source software"))) + text: { + var softwareText = qsTr("open-source software"); + if (licensePathChecker.valid) + return qsTr("Sincerely appreciate the %1 used.").arg(control.__websiteLinkTemplate.arg("-").arg(softwareText)); + else + return qsTr("Sincerely appreciate the %1 used.").arg(softwareText); + } textFormat: Text.RichText Layout.fillWidth: true font: D.DTK.fontManager.t8 @@ -173,7 +185,7 @@ DialogWindow { id: licenseDialogLoader active: false sourceComponent: LicenseDialog { - licensePath: control.licensePath + licenseProvider: licensePathChecker onClosing: function (close) { licenseDialogLoader.active = false } diff --git a/qt6/src/qml/LicenseDialog.qml b/qt6/src/qml/LicenseDialog.qml index aff0df0a..5f394453 100644 --- a/qt6/src/qml/LicenseDialog.qml +++ b/qt6/src/qml/LicenseDialog.qml @@ -15,7 +15,7 @@ DialogWindow { height: 900 title: qsTr("open-source software") - property alias licensePath: licenseProvider.path + property D.LicenseInfoProvider licenseProvider header: D.DialogTitleBar { leftContent: Item { @@ -37,10 +37,6 @@ DialogWindow { implicitWidth: control.width - control.leftPadding - control.rightPadding implicitHeight: control.height - DS.Style.dialogWindow.titleBarHeight - DS.Style.dialogWindow.contentHMargin - D.LicenseInfoProvider { - id: licenseProvider - } - StackView { id: stackView anchors.fill: parent