Android Activity,back Stack Management

Source: Internet
Author: User

To summarize the default behavior for activities and tasks:

  • When activity a starts activity B, activity A was stopped, but the system retains it state (such as scroll position and TE XT entered into forms). If the user presses the back button and the activity B, activity A resumes with its state restored.
  • When the user leaves a task by pressing the Home button, the current activity was stopped and its task goes into T He background. The system retains the state of every activity in the task. If the user later resumes the task by selecting the launcher icon This began the task, the task comes to the foreground an D resumes the activity at the top of the stack.
  • If the user presses the back button, the current activity was popped from the stack and destroyed. The previous activity in the stack is resumed. When a activity is destroyed, the system does not retain the activity's state.
  • Activities can instantiated multiple times, even from other tasks.

Android Activity,back Stack Management

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.