home *** CD-ROM | disk | FTP | other *** search
/ Computer Shopper 144 / DPCS0200.iso / Internet / Supanet / system / swing.jar / javax / swing / plaf / basic / BasicTreeUI$TreeCancelEditingAction.class (.txt) < prev    next >
Encoding:
Java Class File  |  1998-11-05  |  874 b   |  26 lines

  1. package javax.swing.plaf.basic;
  2.  
  3. import java.awt.event.ActionEvent;
  4. import javax.swing.AbstractAction;
  5.  
  6. public class BasicTreeUI$TreeCancelEditingAction extends AbstractAction {
  7.    // $FF: synthetic field
  8.    private final BasicTreeUI this$0;
  9.  
  10.    public BasicTreeUI$TreeCancelEditingAction(BasicTreeUI var1, String var2) {
  11.       super(var2);
  12.       this.this$0 = var1;
  13.    }
  14.  
  15.    public void actionPerformed(ActionEvent var1) {
  16.       if (this.this$0.tree != null) {
  17.          this.this$0.tree.cancelEditing();
  18.       }
  19.  
  20.    }
  21.  
  22.    public boolean isEnabled() {
  23.       return this.this$0.tree != null && this.this$0.tree.isEnabled();
  24.    }
  25. }
  26.