A wrapper around juce::ValueTree designed to store custom plugin state (strings, arrays, etc.).
More...
#include <CustomParameter.h>
A wrapper around juce::ValueTree designed to store custom plugin state (strings, arrays, etc.).
◆ CustomParameter() [1/3]
| krotos::CustomParameter::CustomParameter |
( |
| ) |
|
◆ CustomParameter() [2/3]
| krotos::CustomParameter::CustomParameter |
( |
const ValueTree & | parameterTree, |
|
|
const Identifier & | property, |
|
|
UndoManager * | undoManager = nullptr ) |
◆ CustomParameter() [3/3]
◆ ~CustomParameter()
| krotos::CustomParameter::~CustomParameter |
( |
| ) |
|
|
override |
◆ getParameterTree()
| const ValueTree & krotos::CustomParameter::getParameterTree |
( |
| ) |
const |
|
inline |
Get a reference to the ValueTree that holds this object's state.
◆ getProperty()
| const Identifier & krotos::CustomParameter::getProperty |
( |
| ) |
const |
|
inline |
Get the Identifier for this object's parameter value in its ValueTree.
◆ getUndoManager()
| UndoManager * krotos::CustomParameter::getUndoManager |
( |
| ) |
const |
|
inline |
Get a pointer to the UndoManager used by this object.
◆ getValue()
| const var & krotos::CustomParameter::getValue |
( |
| ) |
const |
Get the current parameter value.
◆ isValid()
| bool krotos::CustomParameter::isValid |
( |
| ) |
const |
◆ operator=()
Copy assignment operator.
◆ operator==()
| bool krotos::CustomParameter::operator== |
( |
const CustomParameter & | other | ) |
const |
Comparison operator.
- Returns
- True if the other CustomParameter is controlling the same ValueTree property as this one.
◆ setUndoManager()
| void krotos::CustomParameter::setUndoManager |
( |
UndoManager * | um | ) |
|
|
inline |
Set the UndoManager that this object will use for all of its ValueTree interactions.
◆ setValue()
| void krotos::CustomParameter::setValue |
( |
const var & | newValue, |
|
|
bool | selfUpdate = false ) |
Set the current parameter value.
- Parameters
-
| newValue | The new custom parameter value. |
| selfUpdate | Set this to true if you would like to receive a callback to this object's 'valueChanged' lambda function. |
◆ valueTreePropertyChanged()
| void krotos::CustomParameter::valueTreePropertyChanged |
( |
ValueTree & | tree, |
|
|
const Identifier & | property ) |
|
overrideprivate |
◆ m_parameterTree
| ValueTree krotos::CustomParameter::m_parameterTree |
|
private |
◆ m_property
| Identifier krotos::CustomParameter::m_property |
|
private |
◆ m_undoManager
| UndoManager* krotos::CustomParameter::m_undoManager {nullptr} |
|
private |
◆ valueChanged
| std::function<void(const var&)> krotos::CustomParameter::valueChanged {nullptr} |
Use this function to receive notifications when the parameter value changes.
The documentation for this class was generated from the following files: