1
0
mirror of https://github.com/cookiengineer/audacity synced 2026-02-15 23:44:59 +01:00

This should fix bug #1111

In addition it adds an option to open the full FFmpeg options
dialog.
This commit is contained in:
Leland Lucius
2015-08-05 02:28:42 -05:00
parent 4cd7757cf4
commit 617e0713df
13 changed files with 467 additions and 152 deletions

View File

@@ -98,7 +98,11 @@ public:
ExportPCMOptions(wxWindow *parent, int format);
virtual ~ExportPCMOptions();
void PopulateOrExchange(ShuttleGui & S);
bool TransferDataToWindow();
bool TransferDataFromWindow();
void OnHeaderChoice(wxCommandEvent & evt);
private:
@@ -148,10 +152,9 @@ ExportPCMOptions::ExportPCMOptions(wxWindow *parent, int selformat)
for (int i = 0, sel = 0, num = sf_num_encodings(); i < num; i++) {
int enc = sf_encoding_index_to_subtype(i);
int fmt = (format & SF_FORMAT_TYPEMASK) | enc;
bool valid = ValidatePair(fmt);
bool valid = ValidatePair(fmt);
if (valid)
{
mEncodingNames.Add(sf_encoding_index_name(i));
mEncodingFormats.Add(enc);
if ((format & SF_FORMAT_SUBMASK) == (int)sf_encoding_index_to_subtype(i))
@@ -163,11 +166,13 @@ ExportPCMOptions::ExportPCMOptions(wxWindow *parent, int selformat)
ShuttleGui S(this, eIsCreatingFromPrefs);
PopulateOrExchange(S);
TransferDataToWindow();
}
ExportPCMOptions::~ExportPCMOptions()
{
WriteExportFormatPref(GetFormat());
TransferDataFromWindow();
}
void ExportPCMOptions::PopulateOrExchange(ShuttleGui & S)
@@ -197,6 +202,25 @@ void ExportPCMOptions::PopulateOrExchange(ShuttleGui & S)
return;
}
///
///
bool ExportPCMOptions::TransferDataToWindow()
{
return true;
}
///
///
bool ExportPCMOptions::TransferDataFromWindow()
{
ShuttleGui S(this, eIsSavingToPrefs);
PopulateOrExchange(S);
WriteExportFormatPref(GetFormat());
return true;
}
void ExportPCMOptions::OnHeaderChoice(wxCommandEvent & WXUNUSED(evt))
{
int format = sf_header_index_to_type(mHeaderChoice->GetSelection());