public JComponent getComponent() {
return mainPanel;
}
public void applyChanges() throws ConfigurationException {
DatabaseBrowserGeneralSettings configuration = getConfiguration();
boolean repaintTree = configuration.isModified();
BrowserDisplayMode displayMode =
simpleRadioButton.isSelected() ? BrowserDisplayMode.SIMPLE :
tabbedRadioButton.isSelected() ? BrowserDisplayMode.TABBED :
BrowserDisplayMode.SIMPLE;
configuration.setDisplayMode(displayMode);
ConfigurationEditorUtil.validateIntegerInputValue(navigationHistorySizeTextField, "Navigation history size", 0, 1000, "");
configuration.getNavigationHistorySize().applyChanges(navigationHistorySizeTextField);
configuration.getShowObjectDetails().applyChanges(showObjectDetailsCheckBox);
if (repaintTree) {
Project project = configuration.getProject();
ObjectDisplaySettingsListener listener = EventManager.notify(project, ObjectDisplaySettingsListener.TOPIC);
listener.displayDetailsChanged();
}
}