Add arg to ignore splash window
This commit is contained in:
parent
af9ed58eef
commit
b8f847e84c
2 changed files with 2988 additions and 3781 deletions
6611
pnpm-lock.yaml
6611
pnpm-lock.yaml
File diff suppressed because it is too large
Load diff
|
@ -469,16 +469,22 @@ const runVencordMain = once(() => require(join(VENCORD_FILES_DIR, "vencordDeskto
|
||||||
|
|
||||||
export async function createWindows() {
|
export async function createWindows() {
|
||||||
const startMinimized = process.argv.includes("--start-minimized");
|
const startMinimized = process.argv.includes("--start-minimized");
|
||||||
const splash = createSplashWindow(startMinimized);
|
const noSplash = process.argv.includes("--no-splash");
|
||||||
|
let splash = undefined;
|
||||||
|
if (!noSplash) {
|
||||||
|
splash = createSplashWindow(startMinimized);
|
||||||
// SteamOS letterboxes and scales it terribly, so just full screen it
|
// SteamOS letterboxes and scales it terribly, so just full screen it
|
||||||
if (isDeckGameMode) splash.setFullScreen(true);
|
if (isDeckGameMode) splash.setFullScreen(true);
|
||||||
|
}
|
||||||
await ensureVencordFiles();
|
await ensureVencordFiles();
|
||||||
runVencordMain();
|
runVencordMain();
|
||||||
|
|
||||||
mainWin = createMainWindow();
|
mainWin = createMainWindow();
|
||||||
|
|
||||||
mainWin.webContents.on("did-finish-load", () => {
|
mainWin.webContents.on("did-finish-load", () => {
|
||||||
|
if (splash) {
|
||||||
splash.destroy();
|
splash.destroy();
|
||||||
|
}
|
||||||
|
|
||||||
if (!startMinimized) {
|
if (!startMinimized) {
|
||||||
mainWin!.show();
|
mainWin!.show();
|
||||||
|
|
Loading…
Reference in a new issue