remove fileDialog
This commit is contained in:
parent
66f313675b
commit
f231b81bf4
1 changed files with 1 additions and 16 deletions
|
@ -90,7 +90,7 @@ Item {
|
|||
text: "Select Image"
|
||||
icon.name: "fileopen"
|
||||
hoverEnabled: true
|
||||
onClicked: fileDialog.open()
|
||||
onClicked: fileHelper.loadFile("Please choose a background", "image")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -138,21 +138,6 @@ Item {
|
|||
}
|
||||
}
|
||||
|
||||
FileDialog {
|
||||
id: fileDialog
|
||||
title: "Please choose a background"
|
||||
folder: shortcuts.home
|
||||
selectMultiple: false
|
||||
nameFilters: ["Image files (*.jpg *.jpeg *.png *.JPG *.JPEG *.PNG *.webp *.gif)", "All files (*)"]
|
||||
onAccepted: {
|
||||
updateImage(fileDialog.fileUrls[0]);
|
||||
console.log("image background = " + fileDialog.fileUrls[0]);
|
||||
}
|
||||
onRejected: {
|
||||
console.log("Canceled")
|
||||
}
|
||||
}
|
||||
|
||||
function changeImage(index) {
|
||||
let img = imageProxyModel.getImage(index);
|
||||
root.image = img;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue