private CoverHolder getHolder(ImageView coverView, FBTree tree) { CoverHolder holder = (CoverHolder) coverView.getTag(); if (holder == null) { holder = new CoverHolder(this, coverView, tree.getUniqueKey()); coverView.setTag(holder); } else { holder.setKey(tree.getUniqueKey()); } return holder; }
void setCoverForView(CoverHolder holder, ZLLoadableImage image) { synchronized (holder) { try { final Bitmap coverBitmap = Cache.getBitmap(holder.Key); if (coverBitmap != null) { holder.CoverView.setImageBitmap(coverBitmap); } else if (holder.coverBitmapTask == null) { holder.coverBitmapTask = myPool.submit(holder.new CoverBitmapRunnable(image)); } } catch (CoverCache.NullObjectException e) { } } }