change list viewer and credits

This commit is contained in:
IgorekLoschinin 2021-10-19 22:04:32 +03:00
parent eb17693759
commit abf015424b
3 changed files with 22 additions and 89 deletions

View File

@ -12,15 +12,12 @@ ApplicationWindow {
Credits { Credits {
state: "about" state: "about"
developersList: [ listCustomInfo: [
{ "## QuasarApp Developers:",
section: qsTr("## QuasarApp Core"),
sectionList: [
"* Oleg-Disigner", "* Oleg-Disigner",
"* Yankovich Andrei" "* Yankovich Andrei"
] ]
}
]
} }
Credits { Credits {
state: "minimal" state: "minimal"
@ -46,16 +43,12 @@ ApplicationWindow {
Credits { Credits {
state: "full" state: "full"
developersList: [ listCustomInfo: [
{ "## QuasarApp Core",
section: qsTr("## QuasarApp Core"),
sectionList: [
"* Oleg-Disigner", "* Oleg-Disigner",
"* Yankovich Andrei" "* Yankovich Andrei"
] ]
} }
]
}
} }
PageIndicator { PageIndicator {

View File

@ -10,24 +10,14 @@ Page {
property bool showHeader: true property bool showHeader: true
property bool showPatreon: true property bool showPatreon: true
property bool showBitcoin: true property bool showBitcoin: true
property bool showPatrons: (showQR || showPatreon || showBitcoin) && patronsList.length property bool showPatrons: (showQR || showPatreon || showBitcoin) && listCustomInfo.length
// developersa and patronsList lists must be contain structure with a section amd sectionList fields. // developersa and patronsList lists must be contain structure with a section amd sectionList fields.
// The section it is section name // The section it is section name
// the sectionList it is list of section members. // the sectionList it is list of section members.
property string iconLogo: "" property string iconLogo: ""
property int iconWidth: 250 property int iconWidth: 250
property var developersList: [] property var listCustomInfo: []
property var versionList: []
property var patronsList: [
{
section: qsTr("## Silver Membership Patrons:"),
sectionList: [
"* Rustem Husnutdinov",
"* Semih Ufuk Güler"
]
}
]
header: Image { header: Image {
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
@ -116,54 +106,12 @@ Page {
} }
Label {
text: qsTr("# Our patrons list:")
Layout.fillWidth: true
textFormat: TextEdit.MarkdownText
visible: showPatrons
}
ListViewer { ListViewer {
model: patronsList model: listCustomInfo
visible: showPatrons visible: showPatrons
} }
Label {
text: qsTr("# Developers list:")
Layout.fillWidth: true
textFormat: TextEdit.MarkdownText
visible: developersList.length
}
ListViewer {
model: developersList
visible: developersList.length
}
Label {
text: qsTr("# Version list:")
Layout.fillWidth: true
textFormat: TextEdit.MarkdownText
visible: versionList.length
}
ListViewer {
model: versionList
visible: versionList.length
}
} }
anchors.fill: parent anchors.fill: parent
@ -223,7 +171,6 @@ Page {
showPatreon: false showPatreon: false
showBitcoin: false showBitcoin: false
showPatrons: true showPatrons: true
} }
}, },
@ -235,7 +182,7 @@ Page {
showHeader: false showHeader: false
showPatreon: false showPatreon: false
showBitcoin: false showBitcoin: false
patronsList: [] listCustomInfo: []
} }
} }

View File

@ -15,20 +15,13 @@ import QtQuick.Layouts 1.15
// ] // ]
// } // }
//] //]
Repeater {
ColumnLayout { ColumnLayout {
property var model: []
Layout.fillWidth: true Layout.fillWidth: true
Label {
text: modelData.section
Layout.fillWidth: true
textFormat: TextEdit.MarkdownText
}
Repeater { Repeater {
model: modelData.sectionList model: model
Label { Label {
text: modelData text: modelData
@ -40,4 +33,4 @@ Repeater {
} }
} }
}