feat: kill aria2c

This commit is contained in:
Chubby Granny Chaser 2024-05-29 22:14:07 +01:00
parent d353002eab
commit 34a44e7fa9
No known key found for this signature in database
2 changed files with 19 additions and 2 deletions

View file

@ -3,7 +3,12 @@ import updater from "electron-updater";
import i18n from "i18next";
import path from "node:path";
import { electronApp, optimizer } from "@electron-toolkit/utils";
import { logger, resolveDatabaseUpdates, WindowManager } from "@main/services";
import {
DownloadManager,
logger,
resolveDatabaseUpdates,
WindowManager,
} from "@main/services";
import { dataSource } from "@main/data-source";
import * as resources from "@locales";
import { userPreferencesRepository } from "@main/repository";
@ -100,6 +105,10 @@ app.on("window-all-closed", () => {
WindowManager.mainWindow = null;
});
app.on("before-quit", () => {
DownloadManager.disconnect();
});
app.on("activate", () => {
// On OS X it's common to re-create a window in the app when the
// dock icon is clicked and there are no other windows open.