mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-17 00:20:06 +02:00
Merge remote-tracking branch 'leland/master'
This commit is contained in:
commit
0d4b58ba1c
@ -43,7 +43,7 @@ bool ShuttlePrefs::TransferBool( const wxString & Name, bool & bValue, const boo
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return (gPrefs->Write( Name, bValue ) && gPrefs->Flush());
|
return gPrefs->Write( Name, bValue );
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -57,7 +57,7 @@ bool ShuttlePrefs::TransferDouble( const wxString & Name, double & dValue, const
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return (gPrefs->Write( Name, dValue ) && gPrefs->Flush());
|
return gPrefs->Write( Name, dValue );
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -71,7 +71,7 @@ bool ShuttlePrefs::TransferInt( const wxString & Name, int & iValue, const int &
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return (gPrefs->Write( Name, iValue ) && gPrefs->Flush());
|
return gPrefs->Write( Name, iValue );
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -85,7 +85,7 @@ bool ShuttlePrefs::TransferString( const wxString & Name, wxString & strValue, c
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return (gPrefs->Write( Name, strValue ) && gPrefs->Flush());
|
return gPrefs->Write( Name, strValue );
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -67,6 +67,9 @@ void SoundActivatedRecord::OnOK(wxCommandEvent & WXUNUSED(event))
|
|||||||
{
|
{
|
||||||
ShuttleGui S( this, eIsSavingToPrefs );
|
ShuttleGui S( this, eIsSavingToPrefs );
|
||||||
PopulateOrExchange( S );
|
PopulateOrExchange( S );
|
||||||
|
|
||||||
|
gPrefs->Flush();
|
||||||
|
|
||||||
EndModal(0);
|
EndModal(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3170,8 +3170,6 @@ void TrackArtist::UpdatePrefs()
|
|||||||
{
|
{
|
||||||
mdBrange = gPrefs->Read(ENV_DB_KEY, mdBrange);
|
mdBrange = gPrefs->Read(ENV_DB_KEY, mdBrange);
|
||||||
mShowClipping = gPrefs->Read(wxT("/GUI/ShowClipping"), mShowClipping);
|
mShowClipping = gPrefs->Read(wxT("/GUI/ShowClipping"), mShowClipping);
|
||||||
|
|
||||||
gPrefs->Flush();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Draws the sync-lock bitmap, tiled; always draws stationary relative to the DC
|
// Draws the sync-lock bitmap, tiled; always draws stationary relative to the DC
|
||||||
|
@ -1391,14 +1391,17 @@ void EffectEqualization::LoadCurves(wxString fileName, bool append)
|
|||||||
}
|
}
|
||||||
if( !fn.FileExists() )
|
if( !fn.FileExists() )
|
||||||
{
|
{
|
||||||
wxString errorMessage;
|
// LLL: Is there really a need for an error message at all???
|
||||||
errorMessage.Printf(_("EQCurves.xml and EQDefaultCurves.xml were not found on your system.\nPlease press 'help' to visit the download page.\n\nSave the curves at %s"), FileNames::DataDir().c_str());
|
//wxString errorMessage;
|
||||||
ShowErrorDialog(mUIParent, _("EQCurves.xml and EQDefaultCurves.xml missing"),
|
//errorMessage.Printf(_("EQCurves.xml and EQDefaultCurves.xml were not found on your system.\nPlease press 'help' to visit the download page.\n\nSave the curves at %s"), FileNames::DataDir().c_str());
|
||||||
errorMessage, wxT("http://wiki.audacityteam.org/wiki/EQCurvesDownload"), false);
|
//ShowErrorDialog(mUIParent, _("EQCurves.xml and EQDefaultCurves.xml missing"),
|
||||||
|
// errorMessage, wxT("http://wiki.audacityteam.org/wiki/EQCurvesDownload"), false);
|
||||||
|
|
||||||
// Have another go at finding EQCurves.xml in the data dir, in case 'help' helped
|
// Have another go at finding EQCurves.xml in the data dir, in case 'help' helped
|
||||||
fn = wxFileName( FileNames::DataDir(), wxT("EQDefaultCurves.xml") );
|
fn = wxFileName( FileNames::DataDir(), wxT("EQDefaultCurves.xml") );
|
||||||
if( !fn.FileExists() )
|
if( !fn.FileExists() )
|
||||||
{
|
{
|
||||||
|
mCurves.Clear();
|
||||||
mCurves.Add( _("unnamed") ); // we still need a default curve to use
|
mCurves.Add( _("unnamed") ); // we still need a default curve to use
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -1990,9 +1990,12 @@ void ExportFFmpegOptions::OnOK(wxCommandEvent& WXUNUSED(event))
|
|||||||
if (selcdc > -1) gPrefs->Write(wxT("/FileFormats/FFmpegCodec"),mCodecList->GetString(selcdc));
|
if (selcdc > -1) gPrefs->Write(wxT("/FileFormats/FFmpegCodec"),mCodecList->GetString(selcdc));
|
||||||
if (selfmt > -1) gPrefs->Write(wxT("/FileFormats/FFmpegFormat"),mFormatList->GetString(selfmt));
|
if (selfmt > -1) gPrefs->Write(wxT("/FileFormats/FFmpegFormat"),mFormatList->GetString(selfmt));
|
||||||
gPrefs->Flush();
|
gPrefs->Flush();
|
||||||
|
|
||||||
ShuttleGui S(this, eIsSavingToPrefs);
|
ShuttleGui S(this, eIsSavingToPrefs);
|
||||||
PopulateOrExchange(S);
|
PopulateOrExchange(S);
|
||||||
|
|
||||||
|
gPrefs->Flush();
|
||||||
|
|
||||||
EndModal(wxID_OK);
|
EndModal(wxID_OK);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
@ -522,6 +522,8 @@ void ExportMultiple::OnExport(wxCommandEvent& WXUNUSED(event))
|
|||||||
ShuttleGui S(this, eIsSavingToPrefs);
|
ShuttleGui S(this, eIsSavingToPrefs);
|
||||||
PopulateOrExchange(S);
|
PopulateOrExchange(S);
|
||||||
|
|
||||||
|
gPrefs->Flush();
|
||||||
|
|
||||||
// Make sure the output directory is in good shape
|
// Make sure the output directory is in good shape
|
||||||
if (!DirOk()) {
|
if (!DirOk()) {
|
||||||
return;
|
return;
|
||||||
|
@ -216,6 +216,8 @@ bool ExportPCMOptions::TransferDataFromWindow()
|
|||||||
ShuttleGui S(this, eIsSavingToPrefs);
|
ShuttleGui S(this, eIsSavingToPrefs);
|
||||||
PopulateOrExchange(S);
|
PopulateOrExchange(S);
|
||||||
|
|
||||||
|
gPrefs->Flush();
|
||||||
|
|
||||||
WriteExportFormatPref(GetFormat());
|
WriteExportFormatPref(GetFormat());
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -347,7 +347,6 @@ bool DevicePrefs::Apply()
|
|||||||
}
|
}
|
||||||
if (map) {
|
if (map) {
|
||||||
gPrefs->Write(wxT("/AudioIO/PlaybackDevice"), map->deviceString);
|
gPrefs->Write(wxT("/AudioIO/PlaybackDevice"), map->deviceString);
|
||||||
gPrefs->Flush();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
map = NULL;
|
map = NULL;
|
||||||
@ -368,7 +367,6 @@ bool DevicePrefs::Apply()
|
|||||||
}
|
}
|
||||||
gPrefs->Write(wxT("/AudioIO/RecordChannels"),
|
gPrefs->Write(wxT("/AudioIO/RecordChannels"),
|
||||||
mChannels->GetSelection() + 1);
|
mChannels->GetSelection() + 1);
|
||||||
return gPrefs->Flush();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -407,6 +407,8 @@ void PrefsDialog::OnOK(wxCommandEvent & WXUNUSED(event))
|
|||||||
else
|
else
|
||||||
mUniquePage->Apply();
|
mUniquePage->Apply();
|
||||||
|
|
||||||
|
gPrefs->Flush();
|
||||||
|
|
||||||
SavePreferredPage();
|
SavePreferredPage();
|
||||||
|
|
||||||
#if USE_PORTMIXER
|
#if USE_PORTMIXER
|
||||||
@ -443,7 +445,6 @@ void PrefsDialog::OnOK(wxCommandEvent & WXUNUSED(event))
|
|||||||
|
|
||||||
WaveformSettings::defaults().LoadPrefs();
|
WaveformSettings::defaults().LoadPrefs();
|
||||||
|
|
||||||
gPrefs->Flush();
|
|
||||||
EndModal(true);
|
EndModal(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -189,7 +189,6 @@ bool RecordingPrefs::Apply()
|
|||||||
if (targetpeak + deltapeak > 100.0 || targetpeak - deltapeak < 0.0)
|
if (targetpeak + deltapeak > 100.0 || targetpeak - deltapeak < 0.0)
|
||||||
{
|
{
|
||||||
gPrefs->Write(wxT("/AudioIO/DeltaPeakVolume"), min(100.0 - targetpeak, targetpeak));
|
gPrefs->Write(wxT("/AudioIO/DeltaPeakVolume"), min(100.0 - targetpeak, targetpeak));
|
||||||
gPrefs->Flush();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int value;
|
int value;
|
||||||
@ -201,7 +200,7 @@ bool RecordingPrefs::Apply()
|
|||||||
if (value < 0)
|
if (value < 0)
|
||||||
gPrefs->Write(wxT("/AudioIO/NumberAnalysis"), AILA_DEF_NUMBER_ANALYSIS);
|
gPrefs->Write(wxT("/AudioIO/NumberAnalysis"), AILA_DEF_NUMBER_ANALYSIS);
|
||||||
#endif
|
#endif
|
||||||
return gPrefs->Flush();
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
PrefsPanel *RecordingPrefsFactory::Create(wxWindow *parent)
|
PrefsPanel *RecordingPrefsFactory::Create(wxWindow *parent)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user