GraphLab Project

graphlab.plugins.main.core.actions
Class VertexTransformer

java.lang.Object
  extended by graphlab.platform.core.AbstractAction
      extended by graphlab.plugins.main.core.actions.VertexTransformer
All Implemented Interfaces:
PaintHandler<AbstractGraphRenderer>, Action, Listener, Undoable

public class VertexTransformer
extends AbstractAction
implements PaintHandler<AbstractGraphRenderer>, Undoable

A class to transform the seleected vertices using mouse This class is not completely working yet!

Now has conflicts with GraphRectRegionSelect

Author:
Azin Azadi

Field Summary
static java.lang.String IS_TRANSFORMING
           
 
Fields inherited from class graphlab.platform.core.AbstractAction
blackboard
 
Constructor Summary
VertexTransformer(BlackBoard blackboard)
           
 
Method Summary
static void drawRoundRect(java.awt.Graphics g, java.awt.geom.Rectangle2D.Double rect, int arcsize)
           
static boolean isPositionOnResizeBoxes(GraphPoint mousPos, BlackBoard b)
           
 void paint(java.awt.Graphics g, java.lang.Object destinationComponent, java.lang.Boolean drawExtras)
           
 void performAction(java.lang.String eventName, java.lang.Object value)
          like Action
 void redo(UndoableActionOccuredData uaod)
           
 void undo(UndoableActionOccuredData uaod)
           
 
Methods inherited from class graphlab.platform.core.AbstractAction
disable, enable, getBlackBoard, getLastListenedEventKey, isEnable, keyChanged, listen4Event, setBlackBoard, unListenEvent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

IS_TRANSFORMING

public static java.lang.String IS_TRANSFORMING
Constructor Detail

VertexTransformer

public VertexTransformer(BlackBoard blackboard)
Method Detail

performAction

public void performAction(java.lang.String eventName,
                          java.lang.Object value)
Description copied from class: AbstractAction
like Action

Specified by:
performAction in interface Action
Specified by:
performAction in class AbstractAction

paint

public void paint(java.awt.Graphics g,
                  java.lang.Object destinationComponent,
                  java.lang.Boolean drawExtras)
Specified by:
paint in interface PaintHandler<AbstractGraphRenderer>

drawRoundRect

public static void drawRoundRect(java.awt.Graphics g,
                                 java.awt.geom.Rectangle2D.Double rect,
                                 int arcsize)

isPositionOnResizeBoxes

public static boolean isPositionOnResizeBoxes(GraphPoint mousPos,
                                              BlackBoard b)
Returns:
true if the given position is on some of resize boxes according to the graph assigned to the blackboard, if any of boxes are visible

undo

public void undo(UndoableActionOccuredData uaod)
Specified by:
undo in interface Undoable

redo

public void redo(UndoableActionOccuredData uaod)
Specified by:
redo in interface Undoable

GraphLab Project