1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-10-25 07:43:54 +02:00

Emit an event when the preferences dialog closes

This commit is contained in:
Paul Licameli
2018-02-17 15:05:39 -05:00
parent a78ad42399
commit cc635e0498
3 changed files with 12 additions and 0 deletions

View File

@@ -844,6 +844,9 @@ void PrefsDialog::OnOK(wxCommandEvent & WXUNUSED(event))
}
#endif
// PRL: Is the following concern still valid, now that prefs update is
// handled instead by delayed event processing?
// LL: wxMac can't handle recreating the menus when this dialog is still active,
// so AudacityProject::UpdatePrefs() or any of the routines it calls must
// not cause MenuCreator::RebuildMenuBar() to be executed.
@@ -851,6 +854,8 @@ void PrefsDialog::OnOK(wxCommandEvent & WXUNUSED(event))
gAudacityProjects[i]->UpdatePrefs();
}
wxTheApp->AddPendingEvent(wxCommandEvent{ EVT_PREFS_UPDATE });
WaveformSettings::defaults().LoadPrefs();
SpectrogramSettings::defaults().LoadPrefs();