Use the fragment support library mentioned by Xav in a recent blog post.

Task == Application.  Each has its own stack.  Just look at how application
switching works.  That is tasks.  Saying "stack overflow exception" doesn't
make sense here, you will never get such an exception.  You may run out of
memory due to too many running activities, and your users may hate you for
letting them get deep down into different tasks that they have to press back
on to go where they want and don't understand how navigation through your
app works.  In this kind of thing, simpler is almost always betters.  Users
are very unlikely to understand complicated UI flow you build in to your
app.  Often Android's own UI flow is over complicated, and something that we
continually try to simplify.  Don't go off into the weeds making your app
complicated here.
 On May 7, 2011 2:48 PM, "Eric" <[email protected]> wrote:
>
>
> On May 7, 5:44 pm, Dianne Hackborn <[email protected]> wrote:
>> I would suggest that you  don't do this.  Tasks are for things the user
>> thinks of as applications -- things they launch from the home screen, see
in
>> the recent tasks list, etc.  If this is not what your application is,
>> abusing the facility for interaction within the app is likely just to
lead
>> to trouble and pain.
>>
>> My first suggestion would be to look at using fragments.  Alternatively,
>> there are Intent flags that allow you to move individual activities
within
>> your task's stack.
>
>
> OK, thank you. We can't use fragments because we need API level 7
> support. I'll look at the Activity re-ordering flags.
>
> But can you tell me if there is a separate history for Task switching
> (from my empirical testing there is), and whether or not that task
> switching history can overflow (like Activity stack can), or whether
> Android prevents it from overflowing by dropping old history?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to