Beispiel #1
0
 BitmapCache(Context ctx, DiskCache diskCache, bool useRoundCorners)
 {
     this.context = ctx;
     this.useRoundCorners = useRoundCorners;
     this.diskCache = diskCache;
     var highWatermark = Java.Lang.Runtime.GetRuntime().MaxMemory() / 3;
     var lowWatermark = highWatermark / 2;
     this.memCache = new ReuseBitmapDrawableCache (highWatermark, lowWatermark, highWatermark);
 }
Beispiel #2
0
        BitmapCache(Context ctx, DiskCache diskCache, bool useRoundCorners)
        {
            this.context         = ctx;
            this.useRoundCorners = useRoundCorners;
            this.diskCache       = diskCache;
            var highWatermark = Java.Lang.Runtime.GetRuntime().MaxMemory() / 3;
            var lowWatermark  = highWatermark / 2;

            this.memCache = new ReuseBitmapDrawableCache(highWatermark, lowWatermark, highWatermark);
        }
Beispiel #3
0
 public static BitmapCache CreateCache(Android.Content.Context ctx, string cacheName, string version = "1.0")
 {
     return(new BitmapCache(DiskCache.CreateCache(ctx, cacheName, version)));
 }
Beispiel #4
0
 BitmapCache(DiskCache diskCache)
 {
     this.diskCache = diskCache;
     this.memCache  = new LRUCache <string, Bitmap> (10);
 }
Beispiel #5
0
 public static BitmapCache CreateCache(Context ctx, string cacheName, string version = "1.0", bool useRoundCorners = true)
 {
     return(new BitmapCache(ctx, DiskCache.CreateCache(ctx, cacheName, version), useRoundCorners));
 }
Beispiel #6
0
		BitmapCache (DiskCache diskCache)
		{
			this.diskCache = diskCache;
			this.memCache = new LRUCache<string, Bitmap> (10);
		}