+ painting = false;
+ }
+
+ public void paint(Graphics g) {
+ Graphics2D g2d = (Graphics2D) g;
+ Image image = null;
+ boolean queued = false;
+
+ if (painting) {
+ AltosSiteMap.debug_component(this, "already painting");
+ return;
+ }
+ AltosSiteMap.debug_component(this, "paint");
+
+ if (file != null) {
+ AltosSiteMapImage aimage;
+
+ aimage = AltosSiteMapCache.get_image(this, file, px_size, px_size);
+ if (aimage != null) {
+ if (aimage.validate())
+ image = aimage.image;
+ else
+ queued = true;
+ }
+ }
+ if (!queued)
+ paint_graphics(g2d, image);
+ painting = queued;