Class DispatchHandlerFX
java.lang.Object
org.jfree.chart.fx.interaction.AbstractMouseHandlerFX
org.jfree.chart.fx.interaction.DispatchHandlerFX
- All Implemented Interfaces:
MouseHandlerFX
Handles mouse move and click events on the
ChartCanvas by
dispatching ChartMouseEventFX events to listeners that are
registered with the ChartCanvas (listeners can also be registered
with a ChartViewer control).-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidhandleMouseClicked(ChartCanvas canvas, javafx.scene.input.MouseEvent e) Handles a mouse clicked event by setting the anchor point for the canvas and redrawing the chart (the anchor point is a reference point used by the chart to determine crosshair lines).voidhandleMouseMoved(ChartCanvas canvas, javafx.scene.input.MouseEvent e) Handles a mouse moved event by passing on an event to all registered listeners.voidhandleMousePressed(ChartCanvas canvas, javafx.scene.input.MouseEvent e) Handles a mouse pressed event by recording the location of the mouse pointer (so that later we can check that the click isn't part of a drag).Methods inherited from class org.jfree.chart.fx.interaction.AbstractMouseHandlerFX
getID, handleMouseDragged, handleMouseReleased, handleScroll, hasMatchingModifiers, isEnabled, setEnabled
-
Constructor Details
-
DispatchHandlerFX
Creates a new instance.- Parameters:
id- the id (nullnot permitted).
-
-
Method Details
-
handleMousePressed
Handles a mouse pressed event by recording the location of the mouse pointer (so that later we can check that the click isn't part of a drag).- Specified by:
handleMousePressedin interfaceMouseHandlerFX- Overrides:
handleMousePressedin classAbstractMouseHandlerFX- Parameters:
canvas- the chart canvas.e- the mouse event.
-
handleMouseMoved
Handles a mouse moved event by passing on an event to all registered listeners.- Specified by:
handleMouseMovedin interfaceMouseHandlerFX- Overrides:
handleMouseMovedin classAbstractMouseHandlerFX- Parameters:
canvas- the chart canvas (nullnot permitted).e- the mouse event.
-
handleMouseClicked
Handles a mouse clicked event by setting the anchor point for the canvas and redrawing the chart (the anchor point is a reference point used by the chart to determine crosshair lines).- Specified by:
handleMouseClickedin interfaceMouseHandlerFX- Overrides:
handleMouseClickedin classAbstractMouseHandlerFX- Parameters:
canvas- the chart canvas (nullnot permitted).e- the mouse event (nullnot permitted).
-