OpenShot Library | OpenShotAudio 0.2.2
|
Helper class providing an RAII-based mechanism for temporarily setting and then re-setting a value. More...
#include <juce_ScopedValueSetter.h>
Public Member Functions | |
ScopedValueSetter (ValueType &valueToSet, ValueType newValue) | |
Creates a ScopedValueSetter that will immediately change the specified value to the given new value, and will then reset it to its original value when this object is deleted. More... | |
ScopedValueSetter (ValueType &valueToSet, ValueType newValue, ValueType valueWhenDeleted) | |
Creates a ScopedValueSetter that will immediately change the specified value to the given new value, and will then reset it to be valueWhenDeleted when this object is deleted. More... | |
Helper class providing an RAII-based mechanism for temporarily setting and then re-setting a value.
E.g.
Definition at line 58 of file juce_ScopedValueSetter.h.
|
inline |
Creates a ScopedValueSetter that will immediately change the specified value to the given new value, and will then reset it to its original value when this object is deleted.
Definition at line 64 of file juce_ScopedValueSetter.h.
|
inline |
Creates a ScopedValueSetter that will immediately change the specified value to the given new value, and will then reset it to be valueWhenDeleted when this object is deleted.
Definition at line 75 of file juce_ScopedValueSetter.h.
|
inline |
Definition at line 84 of file juce_ScopedValueSetter.h.