fix: ImageLoader animation

This commit is contained in:
Richard Ramos 2020-10-07 14:12:43 -04:00 committed by Iuri Matias
parent b05a9a8ff6
commit 0774ad8ccf
1 changed files with 20 additions and 12 deletions

View File

@ -15,7 +15,7 @@ Rectangle {
when: image.status === Image.Loading
PropertyChanges {
target: loading
visible: true
active: true
}
PropertyChanges {
target: reload
@ -31,7 +31,7 @@ Rectangle {
when: image.status === Image.Error
PropertyChanges {
target: loading
visible: false
active: false
}
PropertyChanges {
target: reload
@ -51,7 +51,7 @@ Rectangle {
}
PropertyChanges {
target: loading
visible: false
active: false
}
PropertyChanges {
target: reload
@ -75,18 +75,26 @@ Rectangle {
image.sourceSize.width -= 1
}
LoadingImage {
Component {
id: loadingIndicator
LoadingImage {
width: 23
height: 23
ColorOverlay {
anchors.fill: parent
source: parent
color: Style.current.secondaryText
antialiasing: true
}
}
}
Loader {
id: loading
width: 23
height: 23
sourceComponent: loadingIndicator
anchors.verticalCenter: parent.verticalCenter
anchors.horizontalCenter: parent.horizontalCenter
ColorOverlay {
anchors.fill: parent
source: parent
color: Style.current.secondaryText
antialiasing: true
}
active: false
}
SVGImage {