Implement VencordDesktop, improve tray

This commit is contained in:
Vendicated
2023-04-04 01:35:37 +02:00
parent f45d6482ac
commit 1c20f35460
6 changed files with 57 additions and 22 deletions

View File

@@ -1,8 +1,13 @@
import { ipcMain } from "electron";
import { app, ipcMain } from "electron";
import { join } from "path";
import { GET_PRELOAD_FILE } from "../shared/IpcEvents";
import { GET_PRELOAD_FILE, RELAUNCH } from "../shared/IpcEvents";
import { VENCORD_FILES_DIR } from "./constants";
ipcMain.on(GET_PRELOAD_FILE, e => {
e.returnValue = join(VENCORD_FILES_DIR, "preload.js");
});
ipcMain.handle(RELAUNCH, () => {
app.relaunch();
app.exit();
});