1 19 package org.netbeans.modules.j2ee.websphere6.dd.loaders.ui; 20 21 import org.netbeans.modules.j2ee.websphere6.dd.beans.*; 22 23 27 public class MarkupLanguagePanel extends javax.swing.JPanel { 28 29 30 public MarkupLanguagePanel() { 31 initComponents(); 32 nameComboBox.setModel(new javax.swing.DefaultComboBoxModel (MarkupLanguagesType.AVALIABLE_NAMES)); 33 mimeTypeComboBox.setModel(new javax.swing.DefaultComboBoxModel (MarkupLanguagesType.AVALIABLE_MIME_TYPES)); 34 } 35 36 41 private void initComponents() { 43 idLabel = new javax.swing.JLabel (); 44 idField = new javax.swing.JTextField (); 45 namfeLabel = new javax.swing.JLabel (); 46 nameComboBox = new javax.swing.JComboBox (); 47 mimeTypeLabel = new javax.swing.JLabel (); 48 mimeTypeComboBox = new javax.swing.JComboBox (); 49 50 idLabel.setText("ID:"); 51 52 namfeLabel.setText("Name:"); 53 54 mimeTypeLabel.setText("MIME Type:"); 55 56 org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this); 57 this.setLayout(layout); 58 layout.setHorizontalGroup( 59 layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) 60 .add(layout.createSequentialGroup() 61 .add(38, 38, 38) 62 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) 63 .add(mimeTypeLabel) 64 .add(namfeLabel) 65 .add(idLabel)) 66 .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) 67 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) 68 .add(idField, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 314, Short.MAX_VALUE) 69 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false) 70 .add(org.jdesktop.layout.GroupLayout.LEADING, mimeTypeComboBox, 0, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) 71 .add(org.jdesktop.layout.GroupLayout.LEADING, nameComboBox, 0, 145, Short.MAX_VALUE))) 72 .addContainerGap()) 73 ); 74 layout.setVerticalGroup( 75 layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) 76 .add(layout.createSequentialGroup() 77 .add(42, 42, 42) 78 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) 79 .add(idLabel) 80 .add(idField, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) 81 .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) 82 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) 83 .add(namfeLabel) 84 .add(nameComboBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) 85 .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) 86 .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) 87 .add(mimeTypeLabel) 88 .add(mimeTypeComboBox, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)) 89 .addContainerGap(org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) 90 ); 91 } 93 94 private javax.swing.JTextField idField; 96 private javax.swing.JLabel idLabel; 97 private javax.swing.JComboBox mimeTypeComboBox; 98 private javax.swing.JLabel mimeTypeLabel; 99 private javax.swing.JComboBox nameComboBox; 100 private javax.swing.JLabel namfeLabel; 101 public javax.swing.JTextField getIdField(){ 103 return idField; 104 } 105 public javax.swing.JComboBox getMimeTypeComboBox(){ 106 return mimeTypeComboBox; 107 } 108 public javax.swing.JComboBox getNameComboBox(){ 109 return nameComboBox; 110 } 111 112 } 113 | Popular Tags |