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

Prompt when there is no normal exit #11054

Closed
TCOTC opened this issue Apr 16, 2024 · 8 comments
Closed

Prompt when there is no normal exit #11054

TCOTC opened this issue Apr 16, 2024 · 8 comments
Assignees
Milestone

Comments

@TCOTC
Copy link
Contributor

TCOTC commented Apr 16, 2024

移动端未通过「退出应用」按钮退出,下次启动时提示

In what scenarios do you need this feature?

数据不知道为啥失踪了,有个笔记本包括里边的文档找不到了,我天天加班加懵逼了还是? - JeffreyChen 的回帖 - 链滴

建议还是加个提醒,99% 的 app 都是直接划掉退出的,既然思源这点不符合用户习惯,那么还是需要提醒一下。比如:进入 app 后,发现上次退出不是通过“退出应用”功能,提示不要这样做。

不然,恐怕 D 大你将要一次次不断提醒新用户这件事…

进入 app 后,发现上次退出不是通过“退出应用”功能,提示不要这样做。

感觉这个交互很合理,比如每次启动内核与点击「退出应用」都单独记录一下,下次启动根据记录来判断

毕竟大多数用户不会看完用户指南,还是需要软件主动提醒

Describe the optimal solution

移动端未通过「退出应用」按钮退出,下次启动时提示。

提示的内容像是这样:“检测到应用意外关闭。请使用菜单栏「退出应用」按钮退出应用,以免造成数据丢失。”

Describe the candidate solution

No response

Other information

No response

@Soltus
Copy link
Contributor

Soltus commented Apr 18, 2024

改进方向难道不应该是意外关闭的处理吗,即使你要求用户按规范使用菜单栏退出应用,意外关闭也是不可避免的

@TCOTC
Copy link
Contributor Author

TCOTC commented Apr 18, 2024

改进方向难道不应该是意外关闭的处理吗,即使你要求用户按规范使用菜单栏退出应用,意外关闭也是不可避免的

但问题是,意外关闭——都关闭了还能怎么处理?关闭的那一瞬间问题就发生了。所以只能尽量提醒用户。

这跟工作过程中电脑突然断电是一个道理,电源都没电了还能指望怎么处理?这次丢数据是铁定的了,只能看看以后能不能预防。

@Soltus
Copy link
Contributor

Soltus commented Apr 18, 2024

你用电脑断电类比是不恰当的,安卓应用是有对应的关闭事件的

@88250 88250 self-assigned this Apr 22, 2024
@88250
Copy link
Member

88250 commented Apr 22, 2024

你用电脑断电类比是不恰当的,安卓应用是有对应的关闭事件的

老铁给点提示,谢谢。

@Soltus
Copy link
Contributor

Soltus commented Apr 22, 2024

你用电脑断电类比是不恰当的,安卓应用是有对应的关闭事件的

老铁给点提示,谢谢。

应该是在 App 的 onActivityPreDestroyed 里处理,能不能成我没试过,稍等我去试试

@Soltus
Copy link
Contributor

Soltus commented Apr 22, 2024

应该是在 App 的 onActivityPreDestroyed 里处理,能不能成我没试过,稍等我去试试

试了一下onActivityPreDestroyed能处理的任务有限,onSaveInstanceState 更适合 @88250

@88250
Copy link
Member

88250 commented Apr 22, 2024 via email

@88250 88250 changed the title 移动端未通过「退出应用」按钮退出,下次启动时提示 Prompt did not exit normally Apr 23, 2024
@88250
Copy link
Member

88250 commented Apr 23, 2024

考虑了下,还是用内核来记录吧,这样桌面端也能用。

@88250 88250 added this to the 3.0.11 milestone Apr 23, 2024
@88250 88250 changed the title Prompt did not exit normally Prompt when there is no normal exit Apr 23, 2024
@88250 88250 closed this as completed Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants