()
| 118 | }; |
| 119 | |
| 120 | const focusMainWindow = () => { |
| 121 | const window = liveMainWindow(); |
| 122 | if (!window) { |
| 123 | if (connection) void createWindow(connection); |
| 124 | return; |
| 125 | } |
| 126 | if (window.isMinimized()) window.restore(); |
| 127 | if (!window.isVisible()) window.show(); |
| 128 | window.focus(); |
| 129 | }; |
| 130 | |
| 131 | const ensureSingleInstance = () => { |
| 132 | if (!app.requestSingleInstanceLock()) { |
no test coverage detected