Directly modifying an adapter's data (especially changing the number of 
items) from a background thread is a recipe for disaster.

The data can be loaded on a thread, but should be switched in the adapter 
on the UI thread, followed by a call to notifyDatasetChanged, also on the 
UI thread.

-- K

On Monday, January 28, 2013 5:43:35 AM UTC+4, dashman wrote:
>
> nevermind - i decided to subl-class BaseAdapter
>
> Thanks.
>
>
> On Sunday, January 27, 2013 7:36:06 PM UTC-5, dashman wrote:
>>
>> mark,
>>
>> > You can modify the ArrayList directly from a background thread.
>>
>> How can i do that - i don't see any api for this.
>>
>>
>>
>>

-- 
-- 
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
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group, send email to 
android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to