public class mxSelectionCellsHandler
extends java.lang.Object
implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener
Modifier and Type | Field and Description |
---|---|
protected java.awt.Rectangle |
bounds
Reference to the enclosing graph component.
|
static int |
DEFAULT_MAX_HANDLERS
Defines the default value for maxHandlers.
|
protected boolean |
enabled
Specifies if this handler is enabled.
|
protected mxGraphComponent |
graphComponent
Reference to the enclosing graph component.
|
protected java.util.LinkedHashMap<java.lang.Object,mxCellHandler> |
handlers
Maps from cells to handlers in the order of the selection cells.
|
protected java.beans.PropertyChangeListener |
labelMoveHandler |
protected int |
maxHandlers
Defines the maximum number of handlers to paint individually.
|
protected mxEventSource.mxIEventListener |
refreshHandler |
protected boolean |
visible
Specifies if this handler is visible.
|
Constructor and Description |
---|
mxSelectionCellsHandler(mxGraphComponent graphComponent) |
Modifier and Type | Method and Description |
---|---|
protected void |
addGraphListeners(mxGraph graph)
Installs the listeners to update the handles after any changes.
|
mxGraphComponent |
getGraphComponent() |
mxCellHandler |
getHandler(java.lang.Object cell) |
int |
getMaxHandlers() |
java.lang.String |
getToolTipText(java.awt.event.MouseEvent e)
Redirects the tooltip handling of the JComponent to the graph
component, which in turn may use getHandleToolTipText in this class to
find a tooltip associated with a handle.
|
boolean |
isEnabled() |
boolean |
isVisible() |
void |
mouseClicked(java.awt.event.MouseEvent arg0) |
void |
mouseDragged(java.awt.event.MouseEvent e) |
void |
mouseEntered(java.awt.event.MouseEvent arg0) |
void |
mouseExited(java.awt.event.MouseEvent arg0) |
void |
mouseMoved(java.awt.event.MouseEvent e) |
void |
mousePressed(java.awt.event.MouseEvent e)
Dispatches the mousepressed event to the subhandles.
|
void |
mouseReleased(java.awt.event.MouseEvent e) |
void |
paintHandles(java.awt.Graphics g) |
void |
refresh() |
protected void |
removeGraphListeners(mxGraph graph)
Removes all installed listeners.
|
void |
reset() |
void |
setEnabled(boolean value) |
void |
setMaxHandlers(int value) |
void |
setVisible(boolean value) |
public static int DEFAULT_MAX_HANDLERS
protected mxGraphComponent graphComponent
protected boolean enabled
protected boolean visible
protected java.awt.Rectangle bounds
protected int maxHandlers
protected transient java.util.LinkedHashMap<java.lang.Object,mxCellHandler> handlers
protected transient mxEventSource.mxIEventListener refreshHandler
protected transient java.beans.PropertyChangeListener labelMoveHandler
public mxSelectionCellsHandler(mxGraphComponent graphComponent)
graphComponent
- protected void addGraphListeners(mxGraph graph)
protected void removeGraphListeners(mxGraph graph)
public mxGraphComponent getGraphComponent()
public boolean isEnabled()
public void setEnabled(boolean value)
public boolean isVisible()
public void setVisible(boolean value)
public int getMaxHandlers()
public void setMaxHandlers(int value)
public mxCellHandler getHandler(java.lang.Object cell)
public void mousePressed(java.awt.event.MouseEvent e)
mousePressed
in interface java.awt.event.MouseListener
public void mouseMoved(java.awt.event.MouseEvent e)
mouseMoved
in interface java.awt.event.MouseMotionListener
public void mouseDragged(java.awt.event.MouseEvent e)
mouseDragged
in interface java.awt.event.MouseMotionListener
public void mouseReleased(java.awt.event.MouseEvent e)
mouseReleased
in interface java.awt.event.MouseListener
public java.lang.String getToolTipText(java.awt.event.MouseEvent e)
public void reset()
public void refresh()
public void paintHandles(java.awt.Graphics g)
public void mouseClicked(java.awt.event.MouseEvent arg0)
mouseClicked
in interface java.awt.event.MouseListener
public void mouseEntered(java.awt.event.MouseEvent arg0)
mouseEntered
in interface java.awt.event.MouseListener
public void mouseExited(java.awt.event.MouseEvent arg0)
mouseExited
in interface java.awt.event.MouseListener
Copyright (c) 2010-2017 Gaudenz Alder, JGraph Ltd. All rights reserved.