Class SelectionInteractor
java.lang.Object
com.bc.ceres.swing.figure.AbstractInteractor
com.bc.ceres.swing.figure.ViewportInteractor
com.bc.ceres.swing.figure.FigureEditorInteractor
com.bc.ceres.swing.figure.interactions.SelectionInteractor
- All Implemented Interfaces:
Interactor,KeyListener,MouseListener,MouseMotionListener,EventListener
Interactor for selecting and moving figures and figure points.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classprotected classprotected classprotected classprotected static interface -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcancelInteraction(InputEvent event) protected SelectionInteractor.MoveHandleToolprotected SelectionInteractor.MoveSelectionToolprotected SelectionInteractor.SelectPointToolprotected SelectionInteractor.SelectRectangleToolprotected booleanisMouseOverSelection(MouseEvent event) voidkeyPressed(KeyEvent event) Invoked when a key has been pressed.voidkeyReleased(KeyEvent event) Invoked when a key has been released.voidmouseDragged(MouseEvent event) Invoked when a mouse button is pressed on a component and then dragged.voidmouseMoved(MouseEvent event) Invoked when the mouse cursor has been moved onto a component but no buttons have been pushed.voidmousePressed(MouseEvent event) Invoked when a mouse button has been pressed on a component.voidmouseReleased(MouseEvent event) Invoked when a mouse button has been released on a component.Methods inherited from class com.bc.ceres.swing.figure.FigureEditorInteractor
getFigureEditor, getViewportMethods inherited from class com.bc.ceres.swing.figure.ViewportInteractor
getModelToViewTransform, getViewToModelTransform, toModelPoint, toModelPoint, toModelShapeMethods inherited from class com.bc.ceres.swing.figure.AbstractInteractor
activate, addListener, deactivate, getCursor, getListeners, isActive, isLeftMouseButtonDown, isMultiButton1Click, isSingleButton1Click, keyTyped, mouseClicked, mouseEntered, mouseExited, removeListener, startInteraction, stopInteraction
-
Field Details
-
canceled
protected boolean canceled -
referencePoint
-
-
Constructor Details
-
SelectionInteractor
public SelectionInteractor()
-
-
Method Details
-
cancelInteraction
- Overrides:
cancelInteractionin classAbstractInteractor
-
mousePressed
Description copied from class:AbstractInteractorInvoked when a mouse button has been pressed on a component.The default implementation does nothing.
- Specified by:
mousePressedin interfaceMouseListener- Overrides:
mousePressedin classAbstractInteractor- Parameters:
event- The mouse event.
-
mouseDragged
Description copied from class:AbstractInteractorInvoked when a mouse button is pressed on a component and then dragged.MOUSE_DRAGGEDevents will continue to be delivered to the component where the drag originated until the mouse button is released (regardless of whether the mouse position is within the bounds of the component).Due to platform-dependent Drag&Drop implementations,
MOUSE_DRAGGEDevents may not be delivered during a native Drag&Drop operation.The default implementation does nothing.
- Specified by:
mouseDraggedin interfaceMouseMotionListener- Overrides:
mouseDraggedin classAbstractInteractor- Parameters:
event- The mouse event.
-
mouseReleased
Description copied from class:AbstractInteractorInvoked when a mouse button has been released on a component.The default implementation does nothing.
- Specified by:
mouseReleasedin interfaceMouseListener- Overrides:
mouseReleasedin classAbstractInteractor- Parameters:
event- The mouse event.
-
mouseMoved
Description copied from class:AbstractInteractorInvoked when the mouse cursor has been moved onto a component but no buttons have been pushed.The default implementation does nothing.
- Specified by:
mouseMovedin interfaceMouseMotionListener- Overrides:
mouseMovedin classAbstractInteractor- Parameters:
event- The mouse event.
-
keyPressed
Description copied from class:AbstractInteractorInvoked when a key has been pressed. See the class description forKeyEventfor a definition of a key pressed event.The default implementation does nothing.
- Specified by:
keyPressedin interfaceKeyListener- Overrides:
keyPressedin classAbstractInteractor- Parameters:
event- The key event.
-
keyReleased
Description copied from class:AbstractInteractorInvoked when a key has been released. See the class description forKeyEventfor a definition of a key released event.The default implementation does nothing.
- Specified by:
keyReleasedin interfaceKeyListener- Overrides:
keyReleasedin classAbstractInteractor- Parameters:
event- The key event.
-
createSelectPointTool
-
createSelectRectangleTool
-
createMoveSelectionTool
-
createMoveHandleTool
-
isMouseOverSelection
-