From 7edbe9d7e6cbeb116d3d6d9b00da09dc5047aa99 Mon Sep 17 00:00:00 2001
From: ZhangXianQiang <1135831638@qq.com>
Date: 星期三, 05 六月 2024 10:56:38 +0800
Subject: [PATCH] fix:修改菜单适配问题

---
 src/background.js |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/background.js b/src/background.js
index 5d81b89..c7c4802 100644
--- a/src/background.js
+++ b/src/background.js
@@ -1,5 +1,5 @@
 // src-electron/main.js
-const { app, BrowserWindow } = require('electron');
+const { app, BrowserWindow,screen  } = require('electron');
 const { join } = require('path');
 
 // 灞忚斀瀹夊叏璀﹀憡
@@ -8,9 +8,12 @@
 
 // 鍒涘缓娴忚鍣ㄧ獥鍙f椂锛岃皟鐢ㄨ繖涓嚱鏁般��
 const createWindow = () => {
+    const {width, height} = screen.getPrimaryDisplay().bounds;
     const win = new BrowserWindow({
-        width: 800,
-        height: 600,
+        width: width,
+        height: height,
+        minWidth: 1280,
+        minHeight: 720,
     });
 
     // win.loadURL('http://localhost:3000')

--
Gitblit v1.8.0