Tuesday, August 24, 2010

[android-developers] Re: How to check the Foreground Process from a Service

Ok maybe, I have the Activity Stack mannerism wrong. But the fact
that when you hit the back button it knows to go from your app, to
another app that's not your's, or to the home screen. Theirs a list
somewhere in memory for it to do this. By checking the foreground
from my service, is knowing that the user can do whatever they want
to. That's how I planned on turning off my app. So you don't have to
comeback to it, to turn it off.

the onCreate that I'm referring about is in my activity.

On Aug 24, 5:32 pm, Mark Murphy <mmur...@commonsware.com> wrote:
> On Tue, Aug 24, 2010 at 8:09 PM, Call_Waiting <team.mu.capt...@gmail.com> wrote:
> > I'm just trying to check from a service what's on the top of the
> > activity stack
>
> You assume there is one activity stack. Each task has a stack:
>
> http://developer.android.com/guide/topics/fundamentals.html#acttask
>
> You have no control over what tasks the user is using, because, like
> it or not, users can do what they want.
>
> > because the app starts another app instantly in
> > onCreate()
>
> onCreate() of...an activity? a service? a SQLiteOpenHelper? a
> ContentProvider? something else?
>
> > I'm looking to kill my service
> > automatically without having to comeback to my program at all.
>
> Why is there a service in the first place?
>
> --
> Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy
>
> _The Busy Coder's Guide to Android Development_ Version 3.1 Available!

--
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+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate