01: package jimm.datavision.gui.cmd;
02:
03: import jimm.datavision.Report;
04: import jimm.datavision.gui.Designer;
05: import jimm.datavision.gui.Clipboard;
06: import jimm.datavision.gui.FieldPickerTree;
07: import jimm.util.I18N;
08: import javax.swing.tree.DefaultMutableTreeNode;
09:
10: /**
11: * Cuts (copies to the clipboard then deletes) something from a field
12: * picker tree.
13: *
14: * @author Jim Menard, <a href="mailto:jimm@io.com">jimm@io.com</a>
15: */
16: public class FPCutCommand extends FPDeleteCommand {
17:
18: public FPCutCommand(Report report, Designer designer,
19: FieldPickerTree tree, DefaultMutableTreeNode node) {
20: super (report, designer, tree, node, I18N
21: .get("FPCutCommand.name"));
22: }
23:
24: public void perform() {
25: Clipboard.instance().setContents(info);
26: super .perform();
27: }
28:
29: /**
30: * Calls <code>super.perform</code> because we don't want to copy
31: * anything to the clipboard a second time.
32: */
33: public void redo() {
34: super.perform();
35: }
36:
37: }
|