1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-17 09:07:41 +02:00

Bug 2692 - Mac: VI users get trapped in radio buttons of Keyboard Preferences

This also corrects similar problems in other locations as well.
This commit is contained in:
Leland Lucius 2021-04-01 20:00:12 -05:00
parent cf09d4feea
commit 7a55c90b9d
5 changed files with 140 additions and 89 deletions

View File

@ -854,7 +854,7 @@ void TimerRecordDialog::PopulateOrExchange(ShuttleGui& S)
m_pTimerSavePathTextCtrl = NewPathControl(
S.GetParent(), ID_AUTOSAVEPATH_TEXT,
XO("Save Project As:"), sInitialValue);
m_pTimerSavePathTextCtrl->SetEditable(false);
m_pTimerSavePathTextCtrl->SetReadOnly(true);
S.AddWindow(m_pTimerSavePathTextCtrl);
m_pTimerSavePathButtonCtrl = S.Id(ID_AUTOSAVEPATH_BUTTON).AddButton(XXO("Select..."));
}
@ -871,7 +871,7 @@ void TimerRecordDialog::PopulateOrExchange(ShuttleGui& S)
m_pTimerExportPathTextCtrl = NewPathControl(
S.GetParent(), ID_AUTOEXPORTPATH_TEXT,
XO("Export Project As:"), {});
m_pTimerExportPathTextCtrl->SetEditable(false);
m_pTimerExportPathTextCtrl->SetReadOnly(true);
S.AddWindow(m_pTimerExportPathTextCtrl);
m_pTimerExportPathButtonCtrl = S.Id(ID_AUTOEXPORTPATH_BUTTON).AddButton(XXO("Select..."));
}

View File

