Load files when in args
This commit is contained in:
parent
8b01314f43
commit
5b62163c4e
@ -40,7 +40,8 @@ const createWindow = (startType = "build", debug = false, args = []) => {
|
||||
});
|
||||
|
||||
win.once('ready-to-show', () => {
|
||||
win.show()
|
||||
win.show();
|
||||
win.webContents.send('load-files', args);
|
||||
});
|
||||
|
||||
menu.load(win);
|
||||
|
@ -6,6 +6,7 @@ contextBridge.exposeInMainWorld('electron', {
|
||||
chrome: () => process.versions.chrome,
|
||||
electron: () => process.versions.electron,
|
||||
});
|
||||
|
||||
contextBridge.exposeInMainWorld('main', {
|
||||
onMenuActions: (callback) => ipcRenderer.on('menu-actions', (_event, action) => callback(action)),
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user