[Android] BitmapCache: add a clear method to free the cache

Ludovic Fauvet git at videolan.org
Wed Oct 17 12:34:19 CEST 2012


vlc-ports/android | branch: master | Ludovic Fauvet <etix at videolan.org> | Wed Oct 17 12:19:49 2012 +0200| [f630459d6a82cb74c350647700f517e71ed2465e] | committer: Ludovic Fauvet

BitmapCache: add a clear method to free the cache

> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=f630459d6a82cb74c350647700f517e71ed2465e
---

 vlc-android/src/org/videolan/vlc/BitmapCache.java |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/vlc-android/src/org/videolan/vlc/BitmapCache.java b/vlc-android/src/org/videolan/vlc/BitmapCache.java
index 13725b8..cc1fb60 100644
--- a/vlc-android/src/org/videolan/vlc/BitmapCache.java
+++ b/vlc-android/src/org/videolan/vlc/BitmapCache.java
@@ -84,4 +84,8 @@ public class BitmapCache {
     public void addBitmapToMemCache(int resId, Bitmap bitmap) {
         addBitmapToMemCache("res:" + resId, bitmap);
     }
+
+    public void clear() {
+        mMemCache.evictAll();
+    }
 }



More information about the Android mailing list