black screen appears when come back from an external application

十年热恋 提交于 2019-12-04 22:48:47

I think this is probably the normal Activity lifecycle at work.

Once your Activity goes into the background, it is deemed no longer critical by the OS and its process may be killed in order to reclaim memory or resources for a foreground Activity. The black screen you see when pressing the back button is the window background of your application's theme which appears while your Activity is recreated and its state is restored.

This is normal behavior. Ensure that your Activity saves and restores its state efficently by implementing the appropriate lifecycle methods to reduce the time it takes to re-create.

See http://developer.android.com/reference/android/app/Activity.html#ActivityLifecycle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!