From 4bc8acd75d9b0ea776ba36d8e2a43a2d4381901c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=90=8C=E6=A3=AE?= Date: Tue, 2 Jul 2024 17:37:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=91=E5=B8=83=20v1.1.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- menu/menu.js | 53 ++++++++++++++++++++++++++++++++++------------------ package.json | 9 ++++++--- 2 files changed, 41 insertions(+), 21 deletions(-) diff --git a/menu/menu.js b/menu/menu.js index 0462e13..2c943f3 100644 --- a/menu/menu.js +++ b/menu/menu.js @@ -1,9 +1,12 @@ -const { Menu, BrowserWindow } = require("electron") +const { app, Menu, BrowserWindow } = require("electron") const path = require('node:path') const server = require('../server/server'); const mainWin = require('../windows/app'); const iconPath = path.join(__dirname, '..', 'iyuu.ico') +const iconPngPath = path.join(__dirname, '..', 'iyuu.png') + +const { version } = require('../package.json') let template = [ { @@ -28,11 +31,7 @@ let template = [ let win = new BrowserWindow({ width: 800, height: 600, - icon: iconPath, - webPreferences: { - nodeIntegration: true, - contextIsolation: false, - } + icon: iconPath }); win.loadURL("https://doc.iyuu.cn/"); win.on("closed", () => { @@ -40,6 +39,20 @@ let template = [ }); } }, + { + label: "数据统计", + click: () => { + let win = new BrowserWindow({ + width: 800, + height: 600, + icon: iconPath + }); + win.loadURL("https://analytics.lifebus.top/share/uz482jXYOxwnoRRZ/iyuu.lifebus.top"); + win.on("closed", () => { + win = null; + }); + } + }, ] }, { @@ -51,11 +64,7 @@ let template = [ let win = new BrowserWindow({ width: 800, height: 600, - icon: iconPath, - webPreferences: { - nodeIntegration: true, - contextIsolation: false, - } + icon: iconPath }); win.loadURL("https://gitee.com/qyg2297248353/iyuuplus-windows/issues"); win.on("closed", () => { @@ -69,20 +78,28 @@ let template = [ let win = new BrowserWindow({ width: 800, height: 600, - icon: iconPath, - webPreferences: { - nodeIntegration: true, - contextIsolation: false, - } + icon: iconPath }); - win.loadURL("https://lifebus.top/"); + win.loadURL("https://blog.lifebus.top/"); win.on("closed", () => { win = null; }); } }, { - label: "关于" + label: "关于", + click: () => { + app.setAboutPanelOptions({ + applicationName: "IYUU Plus Windows", + applicationVersion: version, + version: version, + copyright: "新疆萌森软件开发工作室", + authors: ["新疆萌森软件开发工作室", "大卫"], + website: "https://blog.lifebus.top/", + iconPath: iconPngPath + }) + app.showAboutPanel() + } } ] } diff --git a/package.json b/package.json index 47ac090..8c11d95 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "iyuu-plus", - "version": "1.0.0", + "version": "1.1.0", "description": "基于特征码的索引工具", "main": "main.js", "scripts": { @@ -13,7 +13,11 @@ "url": "https://gitee.com/qyg2297248353/iyuuplus-windows.git" }, "keywords": [ - "iyuu" + "iyuu", + "辅种", + "种子", + "pt", + "计划任务" ], "author": "新疆萌森软件开发工作室", "license": "MIT", @@ -31,7 +35,6 @@ "dependencies": { "electron-log": "^5.1.5", "electron-squirrel-startup": "^1.0.1", - "jquery": "^3.7.1", "tree-kill": "^1.2.2" } }