Last active
July 8, 2020 19:30
-
-
Save leoramos086/57daac16b1e1e2ce5f1d23cc0f7430fe to your computer and use it in GitHub Desktop.
Códigos para Electron
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var shouldQuit = app.makeSingleInstance(function(commandLine, workingDirectory) { | |
| // Someone tried to run a second instance, we should focus our window. | |
| if (mainWindow) { | |
| if (mainWindow.isMinimized()) mainWindow.restore(); | |
| mainWindow.focus(); | |
| } | |
| }); | |
| if (shouldQuit) { | |
| app.quit(); | |
| return; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment