ff_meters
Add meter components to visualise AudioBuffers
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Macros Groups Pages
Public Member Functions | List of all members
foleys::LevelMeter::Listener Class Referenceabstract

DEPRECATED: Instead of using the Listener, use the new lambdas: More...

Public Member Functions

virtual ~Listener ()=default
 
virtual void clipLightClicked (foleys::LevelMeter *meter, const int channel, juce::ModifierKeys mods)=0
 This is called, when the user clicks a clip indicator. More...
 
virtual void maxLevelClicked (foleys::LevelMeter *meter, const int channel, juce::ModifierKeys mods)=0
 This is called, when the user clicks a max level text. More...
 

Detailed Description

DEPRECATED: Instead of using the Listener, use the new lambdas:

See Also
onMaxLevelClicked, onClipLightClicked

This Listener interface is meant to implement behaviour if either the clip indicator or the max level text is clicked.

An example implementation could look like this (+alt means clear all, else clear the clicked number):

void clipLightClicked (LevelMeter* clickedMeter, const int channel, ModifierKeys mods) override
{
clickedMeter->clearClipIndicator (mods.isAltDown() ? -1 : channel);
}
void maxLevelClicked (LevelMeter* clickedMeter, const int channel, ModifierKeys mods) override
{
clickedMeter->clearMaxLevelDisplay (mods.isAltDown() ? -1 : channel);
}

Constructor & Destructor Documentation

virtual foleys::LevelMeter::Listener::~Listener ( )
virtualdefault

Member Function Documentation

virtual void foleys::LevelMeter::Listener::clipLightClicked ( foleys::LevelMeter meter,
const int  channel,
juce::ModifierKeys  mods 
)
pure virtual

This is called, when the user clicks a clip indicator.

It can be used to reset the clip indicator. To allow different behaviour, e.g. resetting only one indicator or even all meters spread over the UI.

See Also
clearClipIndicator, maxLevelClicked

Referenced by foleys::LevelMeter::mouseDown().

virtual void foleys::LevelMeter::Listener::maxLevelClicked ( foleys::LevelMeter meter,
const int  channel,
juce::ModifierKeys  mods 
)
pure virtual

This is called, when the user clicks a max level text.

It can be used to reset the max number.

See Also
clearMaxLevelDisplay, clipLightClicked

Referenced by foleys::LevelMeter::mouseDown().


The documentation for this class was generated from the following file: