@Override
 protected JComponent getDefaultFocus() {
   if (jItems.isEnabled()) {
     return jItems;
   } else {
     return jCountMinimum;
   }
 }
 @Override
 public void actionPerformed(ActionEvent e) {
   JComboBox jb = (JComboBox) e.getSource();
   if (jb.isEnabled()) {
     String selectedSpriteName = jb.getSelectedItem().toString();
     DisplayModel displayModel = controller.getSpriteByName(selectedSpriteName);
     setForm(displayModel);
   }
 }
 private void fillAttributes() {
   int layerIdx = nnet.getLayersCount() - 1; // output layerIdx by default
   Attribute attr1;
   Attribute attr2 = null;
   if (layerCombo.isEnabled()) {
     layerIdx = (Integer) layerCombo.getSelectedItem() - 1;
   }
   attr1 = new Attribute(layerIdx, false, "Layer");
   if (attributeTxtField.isEnabled()) {
     attribute = Integer.parseInt(attributeTxtField.getText());
     attr2 = new Attribute(attribute, false, "Input");
   }
   graphBuilder.setAttribute1(attr1);
   graphBuilder.setAttribute2(attr2);
   outputNeuronCount = nnet.getLayerAt(layerIdx).getNeuronsCount();
 }
Esempio n. 4
0
 @Override
 void validateFields() throws SvmValidationException {
   if (comboBoxAnrede != null && comboBoxAnrede.isEnabled()) {
     LOGGER.trace("Validate field Anrede");
     setModelAnrede();
   }
   if (txtNachname.isEnabled()) {
     LOGGER.trace("Validate field Nachname");
     setModelNachname(true);
   }
   if (txtVorname.isEnabled()) {
     LOGGER.trace("Validate field Vorname");
     setModelVorname(true);
   }
   if (txtStrasseHausnummer.isEnabled()) {
     LOGGER.trace("Validate field StrasseHausnummer");
     setModelStrasseHausnummer(true);
   }
   if (txtPlz.isEnabled()) {
     LOGGER.trace("Validate field Plz");
     setModelPlz(true);
   }
   if (txtOrt.isEnabled()) {
     LOGGER.trace("Validate field Ort");
     setModelOrt(true);
   }
   if (txtFestnetz.isEnabled()) {
     LOGGER.trace("Validate field Festnetz");
     setModelFestnetz(true);
   }
   if (txtNatel.isEnabled()) {
     LOGGER.trace("Validate field Natel");
     setModelNatel(true);
   }
   if (txtEmail.isEnabled()) {
     LOGGER.trace("Validate field Email");
     setModelEmail(true);
   }
   if (txtGeburtsdatum != null && txtGeburtsdatum.isEnabled()) {
     LOGGER.trace("Validate field Geburtsdatum");
     setModelGeburtsdatum(true);
   }
 }