mirror of
https://github.com/cookiengineer/audacity
synced 2025-12-24 09:31:13 +01:00
Sweep unnecessary wxString copies: blockfile
This commit is contained in:
@@ -81,7 +81,7 @@ void LegacyAliasBlockFile::SaveXML(XMLWriter &xmlFile)
|
|||||||
// BuildFromXML methods should always return a BlockFile, not NULL,
|
// BuildFromXML methods should always return a BlockFile, not NULL,
|
||||||
// even if the result is flawed (e.g., refers to nonexistent file),
|
// even if the result is flawed (e.g., refers to nonexistent file),
|
||||||
// as testing will be done in DirManager::ProjectFSCK().
|
// as testing will be done in DirManager::ProjectFSCK().
|
||||||
BlockFile *LegacyAliasBlockFile::BuildFromXML(wxString projDir, const wxChar **attrs)
|
BlockFile *LegacyAliasBlockFile::BuildFromXML(const wxString &projDir, const wxChar **attrs)
|
||||||
{
|
{
|
||||||
wxFileName summaryFileName;
|
wxFileName summaryFileName;
|
||||||
wxFileName aliasFileName;
|
wxFileName aliasFileName;
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ class LegacyAliasBlockFile : public PCMAliasBlockFile
|
|||||||
virtual BlockFile *Copy(wxFileName fileName);
|
virtual BlockFile *Copy(wxFileName fileName);
|
||||||
virtual void Recover();
|
virtual void Recover();
|
||||||
|
|
||||||
static BlockFile *BuildFromXML(wxString projDir, const wxChar **attrs);
|
static BlockFile *BuildFromXML(const wxString &projDir, const wxChar **attrs);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -284,7 +284,7 @@ void LegacyBlockFile::SaveXML(XMLWriter &xmlFile)
|
|||||||
// even if the result is flawed (e.g., refers to nonexistent file),
|
// even if the result is flawed (e.g., refers to nonexistent file),
|
||||||
// as testing will be done in DirManager::ProjectFSCK().
|
// as testing will be done in DirManager::ProjectFSCK().
|
||||||
/// static
|
/// static
|
||||||
BlockFile *LegacyBlockFile::BuildFromXML(wxString projDir, const wxChar **attrs,
|
BlockFile *LegacyBlockFile::BuildFromXML(const wxString &projDir, const wxChar **attrs,
|
||||||
sampleCount len, sampleFormat format)
|
sampleCount len, sampleFormat format)
|
||||||
{
|
{
|
||||||
wxFileName fileName;
|
wxFileName fileName;
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ class LegacyBlockFile : public BlockFile {
|
|||||||
virtual wxLongLong GetSpaceUsage();
|
virtual wxLongLong GetSpaceUsage();
|
||||||
virtual void Recover();
|
virtual void Recover();
|
||||||
|
|
||||||
static BlockFile *BuildFromXML(wxString dir, const wxChar **attrs,
|
static BlockFile *BuildFromXML(const wxString &dir, const wxChar **attrs,
|
||||||
sampleCount len,
|
sampleCount len,
|
||||||
sampleFormat format);
|
sampleFormat format);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user