Class CommandMove
- java.lang.Object
-
- org.openstreetmap.josm.plugins.streetside.history.commands.StreetsideCommand
-
- org.openstreetmap.josm.plugins.streetside.history.commands.CommandMove
-
public class CommandMove extends StreetsideCommand
Command created when an image's position is changed.
-
-
Field Summary
Fields Modifier and Type Field Description private doublexprivate doubley-
Fields inherited from class org.openstreetmap.josm.plugins.streetside.history.commands.StreetsideCommand
images
-
-
Constructor Summary
Constructors Constructor Description CommandMove(java.util.Set<StreetsideAbstractImage> images, double x, double y)Main constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidredo()Redoes the action.voidsum(StreetsideCommand command)If two equal commands are applied consecutively to the same set of images, they are summed in order to reduce them to just one command.java.lang.StringtoString()voidundo()Undoes the action.
-
-
-
Constructor Detail
-
CommandMove
public CommandMove(java.util.Set<StreetsideAbstractImage> images, double x, double y)
Main constructor.- Parameters:
images- Set of images that are going to be moved.x- How much the x coordinate increases.y- How much the y coordinate increases.
-
-
Method Detail
-
undo
public void undo()
Description copied from class:StreetsideCommandUndoes the action.- Specified by:
undoin classStreetsideCommand
-
redo
public void redo()
Description copied from class:StreetsideCommandRedoes the action.- Specified by:
redoin classStreetsideCommand
-
toString
public java.lang.String toString()
- Specified by:
toStringin classStreetsideCommand
-
sum
public void sum(StreetsideCommand command)
Description copied from class:StreetsideCommandIf two equal commands are applied consecutively to the same set of images, they are summed in order to reduce them to just one command.- Specified by:
sumin classStreetsideCommand- Parameters:
command- The command to be summed to last command.
-
-