Class BackupPreference
- java.lang.Object
-
- org.openstreetmap.josm.gui.preferences.DefaultPreferenceSetting
-
- org.openstreetmap.josm.gui.preferences.DefaultTabPreferenceSetting
-
- org.openstreetmap.josm.gui.preferences.map.BackupPreference
-
- All Implemented Interfaces:
PreferenceSetting
,TabPreferenceSetting
public class BackupPreference extends DefaultTabPreferenceSetting
Preference settings for data layer autosave.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BackupPreference.Factory
Factory used to create a newBackupPreference
.
-
Field Summary
Fields Modifier and Type Field Description private javax.swing.JCheckBox
autosave
private JosmTextField
autosaveInterval
private JosmTextField
backupPerLayer
private javax.swing.JCheckBox
keepBackup
private javax.swing.JCheckBox
notification
private static BooleanProperty
PROP_KEEP_BACKUP
-
Constructor Summary
Constructors Constructor Description BackupPreference()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addGui(PreferenceTabbedPane gui)
Add the GUI elements to the dialog.java.lang.String
getHelpContext()
Returns the help context for this preferences settings tab.boolean
isExpert()
Called to know if the preferences tab has only to be displayed in expert mode.boolean
ok()
Called when OK is pressed to save the setting in the preferences file.-
Methods inherited from class org.openstreetmap.josm.gui.preferences.DefaultTabPreferenceSetting
addSubTab, addSubTab, canBeHidden, createPreferenceTabWithScrollPane, getDescription, getIconName, getSelectedSubTab, getSubTab, getTabPane, getTitle, getTooltip, registerSubTab, selectSubTab
-
Methods inherited from class org.openstreetmap.josm.gui.preferences.DefaultPreferenceSetting
saveBoolean, saveDouble, saveInt
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.openstreetmap.josm.gui.preferences.TabPreferenceSetting
getIcon
-
-
-
-
Field Detail
-
PROP_KEEP_BACKUP
private static final BooleanProperty PROP_KEEP_BACKUP
-
notification
private javax.swing.JCheckBox notification
-
keepBackup
private javax.swing.JCheckBox keepBackup
-
autosave
private javax.swing.JCheckBox autosave
-
autosaveInterval
private final JosmTextField autosaveInterval
-
backupPerLayer
private final JosmTextField backupPerLayer
-
-
Constructor Detail
-
BackupPreference
BackupPreference()
-
-
Method Detail
-
addGui
public void addGui(PreferenceTabbedPane gui)
Description copied from interface:PreferenceSetting
Add the GUI elements to the dialog. The elements should be initialized after the current preferences.- Parameters:
gui
- the preferences tab pane
-
ok
public boolean ok()
Description copied from interface:PreferenceSetting
Called when OK is pressed to save the setting in the preferences file. Return true when restart is required.- Returns:
true
if restart is required
-
isExpert
public boolean isExpert()
Description copied from interface:PreferenceSetting
Called to know if the preferences tab has only to be displayed in expert mode.- Specified by:
isExpert
in interfacePreferenceSetting
- Overrides:
isExpert
in classDefaultPreferenceSetting
- Returns:
- true if the tab has only to be displayed in expert mode, false otherwise.
-
getHelpContext
public java.lang.String getHelpContext()
Description copied from interface:TabPreferenceSetting
Returns the help context for this preferences settings tab.- Specified by:
getHelpContext
in interfaceTabPreferenceSetting
- Overrides:
getHelpContext
in classDefaultTabPreferenceSetting
- Returns:
- the help context for this preferences settings tab
-
-