mirror of
https://github.com/finos/SymphonyElectron.git
synced 2024-11-27 03:10:36 -06:00
Electron-142 - Fixes the issue where it prevents creating multiple instances of the about window
This commit is contained in:
parent
b264331a54
commit
bb5ace404b
@ -44,6 +44,16 @@ function getTemplatePath() {
|
||||
* which this window should show
|
||||
*/
|
||||
function openAboutWindow(windowName) {
|
||||
|
||||
// This prevents creating multiple instances of the
|
||||
// about window
|
||||
if (aboutWindow) {
|
||||
if (aboutWindow.isMinimized()) {
|
||||
aboutWindow.restore();
|
||||
}
|
||||
aboutWindow.focus();
|
||||
return;
|
||||
}
|
||||
let allWindows = BrowserWindow.getAllWindows();
|
||||
allWindows = allWindows.find((window) => { return window.winName === windowName });
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user