-
Notifications
You must be signed in to change notification settings - Fork 15.8k
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
Event when app is becoming active #2444
Comments
This looks like it might be relevant: http://cocoadev.com/DifferentTypesOfAppActivation |
This is expected since the term "activate" on OS X means the application is activated by clicking on the dock icon, what you want should be a new "active" or "focus" event that emitted when application is becoming active by Cmd+Tab or other means. |
This has been fixed by adding the |
@zcbenz Wait, sorry - how does that fix it? I just checked, and the |
same problem as @ialexryan |
Had same problem, just checked what Atom does. |
Can this be reopened? My understanding is that my original issue still stands, although I'm no longer in a position to conveniently verify this with the latest Electron build. |
@ialexryan @moonwave99 @loki951753 It's there on latest build. Btw no application provide this feature. This issue exists even on telegram app (built on objective c). Same goes with chrome. So I guess this is standard behaviour (activate app only on click not on cmd+tab). Temporary fix - Start tabbing with |
Hello, for anyone who stumbles across this, I was also seeing that the I wanted my electron to open its only window when the user brings the app back to the foreground. I noticed that github desktop uses this approach, and it worked for me. You have to use
Where |
As explained above, the There are two ways to fix the UX.
|
Steps to reproduce:
Issue: the "activate-with-no-open-windows" event is only triggered if I return to the app by clicking on the dock icon, not by Cmd+Tab'ing.
The text was updated successfully, but these errors were encountered: