Package pamScrollSystem
Class RangeSpinner
java.lang.Object
pamScrollSystem.RangeSpinner
- All Implemented Interfaces:
PamScrollObserver
Spinner control used to set display ranges which can
be added to a PamScroller.
- Author:
- Doug
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addRangeSpinnerListener
(RangeSpinnerListener rangeSpinnerListener) Add a range spinner listener.void
addSpecialTimeRange
(double specialRange) Add a single special time range, e.g.void
addSpecialTimeRange
(double[] specialRanges) Add some special time ranges, e.g.double
boolean
Determines whether or not the spinner is enableddouble
double
void
removeRangeSpinnerListener
(RangeSpinnerListener rangeSpinnerListener) Remove a range spinner listener.void
scrollRangeChanged
(AbstractPamScroller pamScroller) Notification sent when a scroller or slider changes it's data rangevoid
scrollValueChanged
(AbstractPamScroller pamScroller) Notification sent when a scroller or slider changes it's positionvoid
setDefaultValue
(double defaultValue) void
setEnabled
(boolean e) Enable the controlsvoid
setMaxValue
(double maxValue) void
setSpinnerValue
(double spinnerValue) void
setTimeRanges
(double[] timeRanges)
-
Constructor Details
-
RangeSpinner
public RangeSpinner()
-
-
Method Details
-
setTimeRanges
public void setTimeRanges(double[] timeRanges) -
addSpecialTimeRange
public void addSpecialTimeRange(double specialRange) Add a single special time range, e.g. the length of a spectrogram display based on pixels- Parameters:
specialRange
- special range.
-
addSpecialTimeRange
public void addSpecialTimeRange(double[] specialRanges) Add some special time ranges, e.g. the length of a spectrogram display based on pixels- Parameters:
specialRanges
- list of special ranges.
-
setEnabled
public void setEnabled(boolean e) Enable the controls- Parameters:
e
- enable
-
getEnabled
public boolean getEnabled()Determines whether or not the spinner is enabled- Returns:
- true if enabled
-
getComponent
-
getDefaultValue
public double getDefaultValue()- Returns:
- the defaultValue
-
setDefaultValue
public void setDefaultValue(double defaultValue) - Parameters:
defaultValue
- the defaultValue to set
-
getSpinnerValue
public double getSpinnerValue()- Returns:
- the spinnerValue in seconds
-
setSpinnerValue
public void setSpinnerValue(double spinnerValue) - Parameters:
spinnerValue
- the spinnerValue to set in seconds
-
addRangeSpinnerListener
Add a range spinner listener.- Parameters:
rangeSpinnerListener
-
-
removeRangeSpinnerListener
Remove a range spinner listener.- Parameters:
rangeSpinnerListener
-
-
getMaxValue
public double getMaxValue()- Returns:
- the maxValue
-
setMaxValue
public void setMaxValue(double maxValue) - Parameters:
maxValue
- the maxValue to set
-
scrollRangeChanged
Description copied from interface:PamScrollObserver
Notification sent when a scroller or slider changes it's data rangeIf data were loaded in a worker thread, this notification is sent after the new data have loaded.
- Specified by:
scrollRangeChanged
in interfacePamScrollObserver
- Parameters:
pamScroller
- reference to moved scroller.
-
scrollValueChanged
Description copied from interface:PamScrollObserver
Notification sent when a scroller or slider changes it's position- Specified by:
scrollValueChanged
in interfacePamScrollObserver
- Parameters:
pamScroller
- reference to moved scroller
-