We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0d39d2b + 6a53a8c commit 4847c58Copy full SHA for 4847c58
src/main/common/registerHotKey.ts
@@ -61,7 +61,11 @@ const registerHotKey = (mainWindow: BrowserWindow): void => {
61
// 显示主窗口
62
function mainWindowPopUp() {
63
const currentShow = mainWindow.isVisible() && mainWindow.isFocused();
64
- if (currentShow) return mainWindow.hide();
+ if (currentShow) {
65
+ mainWindow.blur(); // 先失去焦点,使焦点恢复到之前的应用程序
66
+ mainWindow.hide();
67
+ return;
68
+ }
69
const { x: wx, y: wy } = winPosition.getPosition();
70
mainWindow.setAlwaysOnTop(false);
71
mainWindow.setVisibleOnAllWorkspaces(true, { visibleOnFullScreen: true });
0 commit comments