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

Public Member Functions

 ExportWavPackOptions (wxWindow *parent, int format)
 
virtual ~ExportWavPackOptions ()
 
void PopulateOrExchange (ShuttleGui &S)
 
bool TransferDataToWindow () override
 
bool TransferDataFromWindow () override
 
void OnHybridMode (wxCommandEvent &evt)
 
void OnCreateCorrection (wxCommandEvent &evt)
 
- Public Member Functions inherited from wxPanelWrapper
 wxPanelWrapper ()
 
 wxPanelWrapper (wxWindow *parent, wxWindowID winid=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL|wxNO_BORDER, const TranslatableString &name=XO("Panel"))
 
bool Create (wxWindow *parent, wxWindowID winid=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL|wxNO_BORDER, const TranslatableString &name=XO("Panel"))
 
void SetLabel (const TranslatableString &label)
 
void SetName (const TranslatableString &name)
 
void SetToolTip (const TranslatableString &toolTip)
 
void SetName ()
 
- Public Member Functions inherited from wxTabTraversalWrapper< wxPanel >
 wxTabTraversalWrapper (Args &&... args)
 
 wxTabTraversalWrapper (const wxTabTraversalWrapper &)=delete
 
 wxTabTraversalWrapper (wxTabTraversalWrapper &&)=delete
 
wxTabTraversalWrapperoperator= (const wxTabTraversalWrapper &)=delete
 
wxTabTraversalWrapperoperator= (wxTabTraversalWrapper &&)=delete
 

Private Attributes

wxCheckBox * mCreateCorrectionFile { nullptr }
 
wxChoice * mBitRate
 

Detailed Description

Definition at line 44 of file ExportWavPack.cpp.

Constructor & Destructor Documentation

◆ ExportWavPackOptions()

ExportWavPackOptions::ExportWavPackOptions ( wxWindow *  parent,
int  format 
)

Definition at line 70 of file ExportWavPack.cpp.

71: wxPanelWrapper(parent, wxID_ANY)
72{
75
77}
@ eIsCreatingFromPrefs
Definition: ShuttleGui.h:46
#define S(N)
Definition: ToChars.cpp:64
bool TransferDataToWindow() override
void PopulateOrExchange(ShuttleGui &S)
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition: ShuttleGui.h:625

References eIsCreatingFromPrefs, and S.

◆ ~ExportWavPackOptions()

ExportWavPackOptions::~ExportWavPackOptions ( )
virtual

Definition at line 79 of file ExportWavPack.cpp.

80{
82}
bool TransferDataFromWindow() override

References TransferDataFromWindow().

Here is the call graph for this function:

Member Function Documentation

◆ OnCreateCorrection()

void ExportWavPackOptions::OnCreateCorrection ( wxCommandEvent &  evt)

Definition at line 224 of file ExportWavPack.cpp.

225{
227};
bool Toggle()
Write the negation of the previous value, and then return the current value.
Definition: Prefs.cpp:514

References anonymous_namespace{ExportWavPack.cpp}::CreateCorrectionFileSetting, and BoolSetting::Toggle().

Here is the call graph for this function:

◆ OnHybridMode()

void ExportWavPackOptions::OnHybridMode ( wxCommandEvent &  evt)

Definition at line 217 of file ExportWavPack.cpp.

218{
219 const auto hybridMode = HybridModeSetting.Toggle();
220 mCreateCorrectionFile->Enable(hybridMode);
221 mBitRate->Enable(hybridMode);
222};
wxCheckBox * mCreateCorrectionFile

References anonymous_namespace{ExportWavPack.cpp}::HybridModeSetting, mBitRate, mCreateCorrectionFile, and BoolSetting::Toggle().

Here is the call graph for this function:

◆ PopulateOrExchange()

void ExportWavPackOptions::PopulateOrExchange ( ShuttleGui S)

Definition at line 156 of file ExportWavPack.cpp.

