Question

What I do know is that the current activity get into the onPause() mode, and the home screen activity brought to front.

My confusion starts with situation you can re-open the application from the recent tasks menu. so what exactly happening when I'm opening the application from the recent tasks manager?

Is the activity that was foreground when the home button pressed is still somewhere in the stack?

Is there more then one activity stack on the same time?

Was it helpful?

Solution

As far as I understand it, there is no real stack (of applications). Is just that your activity has states, so whenever you are pressing the HOME button your activity in your current application just "pauses" like if it was a stand-by state so multiple applications can be in this state as long as the system doesnt require memory and kill the tasks. So whenever you open the activity from the recent tasks its just telling the application to wake up.

OTHER TIPS

First of all, here is everything you need to know about the concept of the "Up Button": Navigation with Back and Up and some of the implementation details: Providing Ancestral and Temporal Navigation.

Generally speaking, the Up button lets you navigate up in the application hierarchy, instead of just navigating back in the application(s) back-stack.

For example, if you work with some kind of app and you get the email notification, you can open the mail client by pressing the notification. Then you can go back to you application you were working with by pressing the Back button ( back-stack ) or you can press the Up button in order to go to the mail client's 'parent' activity ( for example from some EmailMessageActivity to EmailHomeActivity ) to work with the mail client application instead of the initial application ( the back-stack usually is cleared then, so you can only go back with the Back button as far as the the Android Home screen ).

The "Recent Tasks" factor is irrelevant and misleading, it's just another way of starting a new Activity.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top