1 Star 0 Fork 2

tela / 三菱1E_3E通讯库Node.js

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
main.js 860 Bytes
一键复制 编辑 原始数据 按行查看 历史
const { app, BrowserWindow } = require("electron");
const { Notification } = require("electron");
function showNotification() {
const notification = {
title: "w10通知消息",
body: "程序正在运行",
};
new Notification(notification).show();
}
function createWindow() {
const win = new BrowserWindow({
width: 1000,
height: 900,
webPreferences: {
nodeIntegration: true, //允许新开窗口支持Node环境
enableRemoteModule: true,
nativeWindowOpen: true,
contextIsolation: false,
},
});
win.loadFile("pages/index.html");
}
app.whenReady().then(createWindow).then(showNotification);
app.on("window-all-closed", () => {
if (process.platform !== "darwin") {
app.quit();
}
});
app.on("activate", () => {
if (BrowserWindow.getAllWindows().length === 0) {
createWindow();
}
});
1
https://gitee.com/aemedc/melsec.git
git@gitee.com:aemedc/melsec.git
aemedc
melsec
三菱1E_3E通讯库Node.js
master

搜索帮助