uavsim.graphics.instruments.navcommselector
Class NavCommSelector
java.lang.Object
uavsim.graphics.instruments.A_Instrument
uavsim.graphics.instruments.A_RectangularInstrument
uavsim.graphics.instruments.navcommselector.NavCommSelector
- All Implemented Interfaces:
- java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.util.EventListener, javax.swing.event.MouseInputListener
public class NavCommSelector
- extends A_RectangularInstrument
Defines a nav/comm selector to route receivers to instruments. This has been deferred because the CMPS 450 approach needs to be
more direct for simplicity. This dynamic approach involves excessive polymorphism.
- Author:
- Dan Tappan [15.09.11]
| Methods inherited from class uavsim.graphics.instruments.A_Instrument |
getAnchor, getCanvasSize, getGraphics, getID, getParentComponent, handleControlCallback, hasControls, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, refresh, registerControl, setCanvasAnchor, setCanvasSize, setParentComponent |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
_map
private final java.util.Map<java.lang.String,NavCommSwitchMapping> _map
- zzz receiver ID mapped to actual sender from list of potential
FACEPLATE
private static final RectangularFaceplaceDescriptor FACEPLATE
- the faceplace
TARGET_TEXT
private static final TextProperties TARGET_TEXT
- the text properties of the distance
NavCommSelector
public NavCommSelector(java.lang.String id,
int canvasSize,
CoordinateCartesianAbsolute canvasAnchor,
java.util.List<NavCommSwitchMapping> mappings)
- Creates a nav/comm selector.
- Parameters:
id - - the unique instrument identifiercanvasSize - - the square size of the instrument footprint in pixelscanvasAnchor - - the anchor position for the center of the canvas in pixelsmappings - - the switch mappings from sources (receivers) to targets (instruments)