CursorPanel(Cursor value) {
      setLayout(new java.awt.GridBagLayout());
      java.awt.GridBagConstraints gridBagConstraints1;
      list = new JList(new java.util.Vector(CURSOR_TYPES.keySet()));
      list.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
      if (value != null) list.setSelectedValue(value.getName(), true);

      gridBagConstraints1 = new java.awt.GridBagConstraints();
      gridBagConstraints1.gridx = 0;
      gridBagConstraints1.gridy = 1;
      gridBagConstraints1.fill = java.awt.GridBagConstraints.BOTH;
      gridBagConstraints1.insets = new java.awt.Insets(8, 8, 8, 8);
      gridBagConstraints1.weightx = 1.0;
      gridBagConstraints1.weighty = 1.0;
      add(list, gridBagConstraints1);

      gridBagConstraints1 = new java.awt.GridBagConstraints();
      gridBagConstraints1.gridx = 0;
      gridBagConstraints1.gridy = 0;
      gridBagConstraints1.insets = new java.awt.Insets(8, 8, 0, 8);
      gridBagConstraints1.anchor = java.awt.GridBagConstraints.WEST;
      add(
          new JLabel(
              org.openide.util.NbBundle.getBundle(CursorEditor.class)
                  .getString("CTL_SelectCursorName")),
          gridBagConstraints1);
    }
 public Object getPropertyValue() throws IllegalStateException {
   if (list.getSelectedValue() == null) return null;
   int type = ((Integer) CURSOR_TYPES.get(list.getSelectedValue())).intValue();
   return new Cursor(type);
 }