mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-16 16:10:06 +02:00
Remove GTK workarounds (or the reason for them)
This commit is contained in:
parent
fdd725fc68
commit
dfcad8a926
@ -267,55 +267,44 @@ void EffectBassTreble::PopulateOrExchange(ShuttleGui & S)
|
|||||||
{
|
{
|
||||||
S.StartVerticalLay(0);
|
S.StartVerticalLay(0);
|
||||||
{
|
{
|
||||||
S.StartStatic(wxT(""));
|
S.StartMultiColumn(3, wxEXPAND);
|
||||||
|
S.SetStretchyCol(2);
|
||||||
{
|
{
|
||||||
S.StartMultiColumn(3, wxEXPAND);
|
// Bass control
|
||||||
S.SetStretchyCol(2);
|
FloatingPointValidator<double> vldBass(1, &dB_bass);
|
||||||
{
|
vldBass.SetRange(MIN_Bass, MAX_Bass);
|
||||||
#ifdef __WXGTK__
|
mBassT = S.Id(ID_Bass).AddTextBox(_("&Bass (dB):"), wxT(""), 10);
|
||||||
// BoxSizer is to make first mnemonic work, on Linux.
|
mBassT->SetName(_("Bass (dB):"));
|
||||||
wxPanel* cPanel = new wxPanel(S.GetParent(), wxID_ANY);
|
mBassT->SetValidator(vldBass);
|
||||||
wxBoxSizer* cSizer = new wxBoxSizer(wxVERTICAL);
|
|
||||||
cPanel->SetSizer(cSizer);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// Bass control
|
S.SetStyle(wxSL_HORIZONTAL);
|
||||||
FloatingPointValidator<double> vldBass(1, &dB_bass);
|
mBassS = S.Id(ID_Bass).AddSlider(wxT(""), 0, MAX_Bass * kSliderScale, MIN_Bass * kSliderScale);
|
||||||
vldBass.SetRange(MIN_Bass, MAX_Bass);
|
mBassS->SetName(_("Bass"));
|
||||||
mBassT = S.Id(ID_Bass).AddTextBox(_("&Bass (dB):"), wxT(""), 10);
|
mBassS->SetPageSize(30);
|
||||||
mBassT->SetName(_("Bass (dB):"));
|
|
||||||
mBassT->SetValidator(vldBass);
|
|
||||||
|
|
||||||
S.SetStyle(wxSL_HORIZONTAL);
|
// Treble control
|
||||||
mBassS = S.Id(ID_Bass).AddSlider(wxT(""), 0, MAX_Bass * kSliderScale, MIN_Bass * kSliderScale);
|
FloatingPointValidator<double> vldTreble(1, &dB_treble);
|
||||||
mBassS->SetName(_("Bass"));
|
vldTreble.SetRange(MIN_Treble, MAX_Treble);
|
||||||
mBassS->SetPageSize(30);
|
mTrebleT = S.Id(ID_Treble).AddTextBox(_("&Treble (dB):"), wxT(""), 10);
|
||||||
|
mTrebleT->SetValidator(vldTreble);
|
||||||
|
|
||||||
// Treble control
|
S.SetStyle(wxSL_HORIZONTAL);
|
||||||
FloatingPointValidator<double> vldTreble(1, &dB_treble);
|
mTrebleS = S.Id(ID_Treble).AddSlider(wxT(""), 0, MAX_Treble * kSliderScale, MIN_Treble * kSliderScale);
|
||||||
vldTreble.SetRange(MIN_Treble, MAX_Treble);
|
mTrebleS->SetName(_("Treble"));
|
||||||
mTrebleT = S.Id(ID_Treble).AddTextBox(_("&Treble (dB):"), wxT(""), 10);
|
mTrebleS->SetPageSize(30);
|
||||||
mTrebleT->SetValidator(vldTreble);
|
|
||||||
|
|
||||||
S.SetStyle(wxSL_HORIZONTAL);
|
// Level control
|
||||||
mTrebleS = S.Id(ID_Treble).AddSlider(wxT(""), 0, MAX_Treble * kSliderScale, MIN_Treble * kSliderScale);
|
FloatingPointValidator<double> vldLevel(1, &dB_level);
|
||||||
mTrebleS->SetName(_("Treble"));
|
vldLevel.SetRange(MIN_Level, MAX_Level);
|
||||||
mTrebleS->SetPageSize(30);
|
mLevelT = S.Id(ID_Level).AddTextBox(_("&Level (dB):"), wxT(""), 10);
|
||||||
|
mLevelT->SetValidator(vldLevel);
|
||||||
|
|
||||||
// Level control
|
S.SetStyle(wxSL_HORIZONTAL);
|
||||||
FloatingPointValidator<double> vldLevel(1, &dB_level);
|
mLevelS = S.Id(ID_Level).AddSlider(wxT(""), 0, MAX_Level * kSliderScale, MIN_Level * kSliderScale);
|
||||||
vldLevel.SetRange(MIN_Level, MAX_Level);
|
mLevelS->SetName(_("Level"));
|
||||||
mLevelT = S.Id(ID_Level).AddTextBox(_("&Level (dB):"), wxT(""), 10);
|
mLevelS->SetPageSize(30);
|
||||||
mLevelT->SetValidator(vldLevel);
|
|
||||||
|
|
||||||
S.SetStyle(wxSL_HORIZONTAL);
|
|
||||||
mLevelS = S.Id(ID_Level).AddSlider(wxT(""), 0, MAX_Level * kSliderScale, MIN_Level * kSliderScale);
|
|
||||||
mLevelS->SetName(_("Level"));
|
|
||||||
mLevelS->SetPageSize(30);
|
|
||||||
}
|
|
||||||
S.EndMultiColumn();
|
|
||||||
}
|
}
|
||||||
S.EndStatic();
|
S.EndMultiColumn();
|
||||||
|
|
||||||
// Normalize checkbox
|
// Normalize checkbox
|
||||||
S.StartHorizontalLay(wxLEFT, true);
|
S.StartHorizontalLay(wxLEFT, true);
|
||||||
|
@ -350,10 +350,7 @@ void EffectClickRemoval::PopulateOrExchange(ShuttleGui & S)
|
|||||||
mThreshS = S.Id(ID_Thresh).AddSlider(wxT(""), mThresholdLevel, MAX_Threshold, MIN_Threshold);
|
mThreshS = S.Id(ID_Thresh).AddSlider(wxT(""), mThresholdLevel, MAX_Threshold, MIN_Threshold);
|
||||||
mThreshS->SetName(_("Threshold"));
|
mThreshS->SetName(_("Threshold"));
|
||||||
mThreshS->SetValidator(wxGenericValidator(&mThresholdLevel));
|
mThreshS->SetValidator(wxGenericValidator(&mThresholdLevel));
|
||||||
#if defined(__WXGTK__)
|
mThreshS->SetMinSize(wxSize(150, -1));
|
||||||
// Force a minimum size since wxGTK allows it to go to zero
|
|
||||||
mThreshS->SetMinSize(wxSize(100, -1));
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// Click width
|
// Click width
|
||||||
IntegerValidator<int> vldWidth(&mClickWidth);
|
IntegerValidator<int> vldWidth(&mClickWidth);
|
||||||
@ -367,10 +364,7 @@ void EffectClickRemoval::PopulateOrExchange(ShuttleGui & S)
|
|||||||
mWidthS = S.Id(ID_Width).AddSlider(wxT(""), mClickWidth, MAX_Width, MIN_Width);
|
mWidthS = S.Id(ID_Width).AddSlider(wxT(""), mClickWidth, MAX_Width, MIN_Width);
|
||||||
mWidthS->SetName(_("Max Spike Width"));
|
mWidthS->SetName(_("Max Spike Width"));
|
||||||
mWidthS->SetValidator(wxGenericValidator(&mClickWidth));
|
mWidthS->SetValidator(wxGenericValidator(&mClickWidth));
|
||||||
#if defined(__WXGTK__)
|
mWidthS->SetMinSize(wxSize(150, -1));
|
||||||
// Force a minimum size since wxGTK allows it to go to zero
|
|
||||||
mWidthS->SetMinSize(wxSize(100, -1));
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
S.EndMultiColumn();
|
S.EndMultiColumn();
|
||||||
|
|
||||||
|
@ -1691,13 +1691,6 @@ void EffectNoiseReduction::Dialog::PopulateOrExchange(ShuttleGui & S)
|
|||||||
S.AddVariableText(_(
|
S.AddVariableText(_(
|
||||||
"Select all of the audio you want filtered, choose how much noise you want\nfiltered out, and then click 'OK' to reduce noise.\n"));
|
"Select all of the audio you want filtered, choose how much noise you want\nfiltered out, and then click 'OK' to reduce noise.\n"));
|
||||||
|
|
||||||
#if defined(__WXGTK__)
|
|
||||||
// Put everything inside a panel to workaround a problem on Linux where the access key
|
|
||||||
// does not work if it is defined within static text on the first control.
|
|
||||||
S.SetStyle(wxTAB_TRAVERSAL);
|
|
||||||
S.StartPanel();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
S.StartMultiColumn(3, wxEXPAND);
|
S.StartMultiColumn(3, wxEXPAND);
|
||||||
S.SetStretchyCol(2);
|
S.SetStretchyCol(2);
|
||||||
{
|
{
|
||||||
@ -1733,10 +1726,6 @@ void EffectNoiseReduction::Dialog::PopulateOrExchange(ShuttleGui & S)
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
S.EndMultiColumn();
|
S.EndMultiColumn();
|
||||||
|
|
||||||
#if defined(__WXGTK__)
|
|
||||||
S.EndPanel();
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
S.EndStatic();
|
S.EndStatic();
|
||||||
|
|
||||||
@ -1744,13 +1733,6 @@ void EffectNoiseReduction::Dialog::PopulateOrExchange(ShuttleGui & S)
|
|||||||
#ifdef ADVANCED_SETTINGS
|
#ifdef ADVANCED_SETTINGS
|
||||||
S.StartStatic(_("Advanced Settings"));
|
S.StartStatic(_("Advanced Settings"));
|
||||||
{
|
{
|
||||||
#if defined(__WXGTK__)
|
|
||||||
// Put everything inside a panel to workaround a problem on Linux where the access key
|
|
||||||
// does not work if it is defined within static text on the first control.
|
|
||||||
S.SetStyle(wxTAB_TRAVERSAL);
|
|
||||||
S.StartPanel();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
S.StartMultiColumn(2);
|
S.StartMultiColumn(2);
|
||||||
{
|
{
|
||||||
{
|
{
|
||||||
@ -1820,10 +1802,6 @@ void EffectNoiseReduction::Dialog::PopulateOrExchange(ShuttleGui & S)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
S.EndMultiColumn();
|
S.EndMultiColumn();
|
||||||
|
|
||||||
#if defined(__WXGTK__)
|
|
||||||
S.EndPanel();
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
S.EndStatic();
|
S.EndStatic();
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user