![macos 程序意外退出](https://i-blog.csdnimg.cn/blog_migrate/90185dae651ea4d43eed386e551cd830.png)
macos 程序意外退出
![](https://i-blog.csdnimg.cn/blog_migrate/40b67bd5f1e0e994c25cb84afcec2c79.png)
To quit an app on a Mac, you can just press Command+Q on your keyboard. This however, can lead to unintended consequences, namely accidentally quitting apps if your fingers are in the wrong place.
要在Mac上退出某个应用,只需按键盘上的Command + Q。 但是,这可能会导致意想不到的后果,即如果手指放在错误的位置,则会意外退出应用程序 。
A while back, Chrome introduced a feature that let you switch to a “slow quit”, requiring you to hold Command+Q for a few seconds before an app would actually quit. If you like this feature, and want it in your other Mac apps, there is a third-party utility that can help you do so.
不久前,Chrome推出了一项功能,可让您切换到“缓慢退出”状态,要求您按住Command + Q几秒钟才能真正退出应用程序。 如果您喜欢此功能,并希望在其他Mac应用程序中使用它,则可以使用第三方实用程序来帮助您。
It’s called SlowQuitApps, and you can find the latest stable releases on this page. Keep in mind that this app is still very much in beta and may not be feature-complete. In our test, it proved to be stable enough and worked as intended, however.
它称为SlowQuitApps ,您可以在此页面上找到最新的稳定版本 。 请记住,此应用仍处于测试阶段,可能功能不完整。 在我们的测试中,事实证明它足够稳定并且可以按预期工作。
Download SlowQuitApps from the link above, then install it by dragging SlowQuitApps it into your Applications folder.
从上面的链接下载SlowQuitApps,然后通过将SlowQuitApps拖到“应用程序”文件夹中进行安装。
![](https://i-blog.csdnimg.cn/blog_migrate/3112b618899469e3f58a23c4d2bfcdf3.png)
The first time you launch SlowQuitApps, it will ask you if you want to automatically launch it when you log in. We clicked “Yes”. You can always change this at a later time.
首次启动SlowQuitApps时,它将询问您是否要在登录时自动启动它。我们单击“是”。 您随时可以在以后更改它。
![](https://i-blog.csdnimg.cn/blog_migrate/7fe6f6cd4da363c5f060b16b259e36b7.png)
Once installed, SlowQuitApps will act as an intermediary between you and Command+Q. When you press Command+Q, a black countdown overlay will appear on top of your app. This overlay will count down until the application quits, or you release the keyboard shortcut.
安装完成后,SlowQuitApps将充当您和Command + Q之间的中介。 当您按Command + Q时,黑色的倒计时叠加层将出现在您的应用程序顶部。 在应用程序退出之前,该覆盖层将递减计数,或者您释放键盘快捷键。
In other words, it will abort quitting the application if you release Command+Q before the countdown completes.
换句话说,如果您在倒计时完成之前释放Command + Q,它将中止退出应用程序。
![](https://i-blog.csdnimg.cn/blog_migrate/795915c646a5224443afe7f04572db08.png)
You can also adjust the delay if you prefer. By default, it is set to quit applications after 2 seconds, but you can make that longer or shorter by opening the Terminal and typing the following command and hitting “Enter”:
您也可以根据需要调整延迟时间。 默认情况下,它设置为2秒后退出应用程序,但是您可以通过打开“终端”并键入以下命令并单击“ Enter”来延长或缩短该应用程序:
$ defaults write com.dteoh.SlowQuitApps delay 5000
You want to change the value after “delay” accordingly. This value is in milliseconds, so if you want the delay to be 10 seconds, you’d use “10000”, as seen in the following screenshot.
您要相应地在“延迟”之后更改值。 该值以毫秒为单位,因此,如果您希望延迟时间为10秒,则可以使用“ 10000”,如以下屏幕截图所示。
![](https://i-blog.csdnimg.cn/blog_migrate/33221a047b0b3aca7dd179f191423590.png)
Finally, to uninstall SlowQuitApps, delete it from your Applications folder.
最后,要卸载SlowQuitApps,请从“应用程序”文件夹中将其删除。
To change whether it runs when you login, open your System Preferences, then click “Users & Groups”.
要更改其在登录时是否运行,请打开“系统偏好设置”,然后单击“用户和组”。
![](https://i-blog.csdnimg.cn/blog_migrate/013f467bbb2f02ef8145b9b8e81d5f7d.png)
Click on your user profile, then click the “Login Items” tab. You have two options, you can uncheck the box next to this item to temporarily disable it, or you can remove it altogether by selecting it and then clicking the small “-” symbol as shown by the red arrow.
单击您的用户个人资料,然后单击“登录项目”选项卡。 您有两个选项,您可以取消选中该项目旁边的框以暂时禁用它,也可以通过选择它然后单击红色箭头所示的小“-”符号将其完全删除。
Note, this does not remove the application from your computer, it simply stops it from launching when you log in.
请注意,这不会从计算机中删除该应用程序,只会在您登录时阻止其启动。
![](https://i-blog.csdnimg.cn/blog_migrate/0e86880bece57907eff68557d4004f67.png)
Just keep in mind, disabling or removing the login item means that SlowQuitApps won’t start automatically unless you re-add the login item or reinstall the app.
请记住,禁用或删除登录项意味着SlowQuitApps不会自动启动,除非您重新添加登录项或重新安装该应用程序。
The other thing to know is that SlowQuitApps doesn’t work when you Command+Q from the app switcher (Command+Tab).
要知道的另一件事是,当您从应用程序切换器(Command + Tab)进行Command + Q时,SlowQuitApps不起作用。
![](https://i-blog.csdnimg.cn/blog_migrate/35d9be260c62edb338efa557e02ec7be.png)
Hopefully, the developer will add this option in a future release.
希望开发人员在将来的版本中添加此选项。
For now however, it should significantly reduce the number of applications you accidentally quit, just be sure to set the delay long enough for you to react.
但是,现在,它应该可以大大减少意外退出的应用程序的数量,只需确保将延迟设置足够长的时间,以便您做出React。
翻译自: https://www.howtogeek.com/263342/how-to-hold-commandq-to-slow-quit-apps-in-macos/
macos 程序意外退出