[android-developers] Re: Activity stack: A B C - press BACK - go to A

2009-08-31 Thread Andrei Bucur
Maybe this helps:
http://developer.android.com/reference/android/content/Intent.html#FLAG_ACTIVITY_PREVIOUS_IS_TOP

On Mon, Aug 31, 2009 at 4:28 AM, tstanly tsai.sta...@gmail.com wrote:


 can possiable to verify whether B is exist or not?
 if B exist,so the apps can call finish() to close B,
 if not,don't call B.finish()
 (will be error because B is not exist)


 thanks!

 On 8月31日, 上午4時11分, Jonas Petersson jonas.peters...@xms.se wrote:
  fhucho wrote:
   my activity stack is ABC, in activity C I press back, and return to B,
   then press back again and go to A. What should I do to return to A
   directly from C?
 
  I guess it depends on the reason for wanting to skip B. I needed
  exactly this case yesterday and in my case B knows very well that it
  will not be needed when it starts up C, so B simply calls finish()
  after that. Solved.
 
  Best / Jonas
 


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



[android-developers] Re: Activity stack: A B C - press BACK - go to A

2009-08-30 Thread Jonas Petersson

fhucho wrote:
 my activity stack is ABC, in activity C I press back, and return to B,
 then press back again and go to A. What should I do to return to A
 directly from C?

I guess it depends on the reason for wanting to skip B. I needed 
exactly this case yesterday and in my case B knows very well that it 
will not be needed when it starts up C, so B simply calls finish() 
after that. Solved.

Best / Jonas


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



[android-developers] Re: Activity stack: A B C - press BACK - go to A

2009-08-30 Thread fhucho

Thanks. Good idea, I did it this way.

On Aug 30, 10:11 pm, Jonas Petersson jonas.peters...@xms.se wrote:
 fhucho wrote:
  my activity stack is ABC, in activity C I press back, and return to B,
  then press back again and go to A. What should I do to return to A
  directly from C?

 I guess it depends on the reason for wanting to skip B. I needed
 exactly this case yesterday and in my case B knows very well that it
 will not be needed when it starts up C, so B simply calls finish()
 after that. Solved.

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



[android-developers] Re: Activity stack: A B C - press BACK - go to A

2009-08-30 Thread tstanly

can possiable to verify whether B is exist or not?
if B exist,so the apps can call finish() to close B,
if not,don't call B.finish()
(will be error because B is not exist)


thanks!

On 8月31日, 上午4時11分, Jonas Petersson jonas.peters...@xms.se wrote:
 fhucho wrote:
  my activity stack is ABC, in activity C I press back, and return to B,
  then press back again and go to A. What should I do to return to A
  directly from C?

 I guess it depends on the reason for wanting to skip B. I needed
 exactly this case yesterday and in my case B knows very well that it
 will not be needed when it starts up C, so B simply calls finish()
 after that. Solved.

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