Android生命周期函数执行顺序
2024-09-06 16:27:18
转载自:http://blog.csdn.net/intheair100/article/details/39061473
程序正常启动:onCreate()->onStart()->onResume();
onCreate之后就会执行onStart,此时画面已经显示出来了,但还不能交互;然后执行onResume,此时可以与用户交互了。
正常退出:onPause()->onStop()->onDestory()
一个Activity启动另一个Activity: onPause()->onStop(), 再返回:onRestart()->onStart()->onResume()
程序按back 退出: onPause()->onStop()->onDestory(),再进入:onCreate()->onStart()->onResume();
程序按home 退出: onPause()->onStop(),再进入:onRestart()->onStart()->onResume();
最新文章
- linux-centos6.5之ssh配置
- 【项目】百度搜索广告CTR预估
- Linux下的SVN服务器搭建
- [转]Centos7下caffe的安装
- C# Rotating Oval
- C#中抽象类和接口
- 用户输入密码隐藏之getpass的使用
- 老李分享:pep8 python代码规范
- 简单背包问题(0032)-swust oj
- [Swift]LeetCode451. 根据字符出现频率排序 | Sort Characters By Frequency
- python 基础 列表
- D. Cutting Out 二分
- linux基本网络配置
- poj 1703 - Find them, Catch them【带权并查集】
- CentOS 服务器安全设置 --摘抄自https://www.kafan.cn/edu/8169544.html
- Homebrew替换源
- Sorted sets
- 计算服务器的pv量算法
- 洛谷 P1341 无序字母对 解题报告
- 给嵌入式ARM+Linux的初学者