1
0
mirror of https://github.com/cookiengineer/audacity synced 2026-03-07 06:55:52 +01:00

ExportPlugins managed with smart pointers

This commit is contained in:
Paul Licameli
2016-03-31 00:46:22 -04:00
parent 1108c1376c
commit 456c8fb01e
18 changed files with 98 additions and 115 deletions

View File

@@ -169,7 +169,6 @@ class ExportMP2 final : public ExportPlugin
public:
ExportMP2();
void Destroy();
// Required
@@ -204,11 +203,6 @@ ExportMP2::ExportMP2()
SetDescription(_("MP2 Files"),0);
}
void ExportMP2::Destroy()
{
delete this;
}
int ExportMP2::Export(AudacityProject *project,
int channels, const wxString &fName,
bool selectionOnly, double t0, double t1, MixerSpec *mixerSpec, const Tags *metadata,
@@ -443,9 +437,9 @@ void ExportMP2::AddFrame(struct id3_tag *tp, const wxString & n, const wxString
}
#endif
ExportPlugin *New_ExportMP2()
movable_ptr<ExportPlugin> New_ExportMP2()
{
return new ExportMP2();
return make_movable<ExportMP2>();
}
#endif // #ifdef USE_LIBTWOLAME