public class MovePositionalModelCommand
extends org.eclipse.gef.commands.Command
Modifier and Type | Field and Description |
---|---|
protected AbstractOfficeFloorEditPart<?,?,?> |
editPart
Edit part to be moved.
|
protected org.eclipse.draw2d.geometry.Point |
newLocation
New position for the figure.
|
protected org.eclipse.draw2d.geometry.Point |
oldLocation
Current (old) position for the edit part.
|
Constructor and Description |
---|
MovePositionalModelCommand(AbstractOfficeFloorEditPart<?,?,?> editPart,
org.eclipse.draw2d.geometry.Point location)
Initiate to move a position model.
|
Modifier and Type | Method and Description |
---|---|
void |
execute() |
protected void |
move(org.eclipse.draw2d.geometry.Point location)
Moves the edit part.
|
void |
undo() |
protected final AbstractOfficeFloorEditPart<?,?,?> editPart
protected final org.eclipse.draw2d.geometry.Point newLocation
protected final org.eclipse.draw2d.geometry.Point oldLocation
public MovePositionalModelCommand(AbstractOfficeFloorEditPart<?,?,?> editPart, org.eclipse.draw2d.geometry.Point location)
editPart
- Edit part to move.location
- Location to move the edit part.public void execute()
execute
in class org.eclipse.gef.commands.Command
public void undo()
undo
in class org.eclipse.gef.commands.Command
protected void move(org.eclipse.draw2d.geometry.Point location)
location
- Location for the edit part.Copyright © 2005–2016. All rights reserved.