Re: [android-developers] Re: close activity A that invoked activity B

2010-07-16 Thread Taoyi Guo
you just finish it . it works.

On Jul 16, 2010 12:14 AM, "Frank Weiss"  wrote:

Perhaps it should be the other way around.

Activity A, started by an external intent, checks to see if the T&C
needs to be displayed. Activity A then starts for result activity B.
If the result is affirmative, Activity A records the status and
proceeds, otherwise simple finishes, or goes into a fallback, such as
launching a exit activity.


Perhaps the T&C should be an alert dialog, which is modal (blocking
the Activity that launched it).


-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" ...

-- 
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

Re: [android-developers] Re: close activity A that invoked activity B

2010-07-16 Thread Taoyi Guo
you can put instance of activity a into application context, so activity b
can ref it.

On Jul 16, 2010 12:50 AM, "Boozel"  wrote:

Ya i wanted B to close A but it isnt possible so i just ended up
starting b for result and then closing a if the result was wrong.
Thanks for the help

On Jul 15, 7:26 pm, TreKing  wrote:

> On Thu, Jul 15, 2010 at 11:13 AM, Boozel  wrote:
> > another activity will ...
> TreKing  - Chicago

> transit tracking app for Android-powered devices

-- 
You received this message because you are su...

-- 
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: close activity A that invoked activity B

2010-07-15 Thread Boozel
Ya i wanted B to close A but it isnt possible so i just ended up
starting b for result and then closing a if the result was wrong.
Thanks for the help

On Jul 15, 7:26 pm, TreKing  wrote:
> On Thu, Jul 15, 2010 at 11:13 AM, Boozel  wrote:
> > another activity will launch my activity which is a set of terms and
> > conditions. if they are declined i want to close the terms and
> > conditions activity and the activity that launched the terms and
> > conditions activity.
>
> Ah, so you don't want B to close A, you want A to close itself based on the
> result of B.
>
> Do as Frank suggests.
>
> --- 
> --
> TreKing  - Chicago
> transit tracking app for Android-powered devices

-- 
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


Re: [android-developers] Re: close activity A that invoked activity B

2010-07-15 Thread TreKing
On Thu, Jul 15, 2010 at 11:13 AM, Boozel  wrote:

> another activity will launch my activity which is a set of terms and
> conditions. if they are declined i want to close the terms and
> conditions activity and the activity that launched the terms and
> conditions activity.
>

Ah, so you don't want B to close A, you want A to close itself based on the
result of B.

Do as Frank suggests.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

Re: [android-developers] Re: close activity A that invoked activity B

2010-07-15 Thread Frank Weiss
Perhaps it should be the other way around.

Activity A, started by an external intent, checks to see if the T&C
needs to be displayed. Activity A then starts for result activity B.
If the result is affirmative, Activity A records the status and
proceeds, otherwise simple finishes, or goes into a fallback, such as
launching a exit activity.


Perhaps the T&C should be an alert dialog, which is modal (blocking
the Activity that launched it).

-- 
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: close activity A that invoked activity B

2010-07-15 Thread Boozel
another activity will launch my activity which is a set of terms and
conditions. if they are declined i want to close the terms and
conditions activity and the activity that launched the terms and
conditions activity.

On Jul 15, 6:06 pm, TreKing  wrote:
> On Thu, Jul 15, 2010 at 10:56 AM, Boozel  wrote:
> > but i only want it to happen if a button is pressed
>
> What is the use case you are trying to solve? In other words, why do you
> want to do this?
>
> --- 
> --
> TreKing  - Chicago
> transit tracking app for Android-powered devices

-- 
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