| 
 | JGraph X 2.1.0.7 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.mxgraph.swing.util.mxMouseAdapter
com.mxgraph.swing.handler.mxGraphHandler
public class mxGraphHandler
| Field Summary | |
|---|---|
| protected  mxRectangle | bboxScaled, translated bounding box of the selection cells. | 
| protected  boolean | canImport | 
| protected  Object | cell | 
| protected  mxRectangle | cellBoundsScaled, translated bounds of the selection cells. | 
| protected  Object[] | cellsHolds the cells that are being moved by this handler. | 
| protected  boolean | centerPreviewSpecifies if the preview should be centered around the mouse cursor if there was no mouse click to define the offset within the shape (eg. | 
| protected  boolean | cloneEnabledSpecifies if cloning by control-drag is enabled. | 
| protected  boolean | constrainedEventWorkaround for shift-key-state not correct in mouseReleased. | 
| protected  DropTarget | currentDropTargetReference to the current drop target. | 
| static Cursor | DEFAULT_CURSORDefault is Cursor.DEFAULT_CURSOR. | 
| protected  Object[] | dragCells | 
| protected  ImageIcon | dragImageHolds the image that is being used for the preview. | 
| protected  boolean | enabledSpecifies if the handler is enabled. | 
| protected  Point | firstHolds the start location of the mouse gesture. | 
| static Cursor | FOLD_CURSORDefault is Cursor.HAND_CURSOR. | 
| protected  mxGraphComponent | graphComponentReference to the enclosing graph component. | 
| protected  boolean | gridEnabledEventWorkaround for alt-key-state not correct in mouseReleased. | 
| protected  boolean | imagePreviewSpecifies if an image should be used for preview. | 
| protected  Object | initialCell | 
| protected  boolean | keepOnTopSpecifies if this handler should be painted on top of all other components. | 
| protected  boolean | livePreviewSpecifies if live preview should be used if possible. | 
| protected  mxCellMarker | marker | 
| protected  boolean | markerEnabledSpecifies if the cell marker should be called (for splitting edges and dropping cells into groups). | 
| static Cursor | MOVE_CURSORDefault is Cursor.MOVE_CURSOR. | 
| protected  boolean | moveEnabledSpecifies if moving is enabled. | 
| protected  mxMovePreview | movePreview | 
| protected  Rectangle | previewBounds | 
| protected  boolean | removeCellsFromParentSpecifies if cells may be moved out of their parents. | 
| protected  boolean | selectEnabledSpecifies if moving is enabled. | 
| protected  mxRectangle | transferBoundsUnscaled, untranslated bounding box of the selection cells. | 
| protected  boolean | visible | 
| Constructor Summary | |
|---|---|
| mxGraphHandler(mxGraphComponent graphComponent) | |
| Methods inherited from class com.mxgraph.swing.util.mxMouseAdapter | 
|---|
| mouseClicked, mouseEntered, mouseExited | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static Cursor DEFAULT_CURSOR
public static Cursor MOVE_CURSOR
public static Cursor FOLD_CURSOR
protected mxGraphComponent graphComponent
protected boolean enabled
protected boolean cloneEnabled
protected boolean moveEnabled
protected boolean selectEnabled
protected boolean markerEnabled
protected boolean removeCellsFromParent
protected mxMovePreview movePreview
protected boolean livePreview
protected boolean imagePreview
protected boolean centerPreview
protected boolean keepOnTop
protected transient Object[] cells
protected transient ImageIcon dragImage
protected transient Point first
protected transient Object cell
protected transient Object initialCell
protected transient Object[] dragCells
protected transient mxCellMarker marker
protected transient boolean canImport
protected transient mxRectangle cellBounds
protected transient mxRectangle bbox
protected transient mxRectangle transferBounds
protected transient boolean visible
protected transient Rectangle previewBounds
protected transient boolean gridEnabledEvent
protected transient boolean constrainedEvent
protected transient DropTarget currentDropTarget
| Constructor Detail | 
|---|
public mxGraphHandler(mxGraphComponent graphComponent)
graphComponent - | Method Detail | 
|---|
protected void installDragGestureHandler()
protected void installDropTargetHandler()
public boolean isVisible()
public void setVisible(boolean value)
public void setPreviewBounds(Rectangle bounds)
protected mxMovePreview createMovePreview()
public mxMovePreview getMovePreview()
protected mxCellMarker createMarker()
public mxGraphComponent getGraphComponent()
public boolean isEnabled()
public void setEnabled(boolean value)
public boolean isCloneEnabled()
public void setCloneEnabled(boolean value)
public boolean isMoveEnabled()
public void setMoveEnabled(boolean value)
public boolean isMarkerEnabled()
public void setMarkerEnabled(boolean value)
public mxCellMarker getMarker()
public void setMarker(mxCellMarker value)
public boolean isSelectEnabled()
public void setSelectEnabled(boolean value)
public boolean isRemoveCellsFromParent()
public void setRemoveCellsFromParent(boolean value)
public boolean isLivePreview()
public void setLivePreview(boolean value)
public boolean isImagePreview()
public void setImagePreview(boolean value)
public boolean isCenterPreview()
public void setCenterPreview(boolean value)
public void updateDragImage(Object[] cells)
public void mouseMoved(MouseEvent e)
mouseMoved in interface MouseMotionListenermouseMoved in class mxMouseAdapterprotected Cursor getCursor(MouseEvent e)
public void dragEnter(DropTargetDragEvent e)
dragEnter in interface DropTargetListenerpublic void mousePressed(MouseEvent e)
mousePressed in interface MouseListenermousePressed in class mxMouseAdapterpublic Object[] getCells(Object initialCell)
public void start(MouseEvent e)
public void dropActionChanged(DropTargetDragEvent e)
dropActionChanged in interface DropTargetListenerpublic void dragOver(DropTargetDragEvent e)
dragOver in interface DropTargetListenere - public Point convertPoint(Point pt)
public void mouseDragged(MouseEvent e)
mouseDragged in interface MouseMotionListenermouseDragged in class mxMouseAdapter
protected Point getPreviewLocation(MouseEvent e,
                                   boolean gridEnabled)
public void dragExit(DropTargetEvent e)
dragExit in interface DropTargetListenere - public void drop(DropTargetDropEvent e)
drop in interface DropTargetListenere - public void mouseReleased(MouseEvent e)
mouseReleased in interface MouseListenermouseReleased in class mxMouseAdapterprotected void fold(Object cell)
public void reset()
protected boolean shouldRemoveCellFromParent(Object parent,
                                             Object[] cells,
                                             MouseEvent e)
protected void moveCells(Object[] cells,
                         double dx,
                         double dy,
                         Object target,
                         MouseEvent e)
dx - dy - e - public void paint(Graphics g)
protected MouseEvent createEvent(DropTargetEvent e)
protected static final mxGraphTransferHandler getGraphTransferHandler(DropTargetEvent e)
protected static final JComponent getDropTarget(DropTargetEvent e)
| 
 | JGraph X 2.1.0.7 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||