1 19 20 package org.netbeans.modules.j2ee.ddloaders.multiview.ui; 21 22 import org.netbeans.modules.xml.multiview.ui.SectionNodeInnerPanel; 23 import org.netbeans.modules.xml.multiview.ui.SectionNodeView; 24 import org.netbeans.modules.xml.multiview.Utils; 25 26 import javax.swing.*; 27 28 31 public class EjbDetailForm extends SectionNodeInnerPanel { 32 33 36 public EjbDetailForm(SectionNodeView sectionNodeView) { 37 super(sectionNodeView); 38 initComponents(); 39 Utils.makeTextAreaLikeTextField(descriptionTextArea, displayNameTextField); 40 } 41 42 48 private void initComponents() { 50 java.awt.GridBagConstraints gridBagConstraints; 51 52 displayNameLabel = new javax.swing.JLabel (); 53 descriptionLabel = new javax.swing.JLabel (); 54 smallIconlabel = new javax.swing.JLabel (); 55 largeIconLabel = new javax.swing.JLabel (); 56 displayNameTextField = new javax.swing.JTextField (); 57 descriptionTextArea = new javax.swing.JTextArea (); 58 smallIconTextField = new javax.swing.JTextField (); 59 browseSmallIconButton = new javax.swing.JButton (); 60 largeIconTextField = new javax.swing.JTextField (); 61 browseLargeIconButton = new javax.swing.JButton (); 62 spacerLabel = new javax.swing.JLabel (); 63 64 setLayout(new java.awt.GridBagLayout ()); 65 66 displayNameLabel.setText(org.openide.util.NbBundle.getMessage(EjbDetailForm.class, "LBL_DisplayName")); 67 gridBagConstraints = new java.awt.GridBagConstraints (); 68 gridBagConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST; 69 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 70 add(displayNameLabel, gridBagConstraints); 71 72 descriptionLabel.setText(org.openide.util.NbBundle.getMessage(EjbDetailForm.class, "LBL_Description")); 73 gridBagConstraints = new java.awt.GridBagConstraints (); 74 gridBagConstraints.gridx = 0; 75 gridBagConstraints.gridy = 2; 76 gridBagConstraints.anchor = java.awt.GridBagConstraints.SOUTHWEST; 77 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 78 add(descriptionLabel, gridBagConstraints); 79 80 smallIconlabel.setText(org.openide.util.NbBundle.getMessage(EjbDetailForm.class, "LBL_SmallIcon")); 81 gridBagConstraints = new java.awt.GridBagConstraints (); 82 gridBagConstraints.gridx = 0; 83 gridBagConstraints.gridy = 3; 84 gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST; 85 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 86 add(smallIconlabel, gridBagConstraints); 87 88 largeIconLabel.setText(org.openide.util.NbBundle.getMessage(EjbDetailForm.class, "LBL_LargeIcon")); 89 gridBagConstraints = new java.awt.GridBagConstraints (); 90 gridBagConstraints.gridx = 0; 91 gridBagConstraints.gridy = 4; 92 gridBagConstraints.anchor = java.awt.GridBagConstraints.WEST; 93 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 94 add(largeIconLabel, gridBagConstraints); 95 96 displayNameTextField.setColumns(25); 97 gridBagConstraints = new java.awt.GridBagConstraints (); 98 gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; 99 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 100 add(displayNameTextField, gridBagConstraints); 101 102 descriptionTextArea.setLineWrap(true); 103 descriptionTextArea.setRows(3); 104 descriptionTextArea.setWrapStyleWord(true); 105 gridBagConstraints = new java.awt.GridBagConstraints (); 106 gridBagConstraints.gridx = 1; 107 gridBagConstraints.gridy = 1; 108 gridBagConstraints.gridwidth = java.awt.GridBagConstraints.REMAINDER; 109 gridBagConstraints.gridheight = 2; 110 gridBagConstraints.fill = java.awt.GridBagConstraints.BOTH; 111 gridBagConstraints.weighty = 1.0; 112 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 113 add(descriptionTextArea, gridBagConstraints); 114 115 smallIconTextField.setColumns(25); 116 gridBagConstraints = new java.awt.GridBagConstraints (); 117 gridBagConstraints.gridx = 1; 118 gridBagConstraints.gridy = 3; 119 gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; 120 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 121 add(smallIconTextField, gridBagConstraints); 122 123 browseSmallIconButton.setText(org.openide.util.NbBundle.getMessage(EjbDetailForm.class, "LBL_Browse")); 124 gridBagConstraints = new java.awt.GridBagConstraints (); 125 gridBagConstraints.gridx = 2; 126 gridBagConstraints.gridy = 3; 127 gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; 128 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 129 add(browseSmallIconButton, gridBagConstraints); 130 131 largeIconTextField.setColumns(25); 132 gridBagConstraints = new java.awt.GridBagConstraints (); 133 gridBagConstraints.gridx = 1; 134 gridBagConstraints.gridy = 4; 135 gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; 136 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 137 add(largeIconTextField, gridBagConstraints); 138 139 browseLargeIconButton.setText(org.openide.util.NbBundle.getMessage(EjbDetailForm.class, "LBL_Browse")); 140 gridBagConstraints = new java.awt.GridBagConstraints (); 141 gridBagConstraints.gridx = 2; 142 gridBagConstraints.gridy = 4; 143 gridBagConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL; 144 gridBagConstraints.insets = new java.awt.Insets (3, 3, 3, 3); 145 add(browseLargeIconButton, gridBagConstraints); 146 147 spacerLabel.setText(" "); 148 gridBagConstraints = new java.awt.GridBagConstraints (); 149 gridBagConstraints.gridx = 3; 150 gridBagConstraints.gridy = 4; 151 gridBagConstraints.weightx = 1.0; 152 add(spacerLabel, gridBagConstraints); 153 154 } 155 157 private javax.swing.JButton browseLargeIconButton; 159 private javax.swing.JButton browseSmallIconButton; 160 private javax.swing.JLabel descriptionLabel; 161 private javax.swing.JTextArea descriptionTextArea; 162 private javax.swing.JLabel displayNameLabel; 163 private javax.swing.JTextField displayNameTextField; 164 private javax.swing.JLabel largeIconLabel; 165 private javax.swing.JTextField largeIconTextField; 166 private javax.swing.JTextField smallIconTextField; 167 private javax.swing.JLabel smallIconlabel; 168 private javax.swing.JLabel spacerLabel; 169 171 public JTextArea getDescriptionTextArea() { 172 return descriptionTextArea; 173 } 174 175 public JTextField getDisplayNameTextField() { 176 return displayNameTextField; 177 } 178 179 public JTextField getLargeIconTextField() { 180 return largeIconTextField; 181 } 182 183 public JTextField getSmallIconTextField() { 184 return smallIconTextField; 185 } 186 187 public JButton getBrowseLargeIconButton() { 188 return browseLargeIconButton; 189 } 190 191 public JButton getBrowseSmallIconButton() { 192 return browseSmallIconButton; 193 } 194 195 public JComponent getErrorComponent(String errorId) { 196 return null; 197 } 198 199 public void setValue(JComponent source, Object value) { 200 201 } 202 203 public void linkButtonPressed(Object ddBean, String ddProperty) { 204 205 } 206 207 } 208 | Popular Tags |