/*
* The contents of this file are subject to the terms
* of the Common Development and Distribution License
* (the License). You may not use this file except in
* compliance with the License.
*
* You can obtain a copy of the license at
* https://glassfish.dev.java.net/public/CDDLv1.0.html or
* glassfish/bootstrap/legal/CDDLv1.0.txt.
* See the License for the specific language governing
* permissions and limitations under the License.
*
* When distributing Covered Code, include this CDDL
* Header Notice in each file and include the License file
* at glassfish/bootstrap/legal/CDDLv1.0.txt.
* If applicable, add the following below the CDDL Header,
* with the fields enclosed by brackets [] replaced by
* you own identifying information:
* "Portions Copyrighted [year] [name of copyright owner]"
*
* Copyright (c) Ericsson AB, 2004-2007. All rights reserved.
* Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
*/
package org.jvnet.glassfish.comms.netbeans.sip.module.wizards;
import javax.swing.JPanel;
import org.openide.WizardDescriptor;
import org.openide.util.HelpCtx;
import org.openide.util.NbBundle;
class ProjectConfigPanelVisual extends JPanel implements HelpCtx.Provider {
private ProjectLocationPanelVisual projectLocationPanel;
private ProjectOptionsPanelVisual optionsPanel;
/** Creates new form PanelInitProject */
public ProjectConfigPanelVisual(ProjectConfigPanel panel) {
initComponents();
this.getAccessibleContext().setAccessibleDescription(NbBundle.getMessage(ProjectConfigPanelVisual.class, "ACS_NWP1_NamePanel_A11YDesc")); // NOI18N
projectLocationPanel = new ProjectLocationPanelVisual(panel);
locationContainer.add(projectLocationPanel, java.awt.BorderLayout.NORTH);
optionsPanel = new ProjectOptionsPanelVisual();
optionsContainer.add(optionsPanel, java.awt.BorderLayout.NORTH);
// Provide a name in the title bar.
setName(NbBundle.getMessage(ProjectConfigPanelVisual.class, "LBL_NWP1_ProjectTitleName")); //NOI18N
putClientProperty ("NewProjectWizard_Title",
NbBundle.getMessage(ProjectConfigPanelVisual.class, "TXT_NewSipApp")); //NOI18N
}
boolean valid(WizardDescriptor wizardDescriptor) {
return projectLocationPanel.valid(wizardDescriptor) && optionsPanel.valid(wizardDescriptor);
}
void read (WizardDescriptor d) {
projectLocationPanel.read(d);
optionsPanel.read(d);
}
void store(WizardDescriptor d) {
projectLocationPanel.store(d);
optionsPanel.store(d);
}
/** This method is called from within the constructor to
* initialize the form.
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
java.awt.GridBagConstraints gridBagConstraints;
locationContainer = new javax.swing.JPanel();
jSeparator1 = new javax.swing.JSeparator();
optionsContainer = new javax.swing.JPanel();
setRequestFocusEnabled(false);
setLayout(new java.awt.GridBagLayout());
locationContainer.setLayout(new java.awt.BorderLayout());
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
gridBagConstraints.weightx = 1.0;
add(locationContainer, gridBagConstraints);
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
gridBagConstraints.weightx = 1.0;
gridBagConstraints.insets = new java.awt.Insets(12, 0, 12, 0);
add(jSeparator1, gridBagConstraints);
optionsContainer.setLayout(new java.awt.BorderLayout());
gridBagConstraints = new java.awt.GridBagConstraints();
gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER;
gridBagConstraints.gridheight = java.awt.GridBagConstraints.REMAINDER;
gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH;
gridBagConstraints.weightx = 1.0;
gridBagConstraints.weighty = 1.0;
add(optionsContainer, gridBagConstraints);
}// </editor-fold>//GEN-END:initComponents
// Variables declaration - do not modify//GEN-BEGIN:variables
private javax.swing.JSeparator jSeparator1;
private javax.swing.JPanel locationContainer;
private javax.swing.JPanel optionsContainer;
// End of variables declaration//GEN-END:variables
/** Help context where to find more about the paste type action.
* @return the help context for this action
*/
public HelpCtx getHelpCtx() {
return new HelpCtx(ProjectConfigPanelVisual.class);
}
}