Operation name Bug fix

This commit is contained in:
naibo 2023-03-27 00:01:26 +08:00
parent 6f9757d4dc
commit 8c418d10f3
3 changed files with 5 additions and 5 deletions

View File

@ -107,13 +107,13 @@ async function beginInvoke(msg) {
flowchart_window.loadURL(url); flowchart_window.loadURL(url);
} }
mainWindow.hide(); mainWindow.hide();
const window = windowManager.getActiveWindow();
// Prints the currently focused window bounds. // Prints the currently focused window bounds.
console.log(window);
// This method has to be called on macOS before changing the window's bounds, otherwise it will throw an error. // This method has to be called on macOS before changing the window's bounds, otherwise it will throw an error.
// It will prompt an accessibility permission request dialog, if needed. // It will prompt an accessibility permission request dialog, if needed.
if(!process.platform == "linux" && !process.platform == "darwin"){ if(process.platform != "linux" && process.platform != "darwin"){
const {windowManager} = require("node-window-manager"); const {windowManager} = require("node-window-manager");
const window = windowManager.getActiveWindow();
console.log(window);
windowManager.requestAccessibility(); windowManager.requestAccessibility();
// Sets the active window's bounds. // Sets the active window's bounds.
let size = screen.getPrimaryDisplay().workAreaSize let size = screen.getPrimaryDisplay().workAreaSize

View File

@ -271,7 +271,7 @@ function addElement(op, para) {
if (option == 1) { //打开网页选项 if (option == 1) { //打开网页选项
title = "Open Page"; title = "Open Page";
} else { } else {
title = $(".options")[option - 2].innerHTML; //获取新增操作名称 title = $(".options")[option - 1].innerHTML; //获取新增操作名称
} }
toolBoxKernel(null, para); toolBoxKernel(null, para);

View File

@ -271,7 +271,7 @@ function addElement(op, para) {
if (option == 1) { //打开网页选项 if (option == 1) { //打开网页选项
title = "打开网页"; title = "打开网页";
} else { } else {
title = $(".options")[option - 2].innerHTML; //获取新增操作名称 title = $(".options")[option - 1].innerHTML; //获取新增操作名称
} }
toolBoxKernel(null, para); toolBoxKernel(null, para);