mirror of
https://github.com/cookiengineer/audacity
synced 2025-05-02 00:29:41 +02:00
Fix more accessibility names after the move to wx 3.1.1
This is a follow up to commit f9ee3cd.
This commit is contained in:
parent
1c751fd863
commit
526606fc29
@ -85,6 +85,10 @@ and in the spectrogram spectral selection.
|
||||
#include "./widgets/HelpSystem.h"
|
||||
#include "widgets/ErrorDialog.h"
|
||||
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
#include "widgets/WindowAccessible.h"
|
||||
#endif
|
||||
|
||||
DEFINE_EVENT_TYPE(EVT_FREQWINDOW_RECALC);
|
||||
|
||||
enum {
|
||||
@ -309,6 +313,10 @@ FreqWindow::FreqWindow(wxWindow * parent, wxWindowID id,
|
||||
{
|
||||
mPanScroller = safenew wxScrollBar(this, FreqPanScrollerID,
|
||||
wxDefaultPosition, wxDefaultSize, wxSB_VERTICAL);
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
mPanScroller->SetAccessible(safenew WindowAccessible(mPanScroller));
|
||||
#endif
|
||||
mPanScroller->SetName(_("Scroll"));
|
||||
S.Prop(1);
|
||||
S.AddWindow(mPanScroller, wxALIGN_LEFT | wxTOP);
|
||||
@ -326,6 +334,10 @@ FreqWindow::FreqWindow(wxWindow * parent, wxWindowID id,
|
||||
wxDefaultPosition, wxDefaultSize, wxSL_VERTICAL);
|
||||
S.Prop(1);
|
||||
S.AddWindow(mZoomSlider, wxALIGN_CENTER_HORIZONTAL);
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
mZoomSlider->SetAccessible(safenew WindowAccessible(mZoomSlider));
|
||||
#endif
|
||||
mZoomSlider->SetName(_("Zoom"));
|
||||
|
||||
S.AddSpace(5);
|
||||
|
@ -48,6 +48,10 @@ for shared and private configs - which need to move out.
|
||||
#include "widgets/ErrorDialog.h"
|
||||
#include "widgets/ProgressDialog.h"
|
||||
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
#include "widgets/WindowAccessible.h"
|
||||
#endif
|
||||
|
||||
#include "PluginManager.h"
|
||||
|
||||
#include "Experimental.h"
|
||||
@ -540,15 +544,31 @@ void PluginRegistrationDialog::PopulateOrExchange(ShuttleGui &S)
|
||||
S.AddPrompt(_("Show:"));
|
||||
/* i18n-hint: Radio button to show all effects */
|
||||
rb = S.Id(ID_ShowAll).AddRadioButton(_("&All"));
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
rb->SetAccessible(safenew WindowAccessible(rb));
|
||||
#endif
|
||||
rb->SetName(_("Show all"));
|
||||
/* i18n-hint: Radio button to show just the currently disabled effects */
|
||||
rb = S.Id(ID_ShowDisabled).AddRadioButtonToGroup(_("D&isabled"));
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
rb->SetAccessible(safenew WindowAccessible(rb));
|
||||
#endif
|
||||
rb->SetName(_("Show disabled"));
|
||||
/* i18n-hint: Radio button to show just the currently enabled effects */
|
||||
rb = S.Id(ID_ShowEnabled).AddRadioButtonToGroup(_("E&nabled"));
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
rb->SetAccessible(safenew WindowAccessible(rb));
|
||||
#endif
|
||||
rb->SetName(_("Show enabled"));
|
||||
/* i18n-hint: Radio button to show just the newly discovered effects */
|
||||
rb = S.Id(ID_ShowNew).AddRadioButtonToGroup(_("Ne&w"));
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
rb->SetAccessible(safenew WindowAccessible(rb));
|
||||
#endif
|
||||
rb->SetName(_("Show new"));
|
||||
}
|
||||
S.EndHorizontalLay();
|
||||
|
@ -292,12 +292,17 @@ ContrastDialog::ContrastDialog(wxWindow * parent, wxWindowID id,
|
||||
{
|
||||
S.StartMultiColumn(3, wxCENTER);
|
||||
{
|
||||
S.AddFixedText(_("Co&ntrast Result:"));
|
||||
wxString label = _("Co&ntrast Result:");
|
||||
S.AddFixedText(label);
|
||||
mPassFailText = S.Id(ID_RESULTS_TEXT).AddTextBox( {}, wxT(""), 50);
|
||||
mPassFailText->SetName(wxStripMenuCodes(label));
|
||||
mPassFailText->Bind(wxEVT_KEY_DOWN, OnChar);
|
||||
m_pButton_Reset = S.Id(ID_BUTTON_RESET).AddButton(_("R&eset"));
|
||||
S.AddFixedText(_("&Difference:"));
|
||||
|
||||
label = _("&Difference:");
|
||||
S.AddFixedText(label);
|
||||
mDiffText = S.Id(ID_RESULTSDB_TEXT).AddTextBox( {}, wxT(""), 50);
|
||||
mDiffText->SetName(wxStripMenuCodes(label));
|
||||
mDiffText->Bind(wxEVT_KEY_DOWN, OnChar);
|
||||
m_pButton_Export = S.Id(ID_BUTTON_EXPORT).AddButton(_("E&xport..."));
|
||||
}
|
||||
|
@ -94,6 +94,10 @@
|
||||
#include "../../xml/XMLFileReader.h"
|
||||
#include "../../xml/XMLWriter.h"
|
||||
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
#include "../../widgets/WindowAccessible.h"
|
||||
#endif
|
||||
|
||||
#include "audacity/ConfigInterface.h"
|
||||
|
||||
#include "VSTEffect.h"
|
||||
@ -2932,6 +2936,10 @@ void VSTEffect::BuildPlain()
|
||||
wxDefaultPosition,
|
||||
wxSize(200, -1));
|
||||
gridSizer->Add(mSliders[i], 0, wxALIGN_CENTER_VERTICAL | wxEXPAND | wxALL, 5);
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
mSliders[i]->SetAccessible(safenew WindowAccessible(mSliders[i]));
|
||||
#endif
|
||||
|
||||
mDisplays[i] = safenew wxStaticText(scroller,
|
||||
wxID_ANY,
|
||||
|
@ -54,6 +54,10 @@ effects from this one class.
|
||||
#include "../../widgets/valnum.h"
|
||||
#include "../../widgets/wxPanelWrapper.h"
|
||||
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
#include "../../widgets/WindowAccessible.h"
|
||||
#endif
|
||||
|
||||
// ============================================================================
|
||||
// List of effects that ship with Audacity. These will be autoregistered.
|
||||
// ============================================================================
|
||||
@ -1328,6 +1332,10 @@ bool LadspaEffect::PopulateUI(wxWindow *parent)
|
||||
0, 0, 1000,
|
||||
wxDefaultPosition,
|
||||
wxSize(200, -1));
|
||||
#if wxUSE_ACCESSIBILITY
|
||||
// so that name can be set on a standard control
|
||||
mSliders[p]->SetAccessible(safenew WindowAccessible(mSliders[p]));
|
||||
#endif
|
||||
mSliders[p]->SetName(labelText);
|
||||
gridSizer->Add(mSliders[p], 0, wxALIGN_CENTER_VERTICAL | wxEXPAND | wxALL, 5);
|
||||
|
||||
@ -1450,7 +1458,7 @@ bool LadspaEffect::PopulateUI(wxWindow *parent)
|
||||
mInputControls[p] = roundf(mInputControls[p] * 1000000.0) / 1000000.0;
|
||||
|
||||
mMeters[p] = safenew LadspaEffectMeter(w, mOutputControls[p], lower, upper);
|
||||
mMeters[p]->SetName(labelText);
|
||||
mMeters[p]->SetLabel(labelText); // for screen readers
|
||||
gridSizer->Add(mMeters[p], 1, wxEXPAND | wxALIGN_CENTER_VERTICAL | wxALL, 5);
|
||||
}
|
||||
|
||||
|
@ -2443,7 +2443,8 @@ void NyquistEffect::BuildEffectWindow(ShuttleGui & S)
|
||||
{
|
||||
NyqControl & ctrl = mControls[i];
|
||||
|
||||
S.AddPrompt(ctrl.name + wxT(":"));
|
||||
wxString prompt = ctrl.name + wxT(" ");
|
||||
S.AddPrompt(prompt);
|
||||
|
||||
if (ctrl.type == NYQ_CTRL_STRING)
|
||||
{
|
||||
@ -2451,6 +2452,7 @@ void NyquistEffect::BuildEffectWindow(ShuttleGui & S)
|
||||
|
||||
wxTextCtrl *item = S.Id(ID_Text + i).AddTextBox( {}, wxT(""), 12);
|
||||
item->SetValidator(wxGenericValidator(&ctrl.valStr));
|
||||
item->SetName(prompt);
|
||||
}
|
||||
else if (ctrl.type == NYQ_CTRL_CHOICE)
|
||||
{
|
||||
@ -2471,6 +2473,7 @@ void NyquistEffect::BuildEffectWindow(ShuttleGui & S)
|
||||
wxTextCtrl *item = S.Id(ID_Text+i).AddTextBox( {}, wxT(""),
|
||||
(ctrl.type == NYQ_CTRL_INT_TEXT ||
|
||||
ctrl.type == NYQ_CTRL_FLOAT_TEXT) ? 25 : 12);
|
||||
item->SetName(prompt);
|
||||
|
||||
double range = ctrl.high - ctrl.low;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user