Class ColorParameterImpl
- java.lang.Object
-
- com.biglybt.pifimpl.local.ui.config.ParameterImpl
-
- com.biglybt.pifimpl.local.ui.config.ColorParameterImpl
-
- All Implemented Interfaces:
ParameterListener
,ConfigParameter
,ColorParameter
,EnablerParameter
,Parameter
,ParameterWithSuffix
public class ColorParameterImpl extends ParameterImpl implements ColorParameter
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
suffixLabelKey
-
Fields inherited from class com.biglybt.pifimpl.local.ui.config.ParameterImpl
configKey
-
Fields inherited from interface com.biglybt.pif.ui.config.Parameter
MODE_ADVANCED, MODE_BEGINNER, MODE_INTERMEDIATE
-
-
Constructor Summary
Constructors Constructor Description ColorParameterImpl(java.lang.String configKey, java.lang.String label)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getBlueValue()
int
getGreenValue()
int
getRedValue()
java.lang.String
getSuffixLabelKey()
java.lang.Object
getValueObject()
Retrieve the parameter's value as an Object.boolean
isOverridden()
boolean
resetToDefault()
Resets the parameter to its default valuevoid
setRGBValue(int r, int g, int b)
void
setSuffixLabelKey(java.lang.String suffixLabelKey)
void
setSuffixLabelText(java.lang.String text)
-
Methods inherited from class com.biglybt.pifimpl.local.ui.config.ParameterImpl
addConfigParameterListener, addDisabledOnSelection, addDisabledOnSelection, addEnabledOnSelection, addEnabledOnSelection, addImplListener, addListener, addValidator, destroy, fireParameterChanged, getConfigKeyName, getDisabledOnSelectionParameters, getEnabledOnSelectionParameters, getGenerateIntermediateEvents, getGroup, getIndent, getKey, getLabelKey, getLabelText, getMinimumRequiredUserMode, getReferenceID, hasBeenSet, isEnabled, isForUIType, isIndentFancy, isVisible, parameterChanged, refreshControl, removeConfigParameterListener, removeImplListener, removeListener, search, setAllowedUiTypes, setEnabled, setGenerateIntermediateEvents, setGroup, setIndent, setLabelKey, setLabelText, setMinimumRequiredUserMode, setReferenceID, setVisible, validate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.biglybt.pif.config.ConfigParameter
addConfigParameterListener, removeConfigParameterListener
-
Methods inherited from interface com.biglybt.pif.ui.config.Parameter
addListener, addValidator, getConfigKeyName, getGenerateIntermediateEvents, getLabelKey, getLabelText, getMinimumRequiredUserMode, hasBeenSet, isEnabled, isForUIType, isVisible, removeListener, setAllowedUiTypes, setEnabled, setGenerateIntermediateEvents, setIndent, setLabelKey, setLabelText, setMinimumRequiredUserMode, setVisible
-
-
-
-
Method Detail
-
getValueObject
public java.lang.Object getValueObject()
Description copied from interface:Parameter
Retrieve the parameter's value as an Object. Subclasses will usually have a getValue() that will return a specific type.- Specified by:
getValueObject
in interfaceParameter
- Overrides:
getValueObject
in classParameterImpl
-
getRedValue
public int getRedValue()
- Specified by:
getRedValue
in interfaceColorParameter
-
getGreenValue
public int getGreenValue()
- Specified by:
getGreenValue
in interfaceColorParameter
-
getBlueValue
public int getBlueValue()
- Specified by:
getBlueValue
in interfaceColorParameter
-
setRGBValue
public void setRGBValue(int r, int g, int b)
- Specified by:
setRGBValue
in interfaceColorParameter
-
resetToDefault
public boolean resetToDefault()
Description copied from interface:Parameter
Resets the parameter to its default value- Specified by:
resetToDefault
in interfaceParameter
- Overrides:
resetToDefault
in classParameterImpl
- Returns:
- true - value was reset; false - already reset
-
isOverridden
public boolean isOverridden()
-
getSuffixLabelKey
public java.lang.String getSuffixLabelKey()
- Specified by:
getSuffixLabelKey
in interfaceParameterWithSuffix
-
setSuffixLabelKey
public void setSuffixLabelKey(java.lang.String suffixLabelKey)
- Specified by:
setSuffixLabelKey
in interfaceParameterWithSuffix
-
setSuffixLabelText
public void setSuffixLabelText(java.lang.String text)
- Specified by:
setSuffixLabelText
in interfaceParameterWithSuffix
-
-