public void updateComponents() { Context context = getMainApplication().getContext(); errorBox.setVisible(false); if (smallPCB.isSelected()) context.setPcbSize(PCBSize.Small); else if (largePCB.isSelected()) context.setPcbSize(PCBSize.Large); ApplicationValues applicationValues = SettingsFactory.getApplicationValues(); applicationValues.getPcbSize().setValue(context.getPcbSize()); applicationValues.save(); continueButton.setDisable( radioButtonsBox.isVisible() && !smallPCB.isSelected() && !largePCB.isSelected()); if (context.getPcbSize() != null && !checkSelectedPcbSize()) { errorBox.setVisible(true); continueButton.setDisable(!ignoreErrorCheckbox.isSelected()); } }