| 
 | 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.util.mxEventSource
com.mxgraph.swing.handler.mxMovePreview
public class mxMovePreview
Connection handler creates new connections between cells. This control is used to display the connector icon, while the preview is used to draw the line.
| Nested Class Summary | 
|---|
| Nested classes/interfaces inherited from class com.mxgraph.util.mxEventSource | 
|---|
| mxEventSource.mxIEventListener | 
| Field Summary | |
|---|---|
| protected  boolean | clonePreviewSpecifies if the preview should use clones of the original shapes. | 
| protected  boolean | contextPreviewSpecifies if connected, unselected edges should be included in the preview. | 
| protected  mxGraphComponent | graphComponent | 
| protected  boolean | hideSelectionHandlerSpecifies if the selection cells handler should be hidden while the preview is visible. | 
| protected  Rectangle | initialPlaceholder | 
| protected  mxRectangle | lastDirty | 
| protected  Object[] | movingCells | 
| protected  Rectangle | placeholder | 
| protected  boolean | placeholderPreviewSpecifies if the placeholder rectangle should be used for all previews. | 
| protected  mxCellStatePreview | preview | 
| protected  mxCellState[] | previewStates | 
| protected  mxCellState | startState | 
| protected  int | thresholdMaximum number of cells to preview individually. | 
| Fields inherited from class com.mxgraph.util.mxEventSource | 
|---|
| eventListeners, eventsEnabled, eventSource | 
| Constructor Summary | |
|---|---|
| mxMovePreview(mxGraphComponent graphComponent)Constructs a new rubberband selection for the given graph component. | |
| Method Summary | |
|---|---|
|  mxCellStatePreview | createCellStatePreview() | 
|  Object[] | getCells(mxCellState initialState) | 
|  Object[] | getMovingCells()FIXME: Cells should be assigned outside of getPreviewStates | 
| protected  mxRectangle | getPlaceholderBounds(mxCellState startState) | 
| protected  mxCellState[] | getPreviewStates()Returns the states that are affected by the move operation. | 
|  int | getThreshold() | 
|  boolean | isActive() | 
| protected  boolean | isCellOpaque(Object cell) | 
|  boolean | isClonePreview() | 
|  boolean | isContextPreview() | 
|  boolean | isHideSelectionHandler() | 
|  boolean | isPlaceholderPreview() | 
|  void | paint(Graphics g) | 
| protected  void | repaint(mxRectangle dirty) | 
| protected  void | reset() | 
|  void | setClonePreview(boolean value) | 
|  void | setContextPreview(boolean value) | 
|  void | setHideSelectionHandler(boolean value) | 
|  void | setPlaceholderPreview(boolean value) | 
|  void | setThreshold(int value) | 
|  void | start(MouseEvent e,
      mxCellState state)Sets the translation of the preview. | 
|  Object[] | stop(boolean commit,
     MouseEvent e,
     double dx,
     double dy,
     boolean clone,
     Object target) | 
|  void | update(MouseEvent e,
       double dx,
       double dy,
       boolean clone)Sets the translation of the preview. | 
| Methods inherited from class com.mxgraph.util.mxEventSource | 
|---|
| addListener, fireEvent, fireEvent, getEventSource, isEventsEnabled, removeListener, removeListener, setEventsEnabled, setEventSource | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
protected mxGraphComponent graphComponent
protected int threshold
protected boolean placeholderPreview
protected boolean clonePreview
protected boolean contextPreview
protected boolean hideSelectionHandler
protected transient mxCellState startState
protected transient mxCellState[] previewStates
protected transient Object[] movingCells
protected transient Rectangle initialPlaceholder
protected transient Rectangle placeholder
protected transient mxRectangle lastDirty
protected transient mxCellStatePreview preview
| Constructor Detail | 
|---|
public mxMovePreview(mxGraphComponent graphComponent)
graphComponent - Component that contains the rubberband.| Method Detail | 
|---|
public int getThreshold()
public void setThreshold(int value)
public boolean isPlaceholderPreview()
public void setPlaceholderPreview(boolean value)
public boolean isClonePreview()
public void setClonePreview(boolean value)
public boolean isContextPreview()
public void setContextPreview(boolean value)
public boolean isHideSelectionHandler()
public void setHideSelectionHandler(boolean value)
public boolean isActive()
public Object[] getMovingCells()
public Object[] getCells(mxCellState initialState)
protected mxCellState[] getPreviewStates()
protected boolean isCellOpaque(Object cell)
public void start(MouseEvent e,
                  mxCellState state)
protected mxRectangle getPlaceholderBounds(mxCellState startState)
public mxCellStatePreview createCellStatePreview()
public void update(MouseEvent e,
                   double dx,
                   double dy,
                   boolean clone)
protected void repaint(mxRectangle dirty)
protected void reset()
public Object[] stop(boolean commit,
                     MouseEvent e,
                     double dx,
                     double dy,
                     boolean clone,
                     Object target)
public void paint(Graphics g)
| 
 | JGraph X 2.1.0.7 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||