1
0
mirror of https://gitlab.com/kelteseth/ScreenPlay.git synced 2024-09-15 06:52:34 +02:00

Change gif selection to clear on reset

This commit is contained in:
Elias Steurer 2020-12-11 14:34:43 +01:00
parent 393e48ab88
commit dd361eef43
2 changed files with 13 additions and 6 deletions

View File

@ -105,7 +105,10 @@ Item {
bottom: parent.bottom
margins: 5
}
onClicked: root.file = ""
onClicked: {
root.file = ""
fileDialog.file = ""
}
}
Button {

View File

@ -49,10 +49,18 @@ WizardPage {
Layout.fillHeight: true
Layout.fillWidth: true
Text {
color: Material.secondaryTextColor
font.family: ScreenPlay.settings.font
text: qsTr("Select a gif below.")
anchors.centerIn: parent
}
AnimatedImage {
id: imgPreview
anchors.fill: parent
fillMode: Image.PreserveAspectCrop
source: fileSelector.fileDialog.file
}
}
@ -63,13 +71,9 @@ WizardPage {
Common.FileSelector {
id: fileSelector
Layout.fillWidth: true
placeHolderText: qsTr("Select your gif")
fileDialog.nameFilters: ["Gif (*.gif)"]
fileDialog.onAccepted: {
imgPreview.source = fileSelector.fileDialog.file
}
Layout.fillWidth: true
}
}