mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2025-07-20 11:33:06 +00:00
Reduce the size of the LRU cache by 2
This commit is contained in:
parent
366a1c91b8
commit
c5293ef21f
@ -7,7 +7,7 @@ import com.limelight.LimeLog;
|
|||||||
|
|
||||||
public class MemoryAssetLoader implements CachedAppAssetLoader.CachedLoader {
|
public class MemoryAssetLoader implements CachedAppAssetLoader.CachedLoader {
|
||||||
private static final int maxMemory = (int) (Runtime.getRuntime().maxMemory() / 1024);
|
private static final int maxMemory = (int) (Runtime.getRuntime().maxMemory() / 1024);
|
||||||
private static final LruCache<String, Bitmap> memoryCache = new LruCache<String, Bitmap>(maxMemory / 4) {
|
private static final LruCache<String, Bitmap> memoryCache = new LruCache<String, Bitmap>(maxMemory / 8) {
|
||||||
@Override
|
@Override
|
||||||
protected int sizeOf(String key, Bitmap bitmap) {
|
protected int sizeOf(String key, Bitmap bitmap) {
|
||||||
// Sizeof returns kilobytes
|
// Sizeof returns kilobytes
|
||||||
|
Loading…
x
Reference in New Issue
Block a user