X-Git-Url: https://git.gag.com/?p=fw%2Faltos;a=blobdiff_plain;f=altosuilib%2FAltosSiteMapCache.java;h=51778ce1301d404ed1c70b444c91afab9603e032;hp=7f436ef0729b595da087f7c706098dd854fc4eca;hb=9f2189e0b99aa32b788ecb4576dcb9bcc926f4e2;hpb=5c3991768d3cb17fc99ad32b2d6d8d11f0e37dfa 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;