I am testing an application where we have a list view with list of images retrieved over network. When i run the application on android device 2.3.3 (WIFI speed 512 KBPS) an
You can use the AsyncTaskCompat.executeInParallel for API < 11, you find this class in the appcompat v4 library.
An exemple of use :
AsyncTaskCompat.executeParallel(new AsyncTask() {
@Override
protected Bitmap doInBackground(Void... params) {
return MediaStore.Images.Thumbnails.getThumbnail(
imageView.getContext().getContentResolver(),
id,
MediaStore.Images.Thumbnails.MINI_KIND,
null);
}
@Override
protected void onPostExecute(Bitmap bitmap) {
imageView.setImageBitmap(bitmap);
if (bitmap != null) {
// Add the image to the memory cache first
CACHE.put(id, bitmap);
if (listener != null) {
listener.onImageLoaded(bitmap);
}
}
}
});
enjoy