making loading work and allow for canceling
This commit is contained in:
parent
cb47858c17
commit
bbb9f910d0
2 changed files with 15 additions and 7 deletions
|
@ -307,13 +307,17 @@ Kirigami.ApplicationWindow {
|
|||
/* } */
|
||||
|
||||
function load() {
|
||||
const file = fileHelper.loadFile("Load Presentation");
|
||||
const loaded = mainPage.serviceItems.load(file);
|
||||
loaded ? showPassiveNotification("Loaded: " + file)
|
||||
: showPassiveNotification("File wasn't loaded");
|
||||
loaded ? RSettings.loadFile = file
|
||||
: showPassiveNotification("Didn't set loadfile!");
|
||||
showPassiveNotification(RSettings.loadFile);
|
||||
const file = fileHelper.loadFile("Load Presentation", "pres");
|
||||
if (file != "") {
|
||||
const loaded = mainPage.serviceItems.load(file);
|
||||
loaded ? showPassiveNotification("Loaded: " + file)
|
||||
: showPassiveNotification("File wasn't loaded");
|
||||
loaded ? RSettings.loadFile = file
|
||||
: showPassiveNotification("Didn't set loadfile!");
|
||||
showPassiveNotification(RSettings.loadFile);
|
||||
} else {
|
||||
showPassiveNotification("Loading Canceled");
|
||||
}
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue