switching to qml based save dialog
This commit is contained in:
parent
fc1a8cd945
commit
a4ce593c0d
1 changed files with 7 additions and 5 deletions
|
@ -197,7 +197,7 @@ Kirigami.ApplicationWindow {
|
||||||
defaultSuffix: ".pres"
|
defaultSuffix: ".pres"
|
||||||
selectExisting: false
|
selectExisting: false
|
||||||
onAccepted: {
|
onAccepted: {
|
||||||
/* save(saveFileDialog.fileUrl); */
|
finalSave(saveFileDialog.fileUrl);
|
||||||
console.log(saveFileDialog.fileUrl);
|
console.log(saveFileDialog.fileUrl);
|
||||||
}
|
}
|
||||||
onRejected: {
|
onRejected: {
|
||||||
|
@ -261,13 +261,15 @@ Kirigami.ApplicationWindow {
|
||||||
const saveFile = RSettings.lastSaveFile;
|
const saveFile = RSettings.lastSaveFile;
|
||||||
console.log(saveFile.toString());
|
console.log(saveFile.toString());
|
||||||
let file = "";
|
let file = "";
|
||||||
saveFile.length === 0 ? file = fileHelper.saveFile() : file = saveFile;
|
if (saveFile.length === 0) {
|
||||||
finalSave(file);
|
saveFileDialog.open()
|
||||||
|
} else {
|
||||||
|
finalSave(saveFile);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function saveAs() {
|
function saveAs() {
|
||||||
const file = fileHelper.saveFile();
|
saveFileDialog.open();
|
||||||
finalSave(file);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function finalSave(file) {
|
function finalSave(file) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue