mirror of
https://github.com/Kong/insomnia.git
synced 2026-04-22 23:28:33 -04:00
fix: set native menus per-window (#8444)
Previously when a new window was created `Menu.setApplicationMenu()` was called, which would change all windows' native menu to the newly created one - causing every window menu to reference the newly created `BrowserWindow`. Now each window is set their own `Menu` instance which will have their own `BrowserWindow`.
This commit is contained in:
@@ -699,7 +699,7 @@ export function createWindow({ firstLaunch }: { firstLaunch?: boolean } = {}): E
|
||||
template.push(developerMenu);
|
||||
}
|
||||
|
||||
Menu.setApplicationMenu(Menu.buildFromTemplate(template));
|
||||
mainBrowserWindow.setMenu(Menu.buildFromTemplate(template));
|
||||
return mainBrowserWindow;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user