diff options
author | Scott Jackson <daneren2005@gmail.com> | 2014-04-01 18:20:02 -0700 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2014-04-01 18:20:02 -0700 |
commit | 60cd635f6d76e0e2484852555845e5ac6a5848bb (patch) | |
tree | 806ada2757c0e6bba49d51639c5fdf32c88558e1 /src/github/daneren2005 | |
parent | 73b5aa504418ddd8bb74318714b96629e9421b9e (diff) | |
download | dsub-60cd635f6d76e0e2484852555845e5ac6a5848bb.tar.gz dsub-60cd635f6d76e0e2484852555845e5ac6a5848bb.tar.bz2 dsub-60cd635f6d76e0e2484852555845e5ac6a5848bb.zip |
Don't try to recycle small size bitmaps
Diffstat (limited to 'src/github/daneren2005')
-rw-r--r-- | src/github/daneren2005/dsub/util/ImageLoader.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/github/daneren2005/dsub/util/ImageLoader.java b/src/github/daneren2005/dsub/util/ImageLoader.java index 37727891..c3008b3a 100644 --- a/src/github/daneren2005/dsub/util/ImageLoader.java +++ b/src/github/daneren2005/dsub/util/ImageLoader.java @@ -72,7 +72,9 @@ public class ImageLoader { protected void entryRemoved(boolean evicted, String key, Bitmap oldBitmap, Bitmap newBitmap) { if(evicted) { if(oldBitmap != nowPlaying) { - oldBitmap.recycle(); + if(sizeOf("", oldBitmap) > 500) { + oldBitmap.recycle(); + } } else { cache.put(key, oldBitmap); } |