Classes | Public Member Functions | List of all members
SliderPack Class Reference

A Component which contains multiple Sliders which support dragging & bipolar display. More...

Inheritance diagram for SliderPack:
SafeChangeListener

Classes

class  Listener
 Inherit from this class in order to get notified about changes to the slider pack. More...
 

Public Member Functions

void addListener (Listener *listener)
 Register a listener that will receive notification when the sliders are changed. More...
 
int getNumSliders ()
 Returns the number of slider. More...
 
double getValue (int sliderIndex)
 Returns the value of the slider index. More...
 
void removeListener (Listener *listener)
 Removes a previously registered listener. More...
 
void setDefaultValue (double defaultValue)
 Sets the double click return value. More...
 
void setNumSliders (int numSliders)
 Sets the number of sliders shown. More...
 
void setSliderWidths (const Array< var > &newWidths)
 Set the slider widths to the given proportions. More...
 
void setValue (int sliderIndex, double newValue)
 Sets the value of one of the sliders. More...
 
 SliderPack (SliderPackData *data=nullptr)
 Creates a new SliderPack. More...
 

Detailed Description

A Component which contains multiple Sliders which support dragging & bipolar display.

This class is driven by the SliderPackData class, which acts as data container.

Constructor & Destructor Documentation

SliderPack ( SliderPackData data = nullptr)

Creates a new SliderPack.

Member Function Documentation

void addListener ( Listener listener)
inline

Register a listener that will receive notification when the sliders are changed.

int getNumSliders ( )

Returns the number of slider.

double getValue ( int  sliderIndex)

Returns the value of the slider index.

If the index is bigger than the slider amount, it will return -1.

void removeListener ( Listener listener)
inline

Removes a previously registered listener.

void setDefaultValue ( double  defaultValue)

Sets the double click return value.

void setNumSliders ( int  numSliders)

Sets the number of sliders shown.

This clears all values.

void setSliderWidths ( const Array< var > &  newWidths)
inline

Set the slider widths to the given proportions.

For example { 0.25, 0.5, 0.25 } will make the middle slider twice as big.

void setValue ( int  sliderIndex,
double  newValue 
)

Sets the value of one of the sliders.

If the index is bigger than the slider amount, it will do nothing.

©2017 HISE. This documentation is autogenerated from the HISE source code using Doxygen.