Cmd + w will quit atom when there is no window left behind


#1

I use atom on my mac. And I always use cmd + w to close windows.
But if I press cmd + w when there is no more window left behind, the atom application will be closed also.

How about only use cmd + q to quit and cmd + w to close window?
It’s just a suggestion.


#2

I can’t replicate this behavior using Atom v1.4.3 on Mac OS X 10.11.3. I have “Remove Empty Panes” and “Close Empty Windows” both enabled. Starting with an Atom window with the Settings View open:

  1. Pressing Cmd+W closes the Settings View
  2. Pressing Cmd+W again closes the window, but the application is still running
  3. Pressing Cmd+W again results in an error beep and the application continues to run

Only pressing Cmd+Q in this state will exit the program (or using the menus).


#3

Atom-version: 1.4.3
OS X: 10.10.5

I was able to reproduce it.
I started Atom fresh. An Untitled Tab was open, nothing else.

  1. Pressing CMD+W closed the untitled tab. At this time no tab is open. Hints are shown in the background.
  2. Pressing CMD+W again closes the whole application.

I also found out that this only happens if you have a certain setting active.
If you go to Preferences > Core Settings and have Close Empty Windows active, that’s where CMD+W also closes Atom if no other tab is open. Because there’s no tab left the command is being sent to the window.

Just deactivate the Close Empty Windows setting and you should be fine.


#4

I do that. And then I use ctrl-shift-W to close the window after all others are closed. It feels natural.


#5

Great! it works.


#6

I think this is a mistake of my description.
The process of atom is still running, but the atom window is closed and my project is closed too.
When I disabled the Close Empty Windows setting, cmd+w will only close file windows not application window. And that’s what I expect it to be.