157{
158 bool hybridMode = HybridModeSetting.Read();
159
160 S.StartVerticalLay();
161 {
162 S.StartHorizontalLay(wxEXPAND);
163 {
164 S.SetSizerProportion(1);
165 S.StartMultiColumn(2, wxCENTER);
166 {
167 S.TieNumberAsChoice(
168 XXO("Quality"),
172 );
173
174 S.TieNumberAsChoice(
175 XXO("Bit Depth"),
179 );
180
181 S.Id(ID_HYBRID_MODE).TieCheckBox( XXO("Hybrid Mode"), HybridModeSetting);
182
183 mCreateCorrectionFile = S.Id(ID_CREATE_WVC).Disable(!hybridMode).TieCheckBox(
184 XXO("Create Correction(.wvc) File"),
186 );
187
188 mBitRate = S.Disable(!hybridMode).TieNumberAsChoice(
189 XXO("Bit Rate:"),
193 );
194 }
195 S.EndMultiColumn();
196 }
197 S.EndHorizontalLay();
198 }
199 S.EndVerticalLay();
200}
#define ID_HYBRID_MODE
const std::vector< int > ExportQualityValues
const TranslatableStrings ExportQualityNames
#define ID_CREATE_WVC
XXO("&Cut/Copy/Paste Toolbar")
bool Read(T *pVar) const
overload of Read returning a boolean that is true if the value was previously defined *‍/
Definition: Prefs.h:200
const TranslatableStrings ExportBitDepthNames
const std::vector< int > ExportBitDepthValues
const std::vector< int > BitRateValues
const TranslatableStrings BitRateNames

References anonymous_namespace{ExportWavPack.cpp}::BitDepthSetting, anonymous_namespace{ExportWavPack.cpp}::BitRateNames, anonymous_namespace{ExportWavPack.cpp}::BitrateSetting, anonymous_namespace{ExportWavPack.cpp}::BitRateValues, anonymous_namespace{ExportWavPack.cpp}::CreateCorrectionFileSetting, anonymous_namespace{ExportWavPack.cpp}::ExportBitDepthNames, anonymous_namespace{ExportWavPack.cpp}::ExportBitDepthValues, ExportQualityNames, ExportQualityValues, anonymous_namespace{ExportWavPack.cpp}::HybridModeSetting, ID_CREATE_WVC, ID_HYBRID_MODE, mBitRate, mCreateCorrectionFile, anonymous_namespace{ExportWavPack.cpp}::QualitySetting, Setting< T >::Read(), S, and XXO().

Referenced by TransferDataFromWindow().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TransferDataFromWindow()

bool ExportWavPackOptions::TransferDataFromWindow ( )
override

Definition at line 207 of file ExportWavPack.cpp.

208{
211
212 gPrefs->Flush();
213
214 return true;
215}
FileConfig * gPrefs
Definition: Prefs.cpp:70
@ eIsSavingToPrefs
Definition: ShuttleGui.h:47
virtual bool Flush(bool bCurrentOnly=false) wxOVERRIDE
Definition: FileConfig.cpp:143

References eIsSavingToPrefs, FileConfig::Flush(), gPrefs, PopulateOrExchange(), and S.

Referenced by ~ExportWavPackOptions().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TransferDataToWindow()

bool ExportWavPackOptions::TransferDataToWindow ( )
override

Definition at line 202 of file ExportWavPack.cpp.

203{
204 return true;
205}

Member Data Documentation

◆ mBitRate

wxChoice* ExportWavPackOptions::mBitRate
private

Definition at line 60 of file ExportWavPack.cpp.

Referenced by OnHybridMode(), and PopulateOrExchange().

◆ mCreateCorrectionFile

wxCheckBox* ExportWavPackOptions::mCreateCorrectionFile { nullptr }
private

Definition at line 59 of file ExportWavPack.cpp.

Referenced by OnHybridMode(), and PopulateOrExchange().


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