public static class ShapeEditingExtension.ShapeEditorExtension extends ShapeEditor
ShapeEditor
that knows how to operate on the custom shape
defined above.ShapeEditor.ControlPointMarker
accessoryLayer, active, activeOperation, angleControlPointAttributes, annotation, ANNOTATION, annotationLayer, armed, controlPointLayer, currentEvent, currentHeading, currentSizingMarker, extensionEnabled, HEIGHT, INNER_MAJOR_RADIUS, INNER_MINOR_RADIUS, INNER_RADIUS, LEFT_AZIMUTH, LEFT_WIDTH, LOCATION, locationControlPointAttributes, MOVING, NONE, originalAttributes, originalHighlightAttributes, OUTER_MAJOR_RADIUS, OUTER_MINOR_RADIUS, OUTER_RADIUS, previousPosition, RIGHT_AZIMUTH, RIGHT_WIDTH, ROTATION, shadowLayer, shape, sizeControlPointAttributes, SIZING, trackAdjacencyList, unitsFormat, WIDTH, wwd
Constructor and Description |
---|
ShapeEditorExtension(WorldWindow wwd,
Renderable shape) |
Modifier and Type | Method and Description |
---|---|
protected double |
doGetControlPointAltitude(LatLon location,
Renderable shape) |
protected Renderable |
doMakeShadowShape()
Creates the shape that's shown in the original position while the original shape is edited.
|
protected void |
doReshapeShape(ShapeEditor.ControlPointMarker controlPoint,
Position terrainPosition)
Called during editing when a control point is moved.
|
protected int |
getShapeAltitudeMode()
Indicates the current shape's altitude mode if the shape has one.
|
protected void |
reshapeArrow(ShapeEditor.ControlPointMarker controlPoint,
Position terrainPosition)
Edit the arrow according to the control point that is being moved.
|
protected void |
updateAnnotation(ShapeEditor.ControlPointMarker controlPoint)
Updates the annotation associated with a specified control point.
|
protected void |
updateArrowControlPoints()
Modify the control points to conform to the current state of the shape being edited.
|
protected void |
updateControlPoints()
Called during editing and moving to reposition the control points.
|
addNearestLocation, adjustShape, adjustTrackShape, appendLocation, computeControlPointDelta, computeEdgeLocation, computeRectangularEdgeLocation, determineTrackAdjacency, disable, dragWholeShape, enable, getAccessoryLayer, getActiveOperation, getAngleControlPointAttributes, getAnnotation, getAnnotationLayer, getControlPointAltitude, getControlPointLayer, getCurrentEvent, getCurrentHeading, getCurrentSizingMarker, getLocationControlPointAttributes, getOriginalAttributes, getOriginalHighlightAttributes, getPreviousPosition, getShadowLayer, getShape, getShapeCenter, getSizeControlPointAttributes, getUnitsFormat, getWwd, isActive, isArmed, isExtensionEnabled, isRadiiValid, makeControlPoint, makeControlPoint, makeControlPointAttributes, makeShadowShape, moveLocation, nearestPointOnSegment, normalizedHeading, propertyChange, removeShadowShape, reshapeCappedCylinder, reshapeCappedEllipticalCylinder, reshapeOrbit, reshapePolygonAirspace, reshapeRoute, reshapeShape, reshapeSphere, reshapeSurfaceCircle, reshapeSurfaceEllipse, reshapeSurfacePolygon, reshapeSurfaceQuad, reshapeSurfaceSquare, reshapeTrack, rotateLocations, selected, setArmed, setExtensionEnabled, setUnitsFormat, updateCappedCylinderControlPoints, updateCappedEllipticalCylinderControlPoints, updateOrbitControlPoints, updateOrientationLine, updatePartialCappedCylinderControlPoints, updatePolygonAirspaceControlPoints, updateRouteControlPoints, updateShapeAnnotation, updateSphereControlPoints, updateSurfaceCircleControlPoints, updateSurfaceEllipseControlPoints, updateSurfacePolygonControlPoints, updateSurfaceQuadControlPoints, updateSurfaceSquareControlPoints, updateTrackControlPoints
public ShapeEditorExtension(WorldWindow wwd, Renderable shape)
protected double doGetControlPointAltitude(LatLon location, Renderable shape)
doGetControlPointAltitude
in class ShapeEditor
protected Renderable doMakeShadowShape()
doMakeShadowShape
in class ShapeEditor
protected void doReshapeShape(ShapeEditor.ControlPointMarker controlPoint, Position terrainPosition)
doReshapeShape
in class ShapeEditor
controlPoint
- the control point selected.terrainPosition
- the terrain position under the cursor.protected int getShapeAltitudeMode()
ShapeEditor
getShapeAltitudeMode
in class ShapeEditor
WorldWind.ABSOLUTE
.protected void reshapeArrow(ShapeEditor.ControlPointMarker controlPoint, Position terrainPosition)
controlPoint
- the control point being moved by the user.terrainPosition
- the terrain position under the cursor.protected void updateAnnotation(ShapeEditor.ControlPointMarker controlPoint)
ShapeEditor
updateAnnotation
in class ShapeEditor
controlPoint
- the control point.protected void updateArrowControlPoints()
protected void updateControlPoints()
updateControlPoints
in class ShapeEditor