|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectCH.ifa.draw.standard.AbstractTool
org.openbp.cockpit.modeler.tools.ModelerToolSupport
public class ModelerToolSupport
The node manipulation tool is the standard tool used by the modeler. It handles regular object selection as well as rubber band tracking, double click on objects and figure popup menu invocations. It also supports moving the workspace view while the ALT key is pressed (track).
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class CH.ifa.draw.standard.AbstractTool |
|---|
CH.ifa.draw.standard.AbstractTool.EventDispatcher |
| Field Summary |
|---|
| Fields inherited from class CH.ifa.draw.standard.AbstractTool |
|---|
fAnchorX, fAnchorY |
| Constructor Summary | |
|---|---|
ModelerToolSupport(DrawingEditorPlugin editor)
Constructs the tool for the given editor. |
|
| Method Summary | |
|---|---|
void |
activateTool(ModelerTool tool,
java.lang.Object objectUnderCursor)
Activates the given tool. |
void |
addToolDecisionTableEntry(ModelerTool tool,
java.lang.Class figureClass,
int requiredInputState)
Adds an entry to the tool decision table. |
protected void |
clearTool()
Clears the current tool. |
void |
deactivate()
|
protected ModelerToolDecisionTableEntry |
determineTool(java.lang.Object object)
Gets the tool that would be applied to the given object according to the current settings and input states. |
void |
displayInPlaceEditor(ProcessElementContainer figure)
Shows the in place editor for the given figure. |
DrawingEditorPlugin |
getEditor()
Gets the editor that owns the tool. |
VisualElement |
getLastFigure()
Gets the last figure that has been hovered with the mouse. |
java.awt.Point |
getLastPoint()
Returns the last known mouse coordinates. |
WorkspaceDrawingView |
getView()
Gets the view we refer to. |
void |
keyDown(java.awt.event.KeyEvent e,
int key)
|
void |
keyUp(java.awt.event.KeyEvent e,
int key)
|
void |
mouseDown(java.awt.event.MouseEvent e,
int x,
int y)
|
void |
mouseDrag(java.awt.event.MouseEvent e,
int x,
int y)
|
void |
mouseMove(java.awt.event.MouseEvent e,
int x,
int y)
|
void |
mouseUp(java.awt.event.MouseEvent e,
int x,
int y)
|
void |
toggleInPlaceEditor(ProcessElementContainer figure,
boolean delay)
Shows or hides the in place editor for the given figure. |
void |
updateToolState()
|
protected void |
updateToolState(java.awt.event.KeyEvent e)
Updates the cursor in case of a key press. |
| Methods inherited from class CH.ifa.draw.standard.AbstractTool |
|---|
activate, addToolListener, checkUsable, createEventDispatcher, drawing, editor, getEventDispatcher, getUndoActivity, isActive, isEnabled, isUsable, removeToolListener, setEnabled, setUndoActivity, setUsable, view, viewCreated, viewDestroying, viewSelectionChanged |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ModelerToolSupport(DrawingEditorPlugin editor)
editor - Editor that owns the tool| Method Detail |
|---|
public void addToolDecisionTableEntry(ModelerTool tool,
java.lang.Class figureClass,
int requiredInputState)
tool - ToolfigureClass - Class of the figure this tool is suitable for or null for anyrequiredInputState - Expected keyboard and mouse button input state or 0 for anypublic void deactivate()
deactivate in interface CH.ifa.draw.framework.Tooldeactivate in class CH.ifa.draw.standard.AbstractTool
public void activateTool(ModelerTool tool,
java.lang.Object objectUnderCursor)
tool - Tool to activateobjectUnderCursor - Object that will be affected by the toolprotected void clearTool()
public java.awt.Point getLastPoint()
public VisualElement getLastFigure()
public DrawingEditorPlugin getEditor()
public WorkspaceDrawingView getView()
public void mouseMove(java.awt.event.MouseEvent e,
int x,
int y)
mouseMove in interface CH.ifa.draw.framework.ToolmouseMove in class CH.ifa.draw.standard.AbstractTool
public void mouseDown(java.awt.event.MouseEvent e,
int x,
int y)
mouseDown in interface CH.ifa.draw.framework.ToolmouseDown in class CH.ifa.draw.standard.AbstractTool
public void mouseUp(java.awt.event.MouseEvent e,
int x,
int y)
mouseUp in interface CH.ifa.draw.framework.ToolmouseUp in class CH.ifa.draw.standard.AbstractTool
public void mouseDrag(java.awt.event.MouseEvent e,
int x,
int y)
mouseDrag in interface CH.ifa.draw.framework.ToolmouseDrag in class CH.ifa.draw.standard.AbstractTool
public void keyDown(java.awt.event.KeyEvent e,
int key)
keyDown in interface CH.ifa.draw.framework.ToolkeyDown in class CH.ifa.draw.standard.AbstractTool
public void keyUp(java.awt.event.KeyEvent e,
int key)
public void displayInPlaceEditor(ProcessElementContainer figure)
figure - Process element container figure to edit
public void toggleInPlaceEditor(ProcessElementContainer figure,
boolean delay)
figure - Process element container figure to editpublic void updateToolState()
protected void updateToolState(java.awt.event.KeyEvent e)
e - Key eventprotected ModelerToolDecisionTableEntry determineTool(java.lang.Object object)
object - Object under cursor
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||