Package docking.options.editor
Class ScrollableOptionsEditor
- java.lang.Object
-
- docking.options.editor.ScrollableOptionsEditor
-
- All Implemented Interfaces:
OptionsEditor
public class ScrollableOptionsEditor extends java.lang.Object implements OptionsEditor
Panel that shows each property in an Options category or a Group in an Options category
-
-
Constructor Summary
Constructors Constructor Description ScrollableOptionsEditor(java.lang.String title)
Creates a panel for editing options.ScrollableOptionsEditor(java.lang.String title, java.util.List<java.lang.String> optionNames)
Creates a panel for editing options.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
apply()
Apply the changes.void
cancel()
Cancel the changes.void
dispose()
Dispose this editorjavax.swing.JComponent
getComponent()
javax.swing.JComponent
getEditorComponent(Options options, EditorStateFactory factory)
Get the editor component.void
reload()
A signal to reload the GUI widgets in the component created by this editor.void
setOptionsPropertyChangeListener(java.beans.PropertyChangeListener listener)
Sets the options change listener
-
-
-
Constructor Detail
-
ScrollableOptionsEditor
public ScrollableOptionsEditor(java.lang.String title, java.util.List<java.lang.String> optionNames)
Creates a panel for editing options. This version of the constructor allows the client to specify the option names to put them in some order other than the default alphabetical ordering.- Parameters:
title
- The title of the options paneloptionNames
- the names of the options for this panel
-
ScrollableOptionsEditor
public ScrollableOptionsEditor(java.lang.String title)
Creates a panel for editing options. This version of the constructor will get the options names from the options object whengetEditorComponent(Options, EditorStateFactory)
is called.- Parameters:
title
- the title for the panel
-
-
Method Detail
-
dispose
public void dispose()
Description copied from interface:OptionsEditor
Dispose this editor- Specified by:
dispose
in interfaceOptionsEditor
-
apply
public void apply() throws InvalidInputException
Description copied from interface:OptionsEditor
Apply the changes.- Specified by:
apply
in interfaceOptionsEditor
- Throws:
InvalidInputException
-
cancel
public void cancel()
Description copied from interface:OptionsEditor
Cancel the changes.- Specified by:
cancel
in interfaceOptionsEditor
-
reload
public void reload()
Description copied from interface:OptionsEditor
A signal to reload the GUI widgets in the component created by this editor. This will happen when the options change out from under the editor, such as when the user restores the default options values.- Specified by:
reload
in interfaceOptionsEditor
-
getEditorComponent
public javax.swing.JComponent getEditorComponent(Options options, EditorStateFactory factory)
Description copied from interface:OptionsEditor
Get the editor component.- Specified by:
getEditorComponent
in interfaceOptionsEditor
- Parameters:
options
- The editable options that for which a GUI component will be createdfactory
- The factory that will provide state objects this options editor
-
setOptionsPropertyChangeListener
public void setOptionsPropertyChangeListener(java.beans.PropertyChangeListener listener)
Description copied from interface:OptionsEditor
Sets the options change listener- Specified by:
setOptionsPropertyChangeListener
in interfaceOptionsEditor
-
getComponent
public javax.swing.JComponent getComponent()
-
-