Skip to content

Commit

Permalink
add onGetNotInCache
Browse files Browse the repository at this point in the history
  • Loading branch information
Trinea committed Jan 4, 2014
1 parent 21c6d5c commit 1c73500
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/cn/trinea/android/demo/ImageCacheDemo.java
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,11 @@ public void onGetFailed(String imageUrl, Drawable imageDrawable, View view, Fail
.append(failedReason.getFailedType()).append(", failed reason is: ")
.append(failedReason.getCause().getMessage()).toString());
}

@Override
public void onGetNotInCache(String imageUrl, View view) {
// you can do something when image not in cache, for example set default image
}
};
IMAGE_CACHE.setOnImageCallbackListener(imageCallBack);
IMAGE_CACHE.setCacheFullRemoveType(new RemoveTypeLastUsedTimeFirst<Drawable>());
Expand Down

0 comments on commit 1c73500

Please sign in to comment.