mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-26 07:13:49 +01:00
Fix crash initializing GlobalPrefsDialog for special case of undefined temp...
... directory at startup time.
This commit is contained in:
@@ -386,18 +386,13 @@ void PrefsDialog::SelectPageByName(wxString pageName)
|
||||
}
|
||||
}
|
||||
|
||||
void PrefsDialog::ShowTempDirPage()
|
||||
{
|
||||
SelectPageByName(_("Directories"));
|
||||
}
|
||||
|
||||
int PrefsDialog::GetSelectedPage() const
|
||||
{
|
||||
return mCategories->GetSelection();
|
||||
}
|
||||
|
||||
GlobalPrefsDialog::GlobalPrefsDialog(wxWindow * parent)
|
||||
: PrefsDialog(parent, _("Preferences: "), DefaultFactories())
|
||||
GlobalPrefsDialog::GlobalPrefsDialog(wxWindow * parent, Factories &factories)
|
||||
: PrefsDialog(parent, _("Preferences: "), factories)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -58,7 +58,6 @@ class PrefsDialog:public wxDialog
|
||||
void OnTreeKeyDown(wxTreeEvent & e); // Used to dismiss the dialog when enter is pressed with focus on tree
|
||||
|
||||
void SelectPageByName(wxString pageName);
|
||||
void ShowTempDirPage();
|
||||
|
||||
// Accessor to help implementations of SavePreferredPage(),
|
||||
// such as by saving a preference after DoModal() returns
|
||||
@@ -85,7 +84,7 @@ private:
|
||||
class GlobalPrefsDialog : public PrefsDialog
|
||||
{
|
||||
public:
|
||||
GlobalPrefsDialog(wxWindow * parent);
|
||||
GlobalPrefsDialog(wxWindow * parent, Factories &factories = DefaultFactories());
|
||||
virtual ~GlobalPrefsDialog();
|
||||
virtual long GetPreferredPage();
|
||||
virtual void SavePreferredPage();
|
||||
|
||||
Reference in New Issue
Block a user