mirror of
https://github.com/JustusPlays78/SectorFileUpdater.git
synced 2025-04-29 10:10:57 +00:00
directory select small fix
This commit is contained in:
parent
9e09037955
commit
5a71d336fb
@ -65,8 +65,8 @@ const createWindow = () => {
|
||||
ipcMain.on('select-dirs', async(event, arg) => {
|
||||
filepath = await dialog.showOpenDialog(mainWindow, {
|
||||
properties: ['openDirectory']
|
||||
})
|
||||
console.log('directories selected', filepath.filePaths)
|
||||
});
|
||||
console.log('directories selected', filepath.filePaths);
|
||||
mainWindow.webContents.send("filepath", filepath.filePaths);
|
||||
// Save directory to file
|
||||
});
|
||||
|
@ -23,14 +23,12 @@ donwloadBtn.addEventListener('click', (e) => {
|
||||
|
||||
let directoryBtn = document.getElementById('dirs');
|
||||
directoryBtn.addEventListener('click', (e) => {
|
||||
window.postMessage({
|
||||
type: 'select-dirs'
|
||||
})
|
||||
ipcRenderer.send('select-dirs');
|
||||
});
|
||||
ipcRenderer.on("filepath", (event, file) => {
|
||||
document.getElementById('dirBox').value = file;
|
||||
});
|
||||
|
||||
ipcRenderer.on("filepath", (event, file) => {
|
||||
document.getElementById('dirBox').innerText = file;
|
||||
});
|
||||
|
||||
|
||||
// Check update
|
||||
|
Loading…
x
Reference in New Issue
Block a user