想象一下,我有活性的,我开始从一个新的b活动。
Imagine that I have an Activity A and I'm starting a new activity B from that one.
会有什么活动周期并排侧?
1. A: onCreate
2. A: onStart
3. A: onResume
在A => startActivity(B)
on A => startActivity(B)
4. B: onCreate
5. B: onStart
6. A: onPause
7. B: onResume
8. A: onStop
这是正确的?
Is this correct?
几乎正确的,只是一个微小的差别。第一A.onPause(),然后B.onCreate()...等
Almost correct, just a minor difference. first A.onPause() and then B.onCreate()... etc
A: onCreate
A: onStart
A: onResume
在A => startActivity(B)
on A => startActivity(B)
A: onPause
B: onCreate
B: onStart
B: onResume
A: onStop
检查该链接,完整的细节
Check this link for complete details
http://developer.android.com/guide/topics/fundamentals/activities.html#CoordinatingActivities