Skip to content

Commit

Permalink
Fixed closing app not always closing all threads
Browse files Browse the repository at this point in the history
  • Loading branch information
WouterJansen committed Jan 13, 2022
1 parent 555ba66 commit a11a539
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 9 deletions.
4 changes: 0 additions & 4 deletions app/cancel.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ $(() => {
}

function onCloseButtonPress() {
app.quit();
win.close();
}

Expand All @@ -45,9 +44,7 @@ $(() => {
}

function onCancelButtonPress() {
app.quit();
win.close();

}

function onCancelAndRemoveButtonPress() {
Expand All @@ -58,7 +55,6 @@ $(() => {
console.log(err)
}
fs.unlinkSync(configPath);
app.quit();
win.close();
}

Expand Down
1 change: 0 additions & 1 deletion app/download.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ $(() => {
}

function onCloseButtonPress() {
app.quit();
win.close();
}

Expand Down
2 changes: 0 additions & 2 deletions app/folder_select.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,7 @@ $(() => {
}

function onCloseButtonPress() {
app.quit();
win.close();

}

function onContinueButtonPress() {
Expand Down
5 changes: 5 additions & 0 deletions app/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,11 @@ function createWindow() {

}

// Quit when all windows are closed.
app.on('window-all-closed', function() {
app.quit();
})

app.setAppUserModelId("PRBF2-Download-Assistant");
app.on('ready', createWindow);

Expand Down
2 changes: 0 additions & 2 deletions app/remove.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ $(() => {
}

function onCloseButtonPress() {
app.quit();
win.close();
}

Expand All @@ -52,7 +51,6 @@ $(() => {
console.log(err)
}
fs.unlinkSync(configPath);
app.quit();
win.close();
}

Expand Down

0 comments on commit a11a539

Please sign in to comment.