1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-05-06 14:52:34 +02:00

Make tool bar pushbuttons cooperate with Voiceover on Mac...

... Use Command+f5 to start VoiceOver, then control+alt+ left and right arrows
to navigate.

Much better now, but still we need to do something about sliders, meters, and
numeric text controls.
This commit is contained in:
Paul Licameli 2016-07-01 00:10:06 -04:00
parent 21239d19a1
commit acde3d6152
2 changed files with 6 additions and 5 deletions

View File

@ -35,7 +35,7 @@
#include "../Project.h"
#include <wx/tooltip.h>
BEGIN_EVENT_TABLE(AButton, wxWindow)
BEGIN_EVENT_TABLE(AButton, wxButton)
EVT_MOUSE_EVENTS(AButton::OnMouseEvent)
EVT_MOUSE_CAPTURE_LOST(AButton::OnCaptureLost)
EVT_KEY_DOWN(AButton::OnKeyDown)
@ -161,7 +161,7 @@ AButton::AButton(wxWindow * parent,
wxImage down,
wxImage dis,
bool toggle):
wxWindow()
wxButton()
{
Init(parent, id, pos, size,
ImageRoll(up), ImageRoll(over),
@ -178,7 +178,7 @@ AButton::AButton(wxWindow * parent,
ImageRoll down,
ImageRoll dis,
bool toggle):
wxWindow()
wxButton()
{
Init(parent, id, pos, size,
up, over, down, dis,
@ -205,7 +205,7 @@ void AButton::Init(wxWindow * parent,
// a navigation event - move to next control. As a workaround, the style wxWANTS_CHARS
// results in all characters being available in the OnKeyDown function below. Note
// that OnKeyDown now has to handle navigation.
Create(parent, id, pos, size, wxWANTS_CHARS);
Create(parent, id, wxEmptyString, pos, size, wxWANTS_CHARS | wxBORDER_NONE);
mWasShiftDown = false;
mWasControlDown = false;

View File

@ -19,12 +19,13 @@
#include <wx/access.h>
#endif
#include <wx/button.h>
#include <wx/image.h>
#include <wx/window.h>
#include "ImageRoll.h"
class AButton final : public wxWindow {
class AButton final : public wxButton {
friend class AButtonAx;
class Listener;