Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Introduction
- ## Activity
- Activity life cycle normally
- ```
- onCreate ->
- onStart ->
- onResume -> ...
- ```
- After we roate the device screen, the life cycle will continue as below...
- ```
- onSaveInstanceState –>
- onPause –>
- onStop –>
- onDestroy –>
- onCreate –>
- onStart –>
- onRestoreInstanceState –>
- onResume –> ...
- ```
- Then we rotate again...
- ```
- onSaveInstanceState –>
- onPause –>
- onStop –>
- onDestroy –>
- onCreate –>
- onStart –>
- onRestoreInstanceState –>
- onResume –>
- onSaveInstanceState –>
- onPause –>
- onStop –>
- onDestroy –>
- onCreate –>
- onStart –>
- onRestoreInstanceState –>
- onResume –>
- ```
- ## Fragment
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement