jimm.datavision.gui.cmd
Class SectionResizeCommand

java.lang.Object
  extended by jimm.datavision.gui.cmd.CommandAdapter
      extended by jimm.datavision.gui.cmd.SectionResizeCommand
All Implemented Interfaces:
Command, Nameable

public class SectionResizeCommand
extends CommandAdapter

Mainly used by other commands to remember a section's old size and restore it on an undo.

Author:
Jim Menard, jimm@io.com

Field Summary
protected  int oldSectionHeight
           
protected  int sectionHeightDelta
           
protected  SectionWidget sw
           
 
Fields inherited from class jimm.datavision.gui.cmd.CommandAdapter
name
 
Constructor Summary
SectionResizeCommand(SectionWidget sw)
           
 
Method Summary
 void perform()
          Performs the command.
 void redo()
          Redoes the command by calling CommandAdapter.perform().
 void undo()
          Undoes the command.
 
Methods inherited from class jimm.datavision.gui.cmd.CommandAdapter
getName, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

sw

protected SectionWidget sw

oldSectionHeight

protected int oldSectionHeight

sectionHeightDelta

protected int sectionHeightDelta
Constructor Detail

SectionResizeCommand

public SectionResizeCommand(SectionWidget sw)
Method Detail

perform

public void perform()
Description copied from class: CommandAdapter
Performs the command. The default implementation does nothing.

Specified by:
perform in interface Command
Overrides:
perform in class CommandAdapter

undo

public void undo()
Description copied from class: CommandAdapter
Undoes the command. The default implementation does nothing.

Specified by:
undo in interface Command
Overrides:
undo in class CommandAdapter

redo

public void redo()
Description copied from class: CommandAdapter
Redoes the command by calling CommandAdapter.perform().

Specified by:
redo in interface Command
Overrides:
redo in class CommandAdapter