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

Update Help link for Spectrogram Settings

This commit is contained in:
Steve Daulton 2017-05-22 15:11:39 +01:00
parent 6a9e0ffe28
commit 2fcf715972

View File

@ -289,7 +289,16 @@ PrefsDialog::PrefsDialog
const PrefsNode &node = factories[0]; const PrefsNode &node = factories[0];
PrefsPanelFactory &factory = *node.pFactory; PrefsPanelFactory &factory = *node.pFactory;
mUniquePage = factory.Create(this); mUniquePage = factory.Create(this);
S.AddWindow(mUniquePage, wxEXPAND); wxWindow * uniquePageWindow = S.AddWindow(mUniquePage, wxEXPAND);
// We're not in the wxTreebook, so add the accelerator here
wxAcceleratorEntry entries[1];
#if defined(__WXMAC__)
// Is there a standard shortcut on Mac?
#else
entries[0].Set(wxACCEL_NORMAL, (int) WXK_F1, wxID_HELP);
#endif
wxAcceleratorTable accel(1, entries);
uniquePageWindow->SetAcceleratorTable(accel);
} }
} }
S.EndVerticalLay(); S.EndVerticalLay();
@ -413,11 +422,10 @@ void PrefsDialog::OnHelp(wxCommandEvent & WXUNUSED(event))
// Currently (May2017) Spectrum Settings is the only preferences // Currently (May2017) Spectrum Settings is the only preferences
// we ever display in a dialog on its own without others. // we ever display in a dialog on its own without others.
// We do so when it is configuring spectrums for a track. // We do so when it is configuring spectrums for a track.
// It is called 'settings' rather than 'preferences' in this context.
// Because this happens, we want to visit a different help page. // Because this happens, we want to visit a different help page.
// So we modify the page name in the case of a page on its own. // So we change the page name in the case of a page on its own.
if( !mCategories) if( !mCategories)
page.Replace( "Spectrograms_Preferences", "Spectrogram_View#spectrogram_settings" ); page.Replace( "Spectrograms_Preferences", "Spectrogram_Settings" );
HelpSystem::ShowHelpDialog(this, page, true); HelpSystem::ShowHelpDialog(this, page, true);
} }