(root: string)
| 422 | } |
| 423 | |
| 424 | function findWindowForVaultRoot(root: string): BrowserWindow | null { |
| 425 | const target = path.resolve(root) |
| 426 | for (const win of BrowserWindow.getAllWindows()) { |
| 427 | if (win.isDestroyed() || !isWorkspaceWindow(win)) continue |
| 428 | const vault = windowVaults.vaultForWindow(win.id) |
| 429 | if (vault && path.resolve(vault.root) === target) return win |
| 430 | } |
| 431 | return null |
| 432 | } |
| 433 | |
| 434 | function queueMarkdownFileOpen(rawPath: string, reuseMainWindow: boolean): void { |
| 435 | pendingFileOpens.push({ absPath: path.resolve(rawPath), reuseMainWindow }) |
no test coverage detected