1 19 20 package org.netbeans.modules.apisupport.project.ui.wizard; 21 22 import java.awt.Component ; 23 import org.netbeans.modules.apisupport.project.Util; 24 import org.openide.util.HelpCtx; 25 26 39 final class BasicConfWizardPanel extends BasicWizardPanel.NewTemplatePanel { 40 41 42 private BasicConfVisualPanel visualPanel; 43 44 45 public BasicConfWizardPanel(final NewModuleProjectData data) { 46 super(data); 47 } 48 49 public void reloadData() { 50 NewModuleProjectData data = getData(); 51 if (data.getCodeNameBase() == null) { 52 String dotName = BasicConfVisualPanel.EXAMPLE_BASE_NAME + data.getProjectName(); 53 data.setCodeNameBase(Util.normalizeCNB(dotName)); 54 } 55 if (data.getProjectDisplayName() == null) { 56 data.setProjectDisplayName(data.getProjectName()); 57 } 58 visualPanel.refreshData(); 59 } 60 61 public void storeData() { 62 visualPanel.storeData(); 63 } 64 65 public Component getComponent() { 66 if (visualPanel == null) { 67 visualPanel = new BasicConfVisualPanel(getData()); 68 visualPanel.addPropertyChangeListener(this); 69 visualPanel.setName(getMessage("LBL_BasicConfigPanel_Title")); 70 } 71 return visualPanel; 72 } 73 74 public HelpCtx getHelp() { 75 return new HelpCtx(BasicConfWizardPanel.class); 76 } 77 78 } 79 | Popular Tags |