mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 10:17:40 +02:00
Rework header and add logo
Use HiFi logo as placeholder for now until Interface SVG is available.
This commit is contained in:
parent
085d87e035
commit
0994cd97dc
1 changed files with 25 additions and 19 deletions
|
@ -26,14 +26,15 @@ DialogContainer {
|
||||||
implicitWidth: backgroundRectangle.width
|
implicitWidth: backgroundRectangle.width
|
||||||
implicitHeight: backgroundRectangle.height
|
implicitHeight: backgroundRectangle.height
|
||||||
|
|
||||||
readonly property int inputWidth: 500
|
readonly property int contentWidth: 500
|
||||||
readonly property int inputHeight: 60
|
readonly property int logoSize: 60
|
||||||
readonly property int borderWidth: 30
|
readonly property int borderWidth: 30
|
||||||
readonly property int closeMargin: 16
|
readonly property int closeMargin: 16
|
||||||
readonly property int inputSpacing: 16
|
readonly property int inputSpacing: 16
|
||||||
readonly property int buttonWidth: 150
|
readonly property int buttonWidth: 150
|
||||||
readonly property int buttonHeight: 50
|
readonly property int buttonHeight: 50
|
||||||
readonly property int buttonRadius: 15
|
readonly property int buttonRadius: 15
|
||||||
|
readonly property int noticeHeight: 15 * inputSpacing
|
||||||
|
|
||||||
signal triggerBuildDownload
|
signal triggerBuildDownload
|
||||||
signal closeUpdateDialog
|
signal closeUpdateDialog
|
||||||
|
@ -42,8 +43,8 @@ DialogContainer {
|
||||||
id: backgroundRectangle
|
id: backgroundRectangle
|
||||||
color: "#ffffff"
|
color: "#ffffff"
|
||||||
|
|
||||||
width: updateDialog.inputWidth + updateDialog.borderWidth * 2
|
width: updateDialog.contentWidth + updateDialog.borderWidth * 2
|
||||||
height: updateDialog.inputHeight * 6 + updateDialog.closeMargin * 2
|
height: mainContent.height + updateDialog.borderWidth * 2
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
|
@ -62,9 +63,20 @@ DialogContainer {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Image {
|
||||||
|
id: logo
|
||||||
|
source: "../images/hifi-logo.svg"
|
||||||
|
width: updateDialog.logoSize
|
||||||
|
height: updateDialog.logoSize
|
||||||
|
anchors {
|
||||||
|
top: mainContent.top
|
||||||
|
right: mainContent.right
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
id: mainContent
|
id: mainContent
|
||||||
width: updateDialog.inputWidth
|
width: updateDialog.contentWidth
|
||||||
spacing: updateDialog.inputSpacing
|
spacing: updateDialog.inputSpacing
|
||||||
anchors {
|
anchors {
|
||||||
horizontalCenter: parent.horizontalCenter
|
horizontalCenter: parent.horizontalCenter
|
||||||
|
@ -72,36 +84,30 @@ DialogContainer {
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: dialogTitle
|
id: header
|
||||||
width: updateDialog.inputWidth
|
width: parent.width - updateDialog.logoSize - updateDialog.inputSpacing
|
||||||
height: updateDialog.inputHeight
|
height: updateAvailable.height + versionDetails.height
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
id: updateAvailableText
|
id: updateAvailable
|
||||||
text: "Update Available"
|
text: "Update Available"
|
||||||
anchors {
|
|
||||||
verticalCenter: parent.verticalCenter
|
|
||||||
left: parent.left
|
|
||||||
leftMargin: updateDialog.inputSpacing
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
id: versionDetails
|
||||||
text: updateDialog.updateAvailableDetails
|
text: updateDialog.updateAvailableDetails
|
||||||
font.pixelSize: 14
|
font.pixelSize: 14
|
||||||
color: hifi.colors.text
|
color: hifi.colors.text
|
||||||
anchors {
|
anchors {
|
||||||
verticalCenter: parent.verticalCenter
|
top: updateAvailable.bottom
|
||||||
left: updateAvailableText.right
|
|
||||||
leftMargin: 13
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ScrollView {
|
ScrollView {
|
||||||
id: scrollArea
|
id: scrollArea
|
||||||
width: updateDialog.inputWidth
|
width: parent.width
|
||||||
height: backgroundRectangle.height - (dialogTitle.height * 2.5) - updateDialog.closeMargin
|
height: updateDialog.noticeHeight
|
||||||
horizontalScrollBarPolicy: Qt.ScrollBarAlwaysOff
|
horizontalScrollBarPolicy: Qt.ScrollBarAlwaysOff
|
||||||
verticalScrollBarPolicy: Qt.ScrollBarAsNeeded
|
verticalScrollBarPolicy: Qt.ScrollBarAsNeeded
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue