1
0
mirror of https://github.com/cookiengineer/audacity synced 2026-03-05 22:21:15 +01:00

Use macro safenew for many allocations of wxWindow subclasses

This commit is contained in:
Paul Licameli
2016-02-13 18:06:49 -05:00
parent 6052b5f9be
commit 3f237daddc
42 changed files with 238 additions and 214 deletions

View File

@@ -114,13 +114,13 @@ ErrorDialog::ErrorDialog(
wxBoxSizer *hSizer = new wxBoxSizer(wxHORIZONTAL);
wxStaticText *statText = new wxStaticText(this, -1, message);
wxStaticText *statText = safenew wxStaticText(this, -1, message);
mainSizer->Add(statText, 0, wxALIGN_LEFT|wxALL, 5);
wxButton *help = new wxButton(this, wxID_HELP, _("Help"));
wxButton *help = safenew wxButton(this, wxID_HELP, _("Help"));
hSizer->Add(help, 0, wxALIGN_LEFT|wxALL, 5);
wxButton *ok = new wxButton(this, wxID_OK, _("OK"));
wxButton *ok = safenew wxButton(this, wxID_OK, _("OK"));
ok->SetDefault();
ok->SetFocus();
hSizer->Add(ok, 0, wxALIGN_RIGHT|wxALL, 5);