Package com.biglybt.ui.swt.config
Class FloatSwtParameter
java.lang.Object
com.biglybt.ui.swt.config.BaseSwtParameter<FloatSwtParameter,Float>
com.biglybt.ui.swt.config.FloatSwtParameter
- All Implemented Interfaces:
SwtParameter<Float>
SWT Parameter representing a Float value
Will always use 2 horizontal spaces in GridLayout
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interface
Value Processor that's parameterized for this class and Float valuesNested classes/interfaces inherited from class com.biglybt.ui.swt.config.BaseSwtParameter
BaseSwtParameter.IndentPaintListener
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate boolean
private final DecimalFormat
private float
private float
private final org.eclipse.swt.widgets.Text
private org.eclipse.swt.widgets.Label
Fields inherited from class com.biglybt.ui.swt.config.BaseSwtParameter
change_listeners, paramID, pluginParam, validating, valueProcessor
Fields inherited from interface com.biglybt.ui.swt.config.SwtParameter
DEBUG
-
Constructor Summary
ConstructorsConstructorDescriptionFloatSwtParameter
(org.eclipse.swt.widgets.Composite composite, FloatParameterImpl pluginParam) FloatSwtParameter
(org.eclipse.swt.widgets.Composite composite, String paramID, String labelKey, String suffixLabelKey, float minValue, float maxValue, boolean allowZero, int digitsAfterDecimal, SwtParameterValueProcessor<FloatSwtParameter, Float> valueProcessor) Make a float value selecting ui. -
Method Summary
Modifier and TypeMethodDescriptionorg.eclipse.swt.widgets.Control[]
void
Methods inherited from class com.biglybt.ui.swt.config.BaseSwtParameter
addAndFireChangeListener, addChangeListener, addLabelContextMenus, addValidator, createStandardLabel, debug, dispose, doGridData, getIndent, getMainControl, getParamID, getRelatedControl, getValue, getValueProcessor, informChanged, isDefaultValue, isDisposed, isEnabled, isIndentFancy, refreshSuffixControl, removeChangeListener, removeValidator, resetToDefault, setConfigValueProcessor, setEnabled, setIndent, setLabelKey, setLabelText, setLayoutData, setMainControl, setPluginParameter, setRelatedControl, setValue, setValueProcessor, setVisible, triggerChangeListeners, triggerSubClassChangeListeners, updateControl
-
Field Details
-
df
-
inputField
private final org.eclipse.swt.widgets.Text inputField -
lblSuffix
private org.eclipse.swt.widgets.Label lblSuffix -
fMinValue
private float fMinValue -
fMaxValue
private float fMaxValue -
allowZero
private boolean allowZero
-
-
Constructor Details
-
FloatSwtParameter
public FloatSwtParameter(org.eclipse.swt.widgets.Composite composite, FloatParameterImpl pluginParam) -
FloatSwtParameter
public FloatSwtParameter(org.eclipse.swt.widgets.Composite composite, String paramID, String labelKey, String suffixLabelKey, float minValue, float maxValue, boolean allowZero, int digitsAfterDecimal, SwtParameterValueProcessor<FloatSwtParameter, Float> valueProcessor) Make a float value selecting ui. When parent composite is of GridLayout, resulting new widgets will take 2 columns- Parameters:
composite
- Where widgets will be placed. Composite is not alteredparamID
- ID of the parameter (usually config id)labelKey
- Messagebundle key for the text shown before text box. null for no label, "" to allocate blank labelsuffixLabelKey
- Messagebundle key for text shown after the text box null for no suffix label, "" to allocate blank suffix labelvalueProcessor
- null if you want to use COConfigurationManager
-
-
Method Details
-
validate
- Overrides:
validate
in classBaseSwtParameter<FloatSwtParameter,
Float>
-
refreshControl
public void refreshControl()- Overrides:
refreshControl
in classBaseSwtParameter<FloatSwtParameter,
Float>
-
getControls
public org.eclipse.swt.widgets.Control[] getControls()- Specified by:
getControls
in interfaceSwtParameter<Float>
- Overrides:
getControls
in classBaseSwtParameter<FloatSwtParameter,
Float>
-