Class SatelliteScalingGraphMousePlugin
- java.lang.Object
-
- org.jungrapht.visualization.control.AbstractGraphMousePlugin
-
- org.jungrapht.visualization.control.ScalingGraphMousePlugin
-
- org.jungrapht.visualization.control.SatelliteScalingGraphMousePlugin
-
- All Implemented Interfaces:
MouseListener
,MouseWheelListener
,EventListener
,GraphMousePlugin
public class SatelliteScalingGraphMousePlugin extends ScalingGraphMousePlugin
Overrides ScalingGraphMousePlugin so that mouse events in the satellite view will cause scaling in the main view- Using only the mouse wheel, both the X-axis and Y-axis are scaled equally.
- If the CTRL key is pressed while the mouse wheel is turned, only the X-axis is scaled
- If the ALT key is pressed while the mouse wheel is turned, only the Y-axis is scaled
- Author:
- Tom Nelson
- See Also:
ScalingGraphMousePlugin
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.jungrapht.visualization.control.ScalingGraphMousePlugin
ScalingGraphMousePlugin.Builder
-
Nested classes/interfaces inherited from class org.jungrapht.visualization.control.AbstractGraphMousePlugin
AbstractGraphMousePlugin.Selecting
-
-
Field Summary
-
Fields inherited from class org.jungrapht.visualization.control.ScalingGraphMousePlugin
enableDoubleClickScaleReset, enableMiddleMouseButtonScaleReset, in, layoutScalingControl, out, pickSize, scaler, scalingMask, xAxisScalingMask, yAxisScalingMask, zoomAtMouse
-
Fields inherited from class org.jungrapht.visualization.control.AbstractGraphMousePlugin
cursor, down, modifiers
-
-
Constructor Summary
Constructors Constructor Description SatelliteScalingGraphMousePlugin(ScalingControl scaler, int scalingMask, int xAxisScalingMask, int yAxisScalingMask)
SatelliteScalingGraphMousePlugin(ScalingControl scaler, int scalingMask, int xAxisScalingMask, int yAxisScalingMask, float in, float out)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
mouseClicked(MouseEvent e)
Invoked when the mouse button has been clicked (pressed and released) on a component.void
mouseWheelMoved(MouseWheelEvent e)
zoom the master view display in or out, depending on the direction of the mouse wheel motion.-
Methods inherited from class org.jungrapht.visualization.control.ScalingGraphMousePlugin
builder, checkModifiers, getIn, getOut, getScaler, mouseEntered, mouseExited, mousePressed, mouseReleased, setIn, setOut, setScaler, setZoomAtMouse, singleEdgeSelection, singleVertexSelection
-
Methods inherited from class org.jungrapht.visualization.control.AbstractGraphMousePlugin
getCursor, getModifiersEx, setCursor, setModifiers
-
-
-
-
Constructor Detail
-
SatelliteScalingGraphMousePlugin
public SatelliteScalingGraphMousePlugin(ScalingControl scaler, int scalingMask, int xAxisScalingMask, int yAxisScalingMask)
-
SatelliteScalingGraphMousePlugin
public SatelliteScalingGraphMousePlugin(ScalingControl scaler, int scalingMask, int xAxisScalingMask, int yAxisScalingMask, float in, float out)
-
-
Method Detail
-
mouseWheelMoved
public void mouseWheelMoved(MouseWheelEvent e)
zoom the master view display in or out, depending on the direction of the mouse wheel motion.- Specified by:
mouseWheelMoved
in interfaceMouseWheelListener
- Overrides:
mouseWheelMoved
in classScalingGraphMousePlugin
-
mouseClicked
public void mouseClicked(MouseEvent e)
Description copied from class:ScalingGraphMousePlugin
Invoked when the mouse button has been clicked (pressed and released) on a component.- Specified by:
mouseClicked
in interfaceMouseListener
- Overrides:
mouseClicked
in classScalingGraphMousePlugin
- Parameters:
e
- the event to be processed
-
-