Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

quit app on linux/windows if the main window is closed #231

Merged
merged 4 commits into from Mar 2, 2018
Merged

quit app on linux/windows if the main window is closed #231

merged 4 commits into from Mar 2, 2018

Conversation

ghost
Copy link

@ghost ghost commented Feb 28, 2018

as i understood electron should quit the app automatically if all windows are closed. maybe hidden is not closed. i dont know, but this works well.

Fix for #228

@hql287
Copy link
Owner

hql287 commented Mar 1, 2018

@jens-t Thanks for the PR, just want to clarify this:

On macOS, the application will only quit if you press CMD+Q or select Quit App from the menu bar, so this is for Linux (probably Windows as well), right? If yes then I think we'll need a few conditional to make sure it behaves correctly on macOS.

@ghost
Copy link
Author

ghost commented Mar 1, 2018

Ok, makes sense. Didn't know that this is unwanted behaviour under osx. So i would say a simple condition for each of the 3 lines that checks that the platform is not osx would do it.

I add a commit for this later today.

@hql287 hql287 assigned hql287 and ghost and unassigned hql287 Mar 1, 2018
@ghost
Copy link
Author

ghost commented Mar 1, 2018

Changed the behavior as discussed in #233. Ready to merge :)
(Devtools are closed by the quit action)

@ghost ghost changed the title quit app if the last visible window is hidden quit app on linux/windows if the main window is closed Mar 1, 2018
@hql287 hql287 merged commit d7c5901 into hql287:dev Mar 2, 2018
@ghost ghost deleted the quit-app-bug branch March 2, 2018 11:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants