1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-25 15:53:52 +02:00

Enable help button for effects

This commit is contained in:
Steve Daulton
2017-05-15 22:00:33 +01:00
parent 429fad6f88
commit 469120cebd
8 changed files with 57 additions and 11 deletions

View File

@@ -118,19 +118,20 @@ int wxTreebookExt::SetSelection(size_t n)
wxWindow *const applyButton = wxWindow::FindWindowById(wxID_APPLY, GetParent());
if (helpButton) {
#if defined(__WXMAC__)
// We don't appear to have accelerators on wxMac
#else
if (showHelp) {
wxAcceleratorEntry entries[1];
entries[0].Set(wxACCEL_ALT, (int) 'H', wxID_HELP);
#if defined(__WXMAC__)
entries[0].Set(wxACCEL_CTRL, (int) '?', wxID_HELP);
#else
entries[0].Set(wxACCEL_NORMAL, (int) WXK_F1, wxID_HELP);
#endif
wxAcceleratorTable accel(1, entries);
this->SetAcceleratorTable(accel);
}
else {
this->SetAcceleratorTable(wxNullAcceleratorTable);
}
#endif
const bool changed = helpButton->Show(showHelp);
if (changed)
GetParent()->Layout();