home *** CD-ROM | disk | FTP | other *** search
/ S283 Planetary Science &… the Search for Life CD 3 / 0_CD-ROM.iso / install / jre1_3 / lib / rt.jar / javax / swing / plaf / basic / BasicDesktopPaneUI$NavigateAction.class (.txt) < prev    next >
Encoding:
Java Class File  |  1979-12-31  |  1.3 KB  |  50 lines

  1. package javax.swing.plaf.basic;
  2.  
  3. import java.awt.event.ActionEvent;
  4. import java.beans.PropertyVetoException;
  5. import javax.swing.AbstractAction;
  6. import javax.swing.JComponent;
  7. import javax.swing.JInternalFrame;
  8.  
  9. public class BasicDesktopPaneUI$NavigateAction extends AbstractAction {
  10.    // $FF: synthetic field
  11.    private final BasicDesktopPaneUI this$0;
  12.  
  13.    protected BasicDesktopPaneUI$NavigateAction(BasicDesktopPaneUI var1) {
  14.       this.this$0 = var1;
  15.    }
  16.  
  17.    public void actionPerformed(ActionEvent var1) {
  18.       BasicDesktopPaneUI.access$100(this.this$0);
  19.       BasicDesktopPaneUI.access$208();
  20.       if (BasicDesktopPaneUI.access$200() >= BasicDesktopPaneUI.access$300().size()) {
  21.          BasicDesktopPaneUI.access$202(0);
  22.       }
  23.  
  24.       JComponent var2 = (JComponent)BasicDesktopPaneUI.access$300().elementAt(BasicDesktopPaneUI.access$200());
  25.       if (var2 instanceof JInternalFrame) {
  26.          JInternalFrame var3 = (JInternalFrame)var2;
  27.  
  28.          try {
  29.             var3.setSelected(true);
  30.             this.this$0.desktopManager.activateFrame(var3);
  31.          } catch (PropertyVetoException var7) {
  32.          }
  33.       } else if (var2 instanceof JInternalFrame.JDesktopIcon) {
  34.          JInternalFrame.JDesktopIcon var8 = (JInternalFrame.JDesktopIcon)var2;
  35.          JInternalFrame var4 = var8.getInternalFrame();
  36.  
  37.          try {
  38.             var4.setSelected(true);
  39.             this.this$0.desktopManager.activateFrame(var4);
  40.          } catch (PropertyVetoException var6) {
  41.          }
  42.       }
  43.  
  44.    }
  45.  
  46.    public boolean isEnabled() {
  47.       return true;
  48.    }
  49. }
  50.