From 5eebeba2a160192d48344ab587e90faaf6135dd8 Mon Sep 17 00:00:00 2001 From: ZhangXianQiang <1135831638@qq.com> Date: 星期一, 03 六月 2024 15:45:44 +0800 Subject: [PATCH] feat:用户信息面板 --- dist-electron/background.js | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/dist-electron/background.js b/dist-electron/background.js index 594cf04..aedb9c8 100644 --- a/dist-electron/background.js +++ b/dist-electron/background.js @@ -1,11 +1,14 @@ "use strict"; -const { app, BrowserWindow } = require("electron"); +const { app, BrowserWindow, screen } = require("electron"); const { join } = require("path"); process.env["ELECTRON_DISABLE_SECURITY_WARNINGS"] = "true"; const createWindow = () => { + const { width, height } = screen.getPrimaryDisplay().bounds; const win = new BrowserWindow({ - width: 800, - height: 600 + width, + height, + minWidth: 1280, + minHeight: 720 }); if (process.env.VITE_DEV_SERVER_URL) { win.loadURL(process.env.VITE_DEV_SERVER_URL); -- Gitblit v1.8.0