/** Load the settings of this panel */ private void loadSettings() { uploadPrioTextField.setText(settings.getValue(SettingsClass.FCP2_DEFAULT_PRIO_MESSAGE_UPLOAD)); downloadPrioTextField.setText( settings.getValue(SettingsClass.FCP2_DEFAULT_PRIO_MESSAGE_DOWNLOAD)); useOneConnectionForMessagesCheckBox.setSelected( settings.getBoolValue(SettingsClass.FCP2_USE_ONE_CONNECTION_FOR_MESSAGES)); displayDaysTextField.setText(settings.getValue(SettingsClass.MAX_MESSAGE_DISPLAY)); downloadDaysTextField.setText(settings.getValue(SettingsClass.MAX_MESSAGE_DOWNLOAD)); messageBaseTextField.setText(settings.getValue(SettingsClass.MESSAGE_BASE)); alwaysDownloadBackloadCheckBox.setSelected( settings.getBoolValue(SettingsClass.ALWAYS_DOWNLOAD_MESSAGES_BACKLOAD)); minimumIntervalTextField.setText( settings.getValue(SettingsClass.BOARD_AUTOUPDATE_MIN_INTERVAL)); concurrentUpdatesTextField.setText( settings.getValue(SettingsClass.BOARD_AUTOUPDATE_CONCURRENT_UPDATES)); // this setting is in MainFrame automaticBoardUpdateCheckBox.setSelected( MainFrame.getInstance().isAutomaticBoardUpdateEnabled()); refreshUpdateState(); storeSentMessagesCheckBox.setSelected( settings.getBoolValue(SettingsClass.STORAGE_STORE_SENT_MESSAGES)); silentlyRetryCheckBox.setSelected(settings.getBoolValue(SettingsClass.SILENTLY_RETRY_MESSAGES)); altEditCheckBox.setSelected(settings.getBoolValue(SettingsClass.ALTERNATE_EDITOR_ENABLED)); altEditTextField.setEnabled(altEditCheckBox.isSelected()); altEditTextField.setText(settings.getValue(SettingsClass.ALTERNATE_EDITOR_COMMAND)); }
/** Save the settings of this panel */ private void saveSettings() { settings.setValue( SettingsClass.FCP2_DEFAULT_PRIO_MESSAGE_UPLOAD, uploadPrioTextField.getText()); settings.setValue( SettingsClass.FCP2_DEFAULT_PRIO_MESSAGE_DOWNLOAD, downloadPrioTextField.getText()); settings.setValue( SettingsClass.FCP2_USE_ONE_CONNECTION_FOR_MESSAGES, useOneConnectionForMessagesCheckBox.isSelected()); settings.setValue(SettingsClass.MAX_MESSAGE_DISPLAY, displayDaysTextField.getText()); settings.setValue(SettingsClass.MAX_MESSAGE_DOWNLOAD, downloadDaysTextField.getText()); settings.setValue( SettingsClass.MESSAGE_BASE, messageBaseTextField.getText().trim().toLowerCase()); settings.setValue( SettingsClass.ALWAYS_DOWNLOAD_MESSAGES_BACKLOAD, alwaysDownloadBackloadCheckBox.isSelected()); settings.setValue( SettingsClass.BOARD_AUTOUPDATE_CONCURRENT_UPDATES, concurrentUpdatesTextField.getText()); settings.setValue( SettingsClass.BOARD_AUTOUPDATE_MIN_INTERVAL, minimumIntervalTextField.getText()); // settings.setValue(SettingsClass.BOARD_AUTOUPDATE_ENABLED, // automaticBoardUpdateCheckBox.isSelected()); // we change setting in MainFrame, this is auto-saved during frostSettings.save() MainFrame.getInstance() .setAutomaticBoardUpdateEnabled(automaticBoardUpdateCheckBox.isSelected()); settings.setValue( SettingsClass.STORAGE_STORE_SENT_MESSAGES, storeSentMessagesCheckBox.isSelected()); settings.setValue(SettingsClass.SILENTLY_RETRY_MESSAGES, silentlyRetryCheckBox.isSelected()); settings.setValue(SettingsClass.ALTERNATE_EDITOR_ENABLED, altEditCheckBox.isSelected()); settings.setValue(SettingsClass.ALTERNATE_EDITOR_COMMAND, altEditTextField.getText()); }
/** Load the settings of this panel */ private void loadSettings() { hideJunkMessagesCheckBox.setSelected( settings.getBoolValue(SettingsClass.JUNK_HIDE_JUNK_MESSAGES)); markJunkIdentityBadCheckBox.setSelected( settings.getBoolValue(SettingsClass.JUNK_MARK_JUNK_IDENTITY_BAD)); stopBoardUpdatesWhenDosedCheckBox.setSelected( settings.getBoolValue(SettingsClass.DOS_STOP_BOARD_UPDATES_WHEN_DOSED)); TfInvalidSubsequentMessagesThreshold.setText( "" + settings.getIntValue(SettingsClass.DOS_INVALID_SUBSEQUENT_MSGS_THRESHOLD)); }
/** Save the settings of this panel */ private void saveSettings() { settings.setValue(SettingsClass.JUNK_HIDE_JUNK_MESSAGES, hideJunkMessagesCheckBox.isSelected()); settings.setValue( SettingsClass.JUNK_MARK_JUNK_IDENTITY_BAD, markJunkIdentityBadCheckBox.isSelected()); settings.setValue( SettingsClass.DOS_STOP_BOARD_UPDATES_WHEN_DOSED, stopBoardUpdatesWhenDosedCheckBox.isSelected()); settings.setValue( SettingsClass.DOS_INVALID_SUBSEQUENT_MSGS_THRESHOLD, TfInvalidSubsequentMessagesThreshold.getText()); }
private void refreshStopOnDosState() { final boolean stopOnDos = stopBoardUpdatesWhenDosedCheckBox.isSelected(); LinvalidSubsequentMessagesThreshold.setEnabled(stopOnDos); TfInvalidSubsequentMessagesThreshold.setEnabled(stopOnDos); }
private void altEditChanged() { altEditTextField.setEnabled(altEditCheckBox.isSelected()); }