리펙토링: Node.js 프로젝트 폴더 구조 적용

This commit is contained in:
2026-05-14 11:01:11 +09:00
parent 65ac35929a
commit dcd3c9a6e9
13 changed files with 4 additions and 4 deletions
+18
View File
@@ -0,0 +1,18 @@
const { ipcMain, dialog, shell } = require('electron');
function register(mainWindow) {
ipcMain.handle('select-folder', async () => {
const result = await dialog.showOpenDialog(mainWindow, {
properties: ['openDirectory'],
title: '이미지 폴더 선택',
});
if (result.canceled) return null;
return result.filePaths[0];
});
ipcMain.handle('reveal-folder', async (_event, folderPath) => {
shell.openPath(folderPath);
});
}
module.exports = { register };