Audacity 3.2.0
|
#include <VST3Editor.h>
Public Member Functions | |
VST3Editor (wxWindow *parent, VST3Wrapper &wrapper, const EffectUIServices &effect, EffectType type, EffectSettingsAccess &access, bool useNativeUI) | |
~VST3Editor () override | |
bool | IsGraphicalUI () override |
bool | UpdateUI () override |
Update appearance of the panel for changes in settings. More... | |
bool | ValidateUI () override |
Get settings data from the panel; may make error dialogs and return false. More... | |
void | OnClose () override |
Public Member Functions inherited from EffectEditor | |
EffectEditor (const EffectUIServices &services, EffectSettingsAccess &access) | |
virtual | ~EffectEditor () |
virtual bool | ValidateUI ()=0 |
Get settings data from the panel; may make error dialogs and return false. More... | |
virtual bool | UpdateUI () |
Update appearance of the panel for changes in settings. More... | |
virtual bool | IsGraphicalUI () |
virtual void | Disconnect () |
On the first call only, may disconnect from further event handling. More... | |
virtual void | OnClose () |
Public Member Functions inherited from Observer::Publisher< EffectSettingChanged > | |
Publisher (ExceptionPolicy *pPolicy=nullptr, Alloc a={}) | |
Constructor supporting type-erased custom allocation/deletion. More... | |
Publisher (Publisher &&)=default | |
Publisher & | operator= (Publisher &&)=default |
Subscription | Subscribe (Callback callback) |
Connect a callback to the Publisher; later-connected are called earlier. More... | |
Subscription | Subscribe (Object &obj, Return(Object::*callback)(Args...)) |
Overload of Subscribe takes an object and pointer-to-member-function. More... | |
Private Member Functions | |
void | OnIdle (wxIdleEvent &) |
bool | TryLoadNativeUI (wxWindow *parent) |
Private Attributes | |
VST3Wrapper & | mWrapper |
Steinberg::IPtr< Steinberg::IPlugView > | mPlugView |
Steinberg::IPtr< Steinberg::IPlugFrame > | mPlugFrame |
wxWindow * | mParent { nullptr } |
NumericTextCtrl * | mDuration { nullptr } |
VST3ParametersWindow * | mPlainUI { nullptr } |
Additional Inherited Members | |
Public Types inherited from Observer::Publisher< EffectSettingChanged > | |
using | message_type = EffectSettingChanged |
using | CallbackReturn = std::conditional_t< true, void, bool > |
using | Callback = std::function< CallbackReturn(const EffectSettingChanged &) > |
Type of functions that can be connected to the Publisher. More... | |
Static Public Member Functions inherited from EffectEditor | |
static bool | EnableApply (wxWindow *parent, bool enable=true) |
Enable or disable the Apply button of the dialog that contains parent. More... | |
static bool | EnablePreview (wxWindow *parent, bool enable=true) |
Static Public Attributes inherited from EffectEditor | |
static constexpr int | kPlayID = 20102 |
Static Public Attributes inherited from Observer::Publisher< EffectSettingChanged > | |
static constexpr bool | notifies_all |
Protected Member Functions inherited from EffectEditor | |
template<typename EventTag , typename Class , typename Event > | |
void | BindTo (wxEvtHandler &src, const EventTag &eventType, void(Class::*pmf)(Event &)) |
Protected Member Functions inherited from Observer::Publisher< EffectSettingChanged > | |
CallbackReturn | Publish (const EffectSettingChanged &message) |
Send a message to connected callbacks. More... | |
Protected Attributes inherited from EffectEditor | |
const EffectUIServices & | mUIServices |
EffectSettingsAccess & | mAccess |
bool | mUIClosed { false } |
Definition at line 20 of file VST3Editor.h.
VST3Editor::VST3Editor | ( | wxWindow * | parent, |
VST3Wrapper & | wrapper, | ||
const EffectUIServices & | effect, | ||
EffectType | type, | ||
EffectSettingsAccess & | access, | ||
bool | useNativeUI | ||
) |
Definition at line 16 of file VST3Editor.cpp.
References _, NumericTextCtrl::Options::AutoPos(), VST3Wrapper::BeginParameterEdit(), EffectTypeGenerate, EffectSettings::extra, EffectSettingsAccess::Get(), id, EffectEditor::mAccess, VST3Wrapper::mComponentHandler, mDuration, VST3Wrapper::mEditController, mParent, mPlainUI, VST3Wrapper::mSetup, mWrapper, NumericConverterType_TIME(), OnIdle(), VST3Wrapper::ParamChangedHandler, Observer::Publisher< EffectSettingChanged >::Publish(), safenew, FormatterContext::SampleRateContext(), NumericTextCtrl::SetName(), VST3ParametersWindow::Setup(), TryLoadNativeUI(), and XO().
|
override |
Definition at line 73 of file VST3Editor.cpp.
References mWrapper, and VST3Wrapper::ParamChangedHandler.
|
overridevirtual |
Default implementation returns false
Reimplemented from EffectEditor.
Definition at line 134 of file VST3Editor.cpp.
References mPlugView.
|
overridevirtual |
Handle the UI OnClose event. Default implementation calls mUIServices.CloseUI()
Reimplemented from EffectEditor.
Definition at line 152 of file VST3Editor.cpp.
References VST3Wrapper::EndParameterEdit(), EffectSettingsAccess::Flush(), VST3Wrapper::FlushParameters(), NumericConverter::GetValue(), EffectEditor::mAccess, mDuration, EffectSettingsAccess::ModifySettings(), mParent, mPlainUI, mPlugFrame, mPlugView, mWrapper, EffectEditor::OnClose(), VST3Wrapper::ParamChangedHandler, settings(), and VST3Wrapper::StoreSettings().
|
private |
Definition at line 78 of file VST3Editor.cpp.
References VST3Wrapper::FlushParameters(), VST3Wrapper::IsActive(), EffectEditor::mAccess, EffectSettingsAccess::ModifySettings(), mWrapper, settings(), and VST3Wrapper::StoreSettings().
Referenced by VST3Editor().
|
private |
Definition at line 95 of file VST3Editor.cpp.
References VST3Wrapper::mEditController, mPlugFrame, mPlugView, mWrapper, and safenew.
Referenced by VST3Editor().
|
overridevirtual |
Update appearance of the panel for changes in settings.
Default implementation does nothing, returns true
Reimplemented from EffectEditor.
Definition at line 186 of file VST3Editor.cpp.
References VST3Wrapper::FetchSettings(), EffectSettingsAccess::Flush(), EffectEditor::mAccess, EffectSettingsAccess::ModifySettings(), mPlainUI, mWrapper, VST3ParametersWindow::ReloadParameters(), and settings().
|
overridevirtual |
Get settings data from the panel; may make error dialogs and return false.
Implements EffectEditor.
Definition at line 139 of file VST3Editor.cpp.
References VST3Wrapper::FlushParameters(), NumericConverter::GetValue(), EffectEditor::mAccess, mDuration, EffectSettingsAccess::ModifySettings(), mWrapper, settings(), and VST3Wrapper::StoreSettings().
|
private |
Definition at line 29 of file VST3Editor.h.
Referenced by OnClose(), ValidateUI(), and VST3Editor().
|
private |
Definition at line 28 of file VST3Editor.h.
Referenced by OnClose(), and VST3Editor().
|
private |
Definition at line 31 of file VST3Editor.h.
Referenced by OnClose(), UpdateUI(), and VST3Editor().
|
private |
Definition at line 27 of file VST3Editor.h.
Referenced by OnClose(), and TryLoadNativeUI().
|
private |
Definition at line 26 of file VST3Editor.h.
Referenced by IsGraphicalUI(), OnClose(), and TryLoadNativeUI().
|
private |
Definition at line 24 of file VST3Editor.h.
Referenced by OnClose(), OnIdle(), TryLoadNativeUI(), UpdateUI(), ValidateUI(), VST3Editor(), and ~VST3Editor().