1 19 20 package org.netbeans.modules.apisupport.project.ui.platform; 21 22 import java.awt.Component ; 23 import org.netbeans.modules.apisupport.project.ui.wizard.BasicWizardPanel; 24 import org.netbeans.modules.apisupport.project.universe.NbPlatform; 25 import org.openide.WizardDescriptor; 26 import org.openide.util.HelpCtx; 27 28 34 final class PlatformChooserWizardPanel extends BasicWizardPanel implements WizardDescriptor.FinishablePanel { 35 36 37 private PlatformChooserVisualPanel visualPanel; 38 39 40 public PlatformChooserWizardPanel(WizardDescriptor settings) { 41 super(settings); 42 } 43 44 public void storeSettings(Object settings) { 45 visualPanel.storeData(); 46 } 47 48 public Component getComponent() { 49 if (visualPanel == null) { 50 visualPanel = new PlatformChooserVisualPanel(getSettings()); 51 visualPanel.addPropertyChangeListener(this); 52 visualPanel.setName(NbPlatformCustomizer.CHOOSER_STEP); 53 } 54 return visualPanel; 55 } 56 57 public HelpCtx getHelp() { 58 return new HelpCtx(PlatformChooserWizardPanel.class); 59 } 60 61 public boolean isFinishPanel() { 62 return NbPlatform.isLabelValid((String ) getSettings().getProperty(NbPlatformCustomizer.PLAF_LABEL_PROPERTY)); 63 } 64 65 } 66 | Popular Tags |