@ -345,6 +345,11 @@ void ExportMP3Options::PopulateOrExchange(ShuttleGui & S)
S.StartTwoColumn();
{
S.AddPrompt(XXO("Bit Rate Mode:"));
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartHorizontalLay();
{
S.StartRadioButtonGroup(MP3RateModeSetting);
@ -357,6 +362,8 @@ void ExportMP3Options::PopulateOrExchange(ShuttleGui & S)
S.EndRadioButtonGroup();
}
S.EndHorizontalLay();
}
S.EndPanel();
/* PRL: unfortunately this bit of procedural code must
interrupt the mostly-declarative dialog description, until
@ -407,7 +414,13 @@ void ExportMP3Options::PopulateOrExchange(ShuttleGui & S)
varModeNames );
S.AddPrompt(XXO("Channel Mode:"));
S.StartMultiColumn(3, wxEXPAND);
S.StartMultiColumn(2, wxEXPAND);
{
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartHorizontalLay();
{
S.StartRadioButtonGroup(MP3ChannelModeSetting);
{
@ -417,10 +430,14 @@ void ExportMP3Options::PopulateOrExchange(ShuttleGui & S)
.TieRadioButton();
}
S.EndRadioButtonGroup();
}
S.EndHorizontalLay();
}
S.EndPanel();
mMono = S.Id(ID_MONO).AddCheckBox(XXO("Force export to mono"), mono);
}
S.EndTwoColumn();
S.EndMultiColumn();
}
S.EndTwoColumn();
}

View File

@ -329,6 +329,11 @@ void ExportMultipleDialog::PopulateOrExchange(ShuttleGui& S)
{
// Row 1
S.SetBorder(1);
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
mTrack = S.Id(TrackID)
.AddRadioButton(XXO("Tracks"));
@ -336,8 +341,10 @@ void ExportMultipleDialog::PopulateOrExchange(ShuttleGui& S)
S.SetBorder(1);
mLabel = S.Id(LabelID)
.AddRadioButtonToGroup(XXO("Labels"));
S.SetBorder(3);
}
S.EndPanel();
S.SetBorder(3);
S.StartMultiColumn(2, wxEXPAND);
S.SetStretchyCol(1);
{
@ -372,6 +379,11 @@ void ExportMultipleDialog::PopulateOrExchange(ShuttleGui& S)
S.StartStatic(XO("Name files:"), 1);
{
S.SetBorder(2);
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartRadioButtonGroup({
wxT("/Export/TrackNameWithOrWithoutNumbers"),
{
@ -389,6 +401,8 @@ void ExportMultipleDialog::PopulateOrExchange(ShuttleGui& S)
mByNumber = S.Id(ByNumberID).TieRadioButton();
}
S.EndRadioButtonGroup();
}
S.EndPanel();
S.StartMultiColumn(3, wxEXPAND);
S.SetStretchyCol(2);

View File

@ -109,6 +109,10 @@ void ImportExportPrefs::PopulateOrExchange(ShuttleGui & S)
S.StartScroller();
S.StartStatic(XO("When exporting tracks to an audio file"));
{
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartRadioButtonGroup(ImportExportPrefs::ExportDownMixSetting);
{
@ -116,6 +120,8 @@ void ImportExportPrefs::PopulateOrExchange(ShuttleGui & S)
S.TieRadioButton();
}
S.EndRadioButtonGroup();
}
S.EndPanel();
S.TieCheckBox(XXO("S&how Metadata Tags editor before export"),
{wxT("/AudioFiles/ShowId3Dialog"),
@ -128,6 +134,10 @@ void ImportExportPrefs::PopulateOrExchange(ShuttleGui & S)
S.EndStatic();
S.StartStatic(XO("Exported Label Style:"));
{
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartRadioButtonGroup(ImportExportPrefs::LabelStyleSetting);
{
@ -136,10 +146,16 @@ void ImportExportPrefs::PopulateOrExchange(ShuttleGui & S)
}
S.EndRadioButtonGroup();
}
S.EndPanel();
}
S.EndStatic();
#ifdef USE_MIDI
S.StartStatic(XO("Exported Allegro (.gro) files save time as:"));
{
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartRadioButtonGroup(ImportExportPrefs::AllegroStyleSetting);
{
@ -148,6 +164,8 @@ void ImportExportPrefs::PopulateOrExchange(ShuttleGui & S)
}
S.EndRadioButtonGroup();
}
S.EndPanel();
}
S.EndStatic();
#endif
S.EndScroller();

View File

@ -176,13 +176,16 @@ void KeyConfigPrefs::PopulateOrExchange(ShuttleGui & S)
S.StartStatic(XO("Key Bindings"), 1);
{
S.StartMultiColumn(3, wxEXPAND);
S.StartHorizontalLay(wxEXPAND, 0);
{
S.SetStretchyCol(1);
S.Position(wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL).AddTitle(XO("View by:"));
S.StartHorizontalLay(wxALIGN_LEFT|wxALIGN_CENTER_VERTICAL, 0);
// Bug 2692: Place button group in panel so tabbing will work and,
// on the Mac, VoiceOver will announce as radio buttons.
S.StartPanel();
{
S.StartHorizontalLay();
{
S.AddTitle(XO("View by:"));
S.StartRadioButtonGroup({
wxT("/Prefs/KeyConfig/ViewBy"),
{
@ -202,7 +205,7 @@ void KeyConfigPrefs::PopulateOrExchange(ShuttleGui & S)
mViewByKey = S.Id(ViewByKeyID)
.Name(XO("View by key"))
.TieRadioButton();
#if wxUSE_ACCESSIBILITY
#if !defined(__WXMAC__) && wxUSE_ACCESSIBILITY
// so that name can be set on a standard control
if (mViewByTree) mViewByTree->SetAccessible(safenew WindowAccessible(mViewByTree));
if (mViewByName) mViewByName->SetAccessible(safenew WindowAccessible(mViewByName));
@ -212,16 +215,14 @@ void KeyConfigPrefs::PopulateOrExchange(ShuttleGui & S)
S.EndRadioButtonGroup();
}
S.EndHorizontalLay();
S.StartHorizontalLay(wxALIGN_CENTER|wxALIGN_CENTER_VERTICAL, 0);
{
// just a spacer
}
S.EndHorizontalLay();
S.EndPanel();
S.StartHorizontalLay(wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL, 0);
S.AddSpace(wxDefaultCoord, wxDefaultCoord, 1);
S.StartHorizontalLay(wxALIGN_CENTER_VERTICAL, 0);
{
mFilterLabel = S.AddVariableText(XO("Searc&h:"));
mFilterLabel = S.Position(wxALIGN_CENTER_VERTICAL).AddVariableText(XO("Searc&h:"));
if (!mFilter) {
mFilter = safenew wxTextCtrl(S.GetParent(),
@ -245,8 +246,9 @@ void KeyConfigPrefs::PopulateOrExchange(ShuttleGui & S)
}
S.EndHorizontalLay();
}
S.EndThreeColumn();
S.AddSpace(-1, 2);
S.EndHorizontalLay();
S.AddSpace(wxDefaultCoord, 2);
S.StartHorizontalLay(wxEXPAND, 1);
{
@ -273,7 +275,7 @@ void KeyConfigPrefs::PopulateOrExchange(ShuttleGui & S)
wxSize(210, -1),
#endif
wxTE_PROCESS_ENTER);
#if wxUSE_ACCESSIBILITY
#if !defined(__WXMAC__) && wxUSE_ACCESSIBILITY
// so that name can be set on a standard control
mKey->SetAccessible(safenew WindowAccessible(mKey));
#endif