Crossfire JXClient, Trunk
|
Public Member Functions | |
void | addOptionListener (@NotNull final OptionListener listener) |
boolean | inhibitSave () |
void | removeOptionListener (@NotNull final OptionListener listener) |
Protected Member Functions | |
void | fireStateChangedEvent () |
Private Attributes | |
final EventListenerList2< OptionListener > | listeners = new EventListenerList2<>() |
The base class for all options. It manages a set of OptionListeners.
Definition at line 33 of file Option.java.
void com.realtime.crossfire.jxclient.settings.options.Option.addOptionListener | ( | @NotNull final OptionListener | listener | ) |
Adds a listener for state changes.
listener | the listener to add |
Definition at line 54 of file Option.java.
References com.realtime.crossfire.jxclient.settings.options.Option.listeners.
Referenced by com.realtime.crossfire.jxclient.gui.misc.GUICheckBox.GUICheckBox().
|
protected |
Notifies all listeners that the state has changed.
Reimplemented in com.realtime.crossfire.jxclient.settings.options.CheckBoxOption.
Definition at line 44 of file Option.java.
References com.realtime.crossfire.jxclient.settings.options.Option.listeners.
boolean com.realtime.crossfire.jxclient.settings.options.Option.inhibitSave | ( | ) |
Returns whether the option should not be saved. This function can be overridden for options that are otherwise saved, or for options that should not be saved at all.
Reimplemented in com.realtime.crossfire.jxclient.settings.options.PickupOptionOldMode, and com.realtime.crossfire.jxclient.settings.options.PickupOptionNewMode.
Definition at line 72 of file Option.java.
Referenced by com.realtime.crossfire.jxclient.settings.options.OptionManager.saveOptions().
void com.realtime.crossfire.jxclient.settings.options.Option.removeOptionListener | ( | @NotNull final OptionListener | listener | ) |
Removes a listener for state changes.
listener | the listener to remove |
Definition at line 62 of file Option.java.
References com.realtime.crossfire.jxclient.settings.options.Option.listeners.
Referenced by com.realtime.crossfire.jxclient.gui.misc.GUICheckBox.dispose().
|
private |
The listeners to be notified.
Definition at line 39 of file Option.java.
Referenced by com.realtime.crossfire.jxclient.settings.options.Option.addOptionListener(), com.realtime.crossfire.jxclient.settings.options.Option.fireStateChangedEvent(), and com.realtime.crossfire.jxclient.settings.options.Option.removeOptionListener().