Package org.openstreetmap.josm.gui
Class MapView.WarningLayerPainter
- java.lang.Object
-
- org.openstreetmap.josm.gui.MapView.WarningLayerPainter
-
- All Implemented Interfaces:
MapViewPaintable.LayerPainter
- Enclosing class:
- MapView
private static class MapView.WarningLayerPainter extends java.lang.Object implements MapViewPaintable.LayerPainter
A layer painter that issues a warning when being called.- Since:
- 10474
-
-
Field Summary
Fields Modifier and Type Field Description private Layerlayer(package private) booleanwarningPrinted
-
Constructor Summary
Constructors Constructor Description WarningLayerPainter(Layer layer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddetachFromMapView(MapViewPaintable.MapViewEvent event)Called when the layer is removed from the map view and this painter is not used any more.voidpaint(MapViewGraphics graphics)Paints the given layer.
-
-
-
Field Detail
-
warningPrinted
boolean warningPrinted
-
-
Constructor Detail
-
WarningLayerPainter
WarningLayerPainter(Layer layer)
-
-
Method Detail
-
paint
public void paint(MapViewGraphics graphics)
Description copied from interface:MapViewPaintable.LayerPainterPaints the given layer.This can be called in any thread at any time. You will not receive parallel calls for the same map view but you can receive parallel calls if you use the same
MapViewPaintable.LayerPainterfor different map views.- Specified by:
paintin interfaceMapViewPaintable.LayerPainter- Parameters:
graphics- The graphics object of the map view you should use. It provides you with a content pane, the bounds and the view state.
-
detachFromMapView
public void detachFromMapView(MapViewPaintable.MapViewEvent event)
Description copied from interface:MapViewPaintable.LayerPainterCalled when the layer is removed from the map view and this painter is not used any more.This method is called once on the painter returned by
AbstractMapViewPaintable.attachToMapView(org.openstreetmap.josm.gui.layer.MapViewPaintable.MapViewEvent)- Specified by:
detachFromMapViewin interfaceMapViewPaintable.LayerPainter- Parameters:
event- The event.
-
-