// add, build, print, switch lists, terminate, and save buttons public void buttonActionPerformed(java.awt.event.ActionEvent ae) { log.debug("button activated"); if (ae.getSource() == clearButton) { updateCheckboxes(false); } if (ae.getSource() == selectButton) { updateCheckboxes(true); } if (ae.getSource() == applyButton) { applySchedule(); } if (ae.getSource() == buildButton) { switchListsButton.setEnabled(false); // uses a thread which allows table updates during build trainManager.buildSelectedTrains(getSortByList()); } if (ae.getSource() == printButton) { trainManager.printSelectedTrains(getSortByList()); } if (ae.getSource() == switchListsButton) { trainScheduleManager.buildSwitchLists(); } if (ae.getSource() == terminateButton) { trainManager.terminateSelectedTrains(getSortByList()); } if (ae.getSource() == activateButton) { trainManager.setTrainSecheduleActiveId(getSelectedScheduleId()); activateButton.setEnabled(false); } if (ae.getSource() == saveButton) { storeValues(); if (Setup.isCloseWindowOnSaveEnabled()) { dispose(); } } }