Merge pull request #7986 from salomvary/fix-before-quit-docs
Clarify docs on a `before-quit` behavior edge case
This commit is contained in:
commit
cf690ae513
2 changed files with 8 additions and 0 deletions
|
@ -60,6 +60,10 @@ Emitted before the application starts closing its windows.
|
||||||
Calling `event.preventDefault()` will prevent the default behaviour, which is
|
Calling `event.preventDefault()` will prevent the default behaviour, which is
|
||||||
terminating the application.
|
terminating the application.
|
||||||
|
|
||||||
|
**Note:** If application quit was initiated by `autoUpdater.quitAndInstall()`
|
||||||
|
then `before-quit` is emitted *after* emitting `close` event on all windows and
|
||||||
|
closing them.
|
||||||
|
|
||||||
### Event: 'will-quit'
|
### Event: 'will-quit'
|
||||||
|
|
||||||
Returns:
|
Returns:
|
||||||
|
|
|
@ -121,6 +121,10 @@ using this API.
|
||||||
Restarts the app and installs the update after it has been downloaded. It
|
Restarts the app and installs the update after it has been downloaded. It
|
||||||
should only be called after `update-downloaded` has been emitted.
|
should only be called after `update-downloaded` has been emitted.
|
||||||
|
|
||||||
|
**Note:** `autoUpdater.quitAndInstall()` will close all application windows
|
||||||
|
first and only emit `before-quit` event on `app` after that. This is different
|
||||||
|
from the normal quit event sequence.
|
||||||
|
|
||||||
[squirrel-mac]: https://github.com/Squirrel/Squirrel.Mac
|
[squirrel-mac]: https://github.com/Squirrel/Squirrel.Mac
|
||||||
[server-support]: https://github.com/Squirrel/Squirrel.Mac#server-support
|
[server-support]: https://github.com/Squirrel/Squirrel.Mac#server-support
|
||||||
[squirrel-windows]: https://github.com/Squirrel/Squirrel.Windows
|
[squirrel-windows]: https://github.com/Squirrel/Squirrel.Windows
|
||||||
|
|
Loading…
Reference in a new issue