Audacity  3.0.3
Public Member Functions | Private Attributes | List of all members
LadspaEffectOptionsDialog Class Referencefinal
Inheritance diagram for LadspaEffectOptionsDialog:
[legend]
Collaboration diagram for LadspaEffectOptionsDialog:
[legend]

Public Member Functions

 LadspaEffectOptionsDialog (wxWindow *parent, EffectHostInterface *host)
 
virtual ~LadspaEffectOptionsDialog ()
 
void PopulateOrExchange (ShuttleGui &S)
 
void OnOk (wxCommandEvent &evt)
 
- Public Member Functions inherited from wxDialogWrapper
 wxDialogWrapper ()
 
 wxDialogWrapper (wxWindow *parent, wxWindowID id, const TranslatableString &title, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxDEFAULT_DIALOG_STYLE, const TranslatableString &name=XO("Dialog"))
 
bool Create (wxWindow *parent, wxWindowID id, const TranslatableString &title, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxDEFAULT_DIALOG_STYLE, const TranslatableString &name=XO("Dialog"))
 
void SetTitle (const TranslatableString &title)
 
void SetLabel (const TranslatableString &title)
 
void SetName (const TranslatableString &title)
 
void SetName ()
 
- Public Member Functions inherited from wxTabTraversalWrapper< wxDialog >
 wxTabTraversalWrapper (Args &&... args)
 
 wxTabTraversalWrapper (const wxTabTraversalWrapper &)=delete
 
 wxTabTraversalWrapper (wxTabTraversalWrapper &&)=delete
 
wxTabTraversalWrapperoperator= (const wxTabTraversalWrapper &)=delete
 
wxTabTraversalWrapperoperator= (wxTabTraversalWrapper &&)=delete
 

Private Attributes

EffectHostInterfacemHost
 
bool mUseLatency
 

Detailed Description

Definition at line 396 of file LadspaEffect.cpp.

Constructor & Destructor Documentation

◆ LadspaEffectOptionsDialog()

LadspaEffectOptionsDialog::LadspaEffectOptionsDialog ( wxWindow *  parent,
EffectHostInterface host 
)

Definition at line 417 of file LadspaEffect.cpp.

418 : wxDialogWrapper(parent, wxID_ANY, XO("LADSPA Effect Options"))
419 {
420  mHost = host;
421 
422  mHost->GetSharedConfig(wxT("Options"), wxT("UseLatency"), mUseLatency, true);
423 
424  ShuttleGui S(this, eIsCreating);
426 }

References eIsCreating.

◆ ~LadspaEffectOptionsDialog()

LadspaEffectOptionsDialog::~LadspaEffectOptionsDialog ( )
virtual

Definition at line 428 of file LadspaEffect.cpp.

429 {
430 }

Member Function Documentation

◆ OnOk()

void LadspaEffectOptionsDialog::OnOk ( wxCommandEvent &  evt)

Definition at line 469 of file LadspaEffect.cpp.

470 {
471  if (!Validate())
472  {
473  return;
474  }
475 
478 
479  mHost->SetSharedConfig(wxT("Options"), wxT("UseLatency"), mUseLatency);
480 
481  EndModal(wxID_OK);
482 }

References eIsGettingFromDialog.

◆ PopulateOrExchange()

void LadspaEffectOptionsDialog::PopulateOrExchange ( ShuttleGui S)

Definition at line 432 of file LadspaEffect.cpp.

433 {
434  S.SetBorder(5);
435  S.StartHorizontalLay(wxEXPAND, 1);
436  {
437  S.StartVerticalLay(false);
438  {
439  S.StartStatic(XO("Latency Compensation"));
440  {
441  S.AddVariableText( XO(
442 "As part of their processing, some LADSPA effects must delay returning "
443 "audio to Audacity. When not compensating for this delay, you will "
444 "notice that small silences have been inserted into the audio. "
445 "Enabling this option will provide that compensation, but it may "
446 "not work for all LADSPA effects."),
447  false, 0, 650);
448 
449  S.StartHorizontalLay(wxALIGN_LEFT);
450  {
451  S.TieCheckBox(XXO("Enable &compensation"),
452  mUseLatency);
453  }
454  S.EndHorizontalLay();
455  }
456  S.EndStatic();
457  }
458  S.EndVerticalLay();
459  }
460  S.EndHorizontalLay();
461 
462  S.AddStandardButtons();
463 
464  Layout();
465  Fit();
466  Center();
467 }

