1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
|
import QtQuick
import QtQuick.Layouts
import QtQuick.Controls.Material
import Main
CustomDialog {
id: aboutDialog
Material.primary: Material.LightBlue
Material.accent: Material.LightBlue
implicitWidth: 400
focus: true
standardButtons: Dialog.Ok
title: qsTr("About %1").arg(Qt.application.name)
contentItem: ScrollView {
contentWidth: availableWidth
ColumnLayout {
width: availableWidth
Image {
readonly property double size: 128
Layout.alignment: Qt.AlignHCenter
Layout.preferredWidth: size
Layout.preferredHeight: size
source: "qrc:/icons/hicolor/scalable/app/syncthingtray.svg"
sourceSize.width: size
sourceSize.height: size
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: qsTr("Developed by %1").arg(Qt.application.organization)
font.weight: Font.Light
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: qsTr("App version")
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: Qt.application.version
font.weight: Font.Light
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: qsTr("Syncthing version")
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: App.syncthingVersion
font.weight: Font.Light
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: qsTr("Qt version")
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
Label {
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
text: App.qtVersion
font.weight: Font.Light
horizontalAlignment: Qt.AlignHCenter
elide: Qt.ElideRight
}
}
}
footer: DialogButtonBox {
Button {
text: qsTr("Legal info")
flat: true
onClicked: App.openUrlExternally(App.readmeUrl + "#legal-information")
DialogButtonBox.buttonRole: DialogButtonBox.HelpRole
}
Button {
text: qsTr("Website")
flat: true
onClicked: App.openUrlExternally(App.website)
DialogButtonBox.buttonRole: DialogButtonBox.HelpRole
}
}
}
|