mirror of
https://github.com/GiriNeko/YesPlayMusic.git
synced 2025-12-16 21:28:06 +00:00
为 Windows 平台添加沉浸式标题栏 (#277)
This commit is contained in:
parent
c0c4597cd8
commit
51fc57efe8
7 changed files with 147 additions and 2 deletions
|
|
@ -88,15 +88,20 @@ class Background {
|
|||
createWindow() {
|
||||
console.log("creating app window");
|
||||
|
||||
// Only for Windows, a special title bar for it
|
||||
const withoutFrame = process.platform == "win32";
|
||||
|
||||
this.window = new BrowserWindow({
|
||||
width: this.store.get("window.width") | 1440,
|
||||
height: this.store.get("window.height") | 840,
|
||||
minWidth: 1080,
|
||||
minHeight: 720,
|
||||
minWidth: 360,
|
||||
minHeight: 240,
|
||||
titleBarStyle: "hiddenInset",
|
||||
frame: !withoutFrame,
|
||||
webPreferences: {
|
||||
webSecurity: false,
|
||||
nodeIntegration: true,
|
||||
enableRemoteModule: true,
|
||||
},
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue