mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 15:09:24 +02:00
Fix styling and flow issues in avatar uploader
This commit is contained in:
parent
c21d037800
commit
83a60a541b
3 changed files with 42 additions and 8 deletions
|
@ -45,6 +45,8 @@ Windows.ScrollingWindow {
|
||||||
anchors.leftMargin: 29
|
anchors.leftMargin: 29
|
||||||
anchors.rightMargin: 29
|
anchors.rightMargin: 29
|
||||||
|
|
||||||
|
clip: true
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
model: AvatarPackagerCore.currentAvatarProject === null ? [] : AvatarPackagerCore.currentAvatarProject.projectFiles
|
model: AvatarPackagerCore.currentAvatarProject === null ? [] : AvatarPackagerCore.currentAvatarProject.projectFiles
|
||||||
|
|
|
@ -229,7 +229,7 @@ Item {
|
||||||
name: "upload-success"
|
name: "upload-success"
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: infoMessage
|
target: infoMessage
|
||||||
text: "Your avatar has been uploaded to our servers. You can modify the project files and update it again to make changes on the uploaded avatar."
|
text: "Your avatar has been successfully uploaded to our servers. Make changes to your avatar by editing and uploading the project files."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
State {
|
State {
|
||||||
|
|
|
@ -17,7 +17,7 @@ Item {
|
||||||
|
|
||||||
Timer {
|
Timer {
|
||||||
id: backToProjectTimer
|
id: backToProjectTimer
|
||||||
interval: 5000
|
interval: 2000
|
||||||
running: false
|
running: false
|
||||||
repeat: false
|
repeat: false
|
||||||
onTriggered: {
|
onTriggered: {
|
||||||
|
@ -37,7 +37,9 @@ Item {
|
||||||
if (visible) {
|
if (visible) {
|
||||||
root.uploader.stateChanged.connect(stateChangedCallback);
|
root.uploader.stateChanged.connect(stateChangedCallback);
|
||||||
root.uploader.finishedChanged.connect(function() {
|
root.uploader.finishedChanged.connect(function() {
|
||||||
backToProjectTimer.start();
|
if (root.uploader.error === 0) {
|
||||||
|
backToProjectTimer.start();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -53,7 +55,7 @@ Item {
|
||||||
id: statusItem
|
id: statusItem
|
||||||
|
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: 192
|
height: 256
|
||||||
|
|
||||||
states: [
|
states: [
|
||||||
State {
|
State {
|
||||||
|
@ -69,6 +71,8 @@ Item {
|
||||||
PropertyChanges { target: uploadSpinner; visible: false }
|
PropertyChanges { target: uploadSpinner; visible: false }
|
||||||
PropertyChanges { target: errorIcon; visible: true }
|
PropertyChanges { target: errorIcon; visible: true }
|
||||||
PropertyChanges { target: successIcon; visible: false }
|
PropertyChanges { target: successIcon; visible: false }
|
||||||
|
PropertyChanges { target: errorFooter; visible: true }
|
||||||
|
PropertyChanges { target: errorMessage; visible: true }
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -99,7 +103,7 @@ Item {
|
||||||
verticalCenter: parent.verticalCenter
|
verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
size: 164
|
size: 315
|
||||||
text: "+"
|
text: "+"
|
||||||
color: "#EA4C5F"
|
color: "#EA4C5F"
|
||||||
}
|
}
|
||||||
|
@ -151,20 +155,48 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
RalewayRegular {
|
RalewayRegular {
|
||||||
visible: root.uploader.error
|
id: errorMessage
|
||||||
|
|
||||||
|
visible: false
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: errorFooter.top
|
||||||
anchors.leftMargin: 16
|
anchors.leftMargin: 16
|
||||||
anchors.rightMargin: 16
|
anchors.rightMargin: 16
|
||||||
anchors.bottomMargin: 16
|
anchors.bottomMargin: 32
|
||||||
|
|
||||||
size: 28
|
size: 28
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
color: "white"
|
color: "white"
|
||||||
text: "We couldn't upload your avatar at this time. Please try again later."
|
text: "We couldn't upload your avatar at this time. Please try again later."
|
||||||
}
|
}
|
||||||
|
AvatarPackagerFooter {
|
||||||
|
id: errorFooter
|
||||||
|
|
||||||
|
anchors.bottom: parent.bottom
|
||||||
|
visible: false
|
||||||
|
|
||||||
|
content: Item {
|
||||||
|
anchors.fill: parent
|
||||||
|
anchors.rightMargin: 17
|
||||||
|
HifiControls.Button {
|
||||||
|
id: backButton
|
||||||
|
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
anchors.right: parent.right
|
||||||
|
|
||||||
|
text: qsTr("Back")
|
||||||
|
color: hifi.buttons.blue
|
||||||
|
colorScheme: root.colorScheme
|
||||||
|
width: 133
|
||||||
|
height: 40
|
||||||
|
onClicked: function() {
|
||||||
|
avatarPackager.state = "project"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
|
|
Loading…
Reference in a new issue