public void onChange(Message msg) { if (KMLAbstractObject.MSG_LINK_CHANGED.Equals(msg.getName())) { this.renderable = null; } super.onChange(msg); }
public void applyChange(KMLAbstractObject sourceValues) { if (!(sourceValues is KMLScreenOverlay)) { String message = Logging.getMessage("nullValue.SourceIsNull"); Logging.logger().warning(message); throw new ArgumentException(message); } this.renderable = null; super.applyChange(sourceValues); }
protected void doPreRender(KMLTraversalContext tc, DrawContext dc) { if (this.getRenderable() == null) { this.initializeRenderable(tc); } KMLRenderable r = this.getRenderable(); if (r != null) { r.preRender(tc, dc); } }
protected void doRender(KMLTraversalContext tc, DrawContext dc) { // We've already initialized the screen image renderable during the preRender pass. Render the screen image // without any further preparation. KMLRenderable r = this.getRenderable(); if (r != null) { r.render(tc, dc); } // Render the feature balloon (if any) this.renderBalloon(tc, dc); }
/** * Create the renderable that will represent the overlay. * * @param tc the current KML traversal context. */ protected void initializeRenderable(KMLTraversalContext tc) { final String altitudeMode = this.getAltitudeMode(); if ("absolute".Equals(altitudeMode)) { this.renderable = new KMLGroundOverlayPolygonImpl(tc, this); } else // Default to clampToGround { // If the overlay has an icon, create a surface image renderable. Otherwise, create a surface polygon to // render the overlay as a colored polygon. if (this.getIcon() != null && this.getIcon().getHref() != null) { this.renderable = new KMLSurfaceImageImpl(tc, this); } else { this.renderable = new KMLSurfacePolygonImpl(tc, this); } } }
/** * Create the renderable that will represent the overlay. * * @param tc the current KML traversal context. */ protected void initializeRenderable(KMLTraversalContext tc) { renderable = new KMLScreenImageImpl(tc, this); }