MCPcopy Create free account
hub / github.com/audacity/audacity / Init

Method Init

src/widgets/AButton.cpp:174–193  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

172
173
174void AButton::Init(wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, bool toggle)
175{
176 SetBackgroundStyle(wxBG_STYLE_PAINT);
177 SetBackgroundColour(theTheme.Colour(clrMedium));
178
179 // Bug in wxWidgets 2.8.12: by default pressing Enter on an AButton is interpreted as
180 // a navigation event - move to next control. As a workaround, the style wxWANTS_CHARS
181 // results in all characters being available in the OnKeyDown function below. Note
182 // that OnKeyDown now has to handle navigation.
183 Create(parent, id, pos, size, wxWANTS_CHARS);
184
185 mToggle = toggle;
186
187 mFocusRect = GetClientRect().Deflate( 3, 3 );
188
189#if wxUSE_ACCESSIBILITY
190 SetName( wxT("") );
191 SetAccessible(safenew AButtonAx(this));
192#endif
193}
194
195void AButton::UseDisabledAsDownHiliteImage(bool flag)
196{

Callers 7

DoRecordMethod · 0.45
BindMethod · 0.45
GetAudacityCommandMethod · 0.45
SetEffectParametersMethod · 0.45
DoClipMoveFunction · 0.45
doRecordMethod · 0.45
doPerformEffectMethod · 0.45

Calls 1

CreateFunction · 0.85

Tested by

no test coverage detected