Refactor code structure for improved readability and maintainability

This commit is contained in:
jhartworks
2026-06-16 12:00:27 +02:00
parent a65fc56b8c
commit a7f8bfb58f
7 changed files with 1596 additions and 426 deletions
+18
View File
@@ -59,6 +59,24 @@ ipcMain.handle("project:load", async () => {
return { canceled: false, filePath, data };
});
ipcMain.handle("audio:pickFile", async () => {
const result = await dialog.showOpenDialog({
properties: ["openFile"],
filters: [
{ name: "Audio", extensions: ["mp3", "m4a", "flac", "wma"] }
]
});
if (result.canceled || result.filePaths.length === 0) {
return { canceled: true };
}
return {
canceled: false,
filePath: result.filePaths[0]
};
});
app.whenReady().then(() => {
createWindow();