g1bb wrote:
> Hi Mark,
>
> Sorry, I forgot to mention that I would like to destroy the activity
> from a different class not associated with the activity. Is that
> possible?
Provide that class with a reference to your Activity when you create it.
E.g.:
class ActivityKiller {
ActivityKiller(Activity victim) {
this.victim=victim;
}
void pussycatKillKill() {
victim.finish();
}
}
You will also need to arrange for background threads to close up shop,
including the thread your alternate class' code is running on, if that's
not the main UI thread.
--
Mark Murphy (a Commons Guy)
http://commonsware.com
Android Training on the Ranch! -- Mar 16-20, 2009
http://www.bignerdranch.com/schedule.shtml
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---