Friday, September 23, 2011

[android-developers] Re: Async Task, rotation and indeterminate progressbar in custom header.

AsyncTasks are a nifty tool but they have a fairly limited specific
set of uses. The previous responses have pointed out a several
problems with this code: you can't keep static refs to Activites or
Views, multiple Activities can't share a progress bar, etc.

I don't understand the use case, but I agree with Mark that, from the
code you've supplied, this might be better done as an IntentService or
as a pair of Fragments.

I'm going to be giving a Webinar on the pitfalls surrounding
AsyncTasks next week, on the 29th:

http://oreillynet.com/pub/e/2061

-blake
Programming Android, FTW!
http://oreilly.com/catalog/0636920010364

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