1
0

Expose 'pick-folder' method in main.js using IPC

This commit is contained in:
2025-05-25 04:51:20 +02:00
parent c893170cd1
commit 884778b7ed

View File

@@ -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 …