Code example for ColorDrawable

Methods: setImageDrawable

0
		Bitmap bitmap = memoryCache.get(url);
		if (bitmap != null) {
			imageView.setImageBitmap(bitmap);
		} else { 
			queuePhoto(url, imageView);
			imageView.setImageDrawable(new ColorDrawable(Color.WHITE));
		} 
	} 
 
	private void queuePhoto(String url, ImageView imageView) {
		PhotoToLoad p = new PhotoToLoad(url, imageView);
		executorService.submit(new PhotosLoader(p));
	} 
 
	private Bitmap getBitmap(String url, int size) {
		File f = fileCache.getFile(url);
 
		// from SD cache 
		Bitmap b = decodeFile(f, size);
		if (b != null)
			return b;