public class mxConnectPreview extends mxEventSource
mxEventSource.mxIEventListener
Modifier and Type | Field | Description |
---|---|---|
protected mxGraphComponent |
graphComponent |
|
protected mxCellState |
previewState |
|
protected mxCellState |
sourceState |
|
protected mxPoint |
startPoint |
eventListeners, eventsEnabled, eventSource
Constructor | Description |
---|---|
mxConnectPreview(mxGraphComponent graphComponent) |
Modifier and Type | Method | Description |
---|---|---|
protected java.lang.Object |
createCell(mxCellState startState,
java.lang.String style) |
Creates a new instance of mxShape for previewing the edge.
|
protected java.awt.Rectangle |
getDirtyRect() |
|
protected java.awt.Rectangle |
getDirtyRect(mxRectangle dirty) |
|
mxCellState |
getPreviewState() |
|
mxCellState |
getSourceState() |
|
mxPoint |
getStartPoint() |
|
boolean |
isActive() |
|
void |
paint(java.awt.Graphics g) |
|
protected void |
paintPreview(mxGraphics2DCanvas canvas) |
Draws the preview using the graphics canvas.
|
void |
revalidate(mxCellState state) |
|
void |
start(java.awt.event.MouseEvent e,
mxCellState startState,
java.lang.String style) |
Updates the style of the edge preview from the incoming edge
|
java.lang.Object |
stop(boolean commit) |
|
java.lang.Object |
stop(boolean commit,
java.awt.event.MouseEvent e) |
|
protected mxPoint |
transformScreenPoint(double x,
double y) |
|
void |
update(java.awt.event.MouseEvent e,
mxCellState targetState,
double x,
double y) |
addListener, fireEvent, fireEvent, getEventSource, isEventsEnabled, removeListener, removeListener, setEventsEnabled, setEventSource
protected mxGraphComponent graphComponent
protected mxCellState previewState
protected mxCellState sourceState
protected mxPoint startPoint
public mxConnectPreview(mxGraphComponent graphComponent)
graphComponent
- protected java.lang.Object createCell(mxCellState startState, java.lang.String style)
public boolean isActive()
public mxCellState getSourceState()
public mxCellState getPreviewState()
public mxPoint getStartPoint()
public void start(java.awt.event.MouseEvent e, mxCellState startState, java.lang.String style)
public void update(java.awt.event.MouseEvent e, mxCellState targetState, double x, double y)
protected java.awt.Rectangle getDirtyRect()
protected java.awt.Rectangle getDirtyRect(mxRectangle dirty)
protected mxPoint transformScreenPoint(double x, double y)
public void revalidate(mxCellState state)
public void paint(java.awt.Graphics g)
protected void paintPreview(mxGraphics2DCanvas canvas)
public java.lang.Object stop(boolean commit)
public java.lang.Object stop(boolean commit, java.awt.event.MouseEvent e)
Copyright (c) 2010-2017 Gaudenz Alder, JGraph Ltd. All rights reserved.