References ShuttleGui::AddStandardButtons(), ShuttleGuiBase::AddVariableText(), ShuttleGuiBase::EndHorizontalLay(), ShuttleGuiBase::EndStatic(), ShuttleGuiBase::EndVerticalLay(), ShuttleGuiBase::SetBorder(), ShuttleGuiBase::StartHorizontalLay(), ShuttleGuiBase::StartStatic(), ShuttleGuiBase::StartVerticalLay(), ShuttleGuiBase::TieCheckBox(), XO, and XXO.

Here is the call graph for this function:

Member Data Documentation

◆ mHost

EffectHostInterface* LadspaEffectOptionsDialog::mHost
private

Definition at line 407 of file LadspaEffect.cpp.

◆ mUseLatency

bool LadspaEffectOptionsDialog::mUseLatency
private

Definition at line 408 of file LadspaEffect.cpp.


The documentation for this class was generated from the following file:
eIsCreating
@ eIsCreating
Definition: ShuttleGui.h:38
ShuttleGuiBase::StartVerticalLay
void StartVerticalLay(int iProp=1)
Definition: ShuttleGui.cpp:1184
eIsGettingFromDialog
@ eIsGettingFromDialog
Definition: ShuttleGui.h:39
ShuttleGuiBase::TieCheckBox
wxCheckBox * TieCheckBox(const TranslatableString &Prompt, bool &Var)
Definition: ShuttleGui.cpp:1629
LadspaEffectOptionsDialog::mHost
EffectHostInterface * mHost
Definition: LadspaEffect.cpp:407
XO
#define XO(s)
Definition: Internat.h:31
XXO
#define XXO(s)
Definition: Internat.h:44
ShuttleGuiBase::EndHorizontalLay
void EndHorizontalLay()
Definition: ShuttleGui.cpp:1177
ShuttleGuiBase::StartHorizontalLay
void StartHorizontalLay(int PositionFlags=wxALIGN_CENTRE, int iProp=1)
Definition: ShuttleGui.cpp:1167
ShuttleGuiBase::EndVerticalLay
void EndVerticalLay()
Definition: ShuttleGui.cpp:1203
LadspaEffectOptionsDialog::PopulateOrExchange
void PopulateOrExchange(ShuttleGui &S)
Definition: LadspaEffect.cpp:432
ConfigClientInterface::GetSharedConfig
virtual bool GetSharedConfig(const RegistryPath &group, const RegistryPath &key, wxString &value, const wxString &defval)=0
ShuttleGuiBase::StartStatic
wxStaticBox * StartStatic(const TranslatableString &Str, int iProp=0)
Definition: ShuttleGui.cpp:893
ConfigClientInterface::SetSharedConfig
virtual bool SetSharedConfig(const RegistryPath &group, const RegistryPath &key, const wxString &value)=0
wxDialogWrapper::wxDialogWrapper
wxDialogWrapper()
Definition: wxPanelWrapper.h:84
ShuttleGui::AddStandardButtons
void AddStandardButtons(long buttons=eOkButton|eCancelButton, wxWindow *extra=NULL)
Definition: ShuttleGui.cpp:2444
ShuttleGuiBase::SetBorder
void SetBorder(int Border)
Definition: ShuttleGui.h:489
ShuttleGuiBase::AddVariableText
wxStaticText * AddVariableText(const TranslatableString &Str, bool bCenter=false, int PositionFlags=0, int wrapWidth=0)
Definition: ShuttleGui.cpp:463
ShuttleGuiBase::EndStatic
void EndStatic()
Definition: ShuttleGui.cpp:922
ShuttleGui
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition: ShuttleGui.h:631
LadspaEffectOptionsDialog::mUseLatency
bool mUseLatency
Definition: LadspaEffect.cpp:408