X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/3a8ff76d0a68d0ba18513c177b69bb8cb38e4189..32dadbcc6ca0de9924f216f81c6a124862ab3136:/src/com/owncloud/android/ui/adapter/DiskLruImageCache.java diff --git a/src/com/owncloud/android/ui/adapter/DiskLruImageCache.java b/src/com/owncloud/android/ui/adapter/DiskLruImageCache.java index 93efdf1c..5a53a866 100644 --- a/src/com/owncloud/android/ui/adapter/DiskLruImageCache.java +++ b/src/com/owncloud/android/ui/adapter/DiskLruImageCache.java @@ -1,5 +1,7 @@ -/* ownCloud Android client application - * Copyright (C) 2012-2014 ownCloud Inc. +/** + * ownCloud Android client application + * + * Copyright (C) 2015 ownCloud Inc. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2, @@ -118,10 +120,10 @@ public class DiskLruImageCache { } final InputStream in = snapshot.getInputStream( 0 ); if ( in != null ) { - final BufferedInputStream buffIn = + final BufferedInputStream buffIn = new BufferedInputStream( in, IO_BUFFER_SIZE ); - bitmap = BitmapFactory.decodeStream( buffIn ); - } + bitmap = BitmapFactory.decodeStream( buffIn ); + } } catch ( IOException e ) { e.printStackTrace(); } finally { @@ -191,4 +193,12 @@ public class DiskLruImageCache { e.printStackTrace(); } } + + public void setMaxSize(long maxSize){ + mDiskCache.setMaxSize(maxSize); + } + + public long getMaxSize(){ + return mDiskCache.getMaxSize(); + } } \ No newline at end of file