Christine wrote:
> On Aug 15, 2:55 pm, Mark Murphy <[email protected]> wrote:
> 
>> By "posts a task", do you mean executes an AsyncTask, or something else?
> 
> I postDelayed a Runnable in a Handler.

Ick!

> I
> assumed that a Service would run at a lower priority than the Activity
> thread.

The Service *is* the Activity thread, unless you fork your own thread.
That's the "ick!" from above -- all the Handler/Runnable stuff does is
delay the processing, not put it on a background thread.

> Putting the Runnable in a thread with a priority one lower
> than the Service's thread seems to solve the problem - need more
> testing, but I haven't seen the popup yet.

Great!

> I will check out AsyncTask
> to see if that's a better solution than creating a thread.

If you do not need a long-lived thread, AsyncTask is nice for "fire and
forget" background work.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android App Developer Training: http://commonsware.com/training.html

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