X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=altosuilib%2FAltosSiteMapCache.java;h=51778ce1301d404ed1c70b444c91afab9603e032;hb=73249dbf16382c91c2a220ff852a4f099fe0de3d;hp=7f436ef0729b595da087f7c706098dd854fc4eca;hpb=5c3991768d3cb17fc99ad32b2d6d8d11f0e37dfa;p=fw%2Faltos diff --git a/altosuilib/AltosSiteMapCache.java b/altosuilib/AltosSiteMapCache.java index 7f436ef0..51778ce1 100644 --- a/altosuilib/AltosSiteMapCache.java +++ b/altosuilib/AltosSiteMapCache.java @@ -158,7 +158,7 @@ public class AltosSiteMapCache { for (int i = 0; i < cache_size; i++) { if (i < new_size) new_images[i] = images[i]; - else + else if (images[i] != null) images[i].flush(); } images = new_images; @@ -176,6 +176,7 @@ public class AltosSiteMapCache { return new Point (x, y); } +/* private static void dump_cache() { int min_x = 1000, max_x = -1000, min_y = 1000, max_y = -1000; @@ -208,6 +209,7 @@ public class AltosSiteMapCache { System.out.printf("\n"); } } +*/ public static AltosSiteMapImage get_image(AltosSiteMapTile tile, File file, int width, int height) { int oldest = -1;