From 884778b7edb9e2541d003ccda40f3113203a3f2b Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Sun, 25 May 2025 04:51:20 +0200 Subject: [PATCH] Expose 'pick-folder' method in main.js using IPC --- main.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/main.js b/main.js index 71a1a39..57a4150 100644 --- a/main.js +++ b/main.js @@ -1104,7 +1104,12 @@ app.whenReady().then(() => { return folders.find(f => f.path === newPath); }); - + ipcMain.handle('pick-folder', async () => { + const result = await dialog.showOpenDialog({ + properties: ['openDirectory'] + }); + return result.canceled ? null : result.filePaths; + }); // … Ende der IPC-Handler …