Class AbstractRotateInteractor
java.lang.Object
org.apache.batik.swing.gvt.InteractorAdapter
org.apache.batik.swing.gvt.AbstractRotateInteractor
- All Implemented Interfaces:
KeyListener, MouseListener, MouseMotionListener, EventListener, Interactor
This class represents a rotate interactor.
To use it, just redefine the
InteractorAdapter.startInteraction(java.awt.event.InputEvent) method.-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected booleanWhether the interactor has finished.protected doubleThe initial rotation angle. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanTells whether the interactor has finished.voidInvoked when a mouse button is pressed on a component and then dragged.voidInvoked when the mouse exits a component.voidInvoked when a mouse button has been pressed on a component.voidInvoked when a mouse button has been released on a component.protected AffineTransformrotateTransform(Dimension d, int x, int y) Returns the rotate transform.Methods inherited from class InteractorAdapter
keyPressed, keyReleased, keyTyped, mouseClicked, mouseEntered, mouseMoved, startInteraction
-
Field Details
-
finished
protected boolean finishedWhether the interactor has finished. -
initialRotation
protected double initialRotationThe initial rotation angle.
-
-
Constructor Details
-
AbstractRotateInteractor
public AbstractRotateInteractor()
-
-
Method Details
-
endInteraction
public boolean endInteraction()Tells whether the interactor has finished.- Specified by:
endInteractionin interfaceInteractor- Overrides:
endInteractionin classInteractorAdapter
-
mousePressed
Invoked when a mouse button has been pressed on a component.- Specified by:
mousePressedin interfaceMouseListener- Overrides:
mousePressedin classInteractorAdapter
-
mouseReleased
Invoked when a mouse button has been released on a component.- Specified by:
mouseReleasedin interfaceMouseListener- Overrides:
mouseReleasedin classInteractorAdapter
-
mouseExited
Invoked when the mouse exits a component.- Specified by:
mouseExitedin interfaceMouseListener- Overrides:
mouseExitedin classInteractorAdapter
-
mouseDragged
Invoked when a mouse button is pressed on a component and then dragged. Mouse drag events will continue to be delivered to the component where the first originated until the mouse button is released (regardless of whether the mouse position is within the bounds of the component).- Specified by:
mouseDraggedin interfaceMouseMotionListener- Overrides:
mouseDraggedin classInteractorAdapter
-
rotateTransform
Returns the rotate transform.
-