1
0
mirror of https://github.com/cookiengineer/audacity synced 2026-03-31 19:44:54 +02:00

Common functions read and write mute and solo in Wave and Note

This commit is contained in:
Paul Licameli
2017-03-30 16:00:27 -04:00
parent 1a86819b4b
commit 7bda40f656
4 changed files with 46 additions and 12 deletions

View File

@@ -758,6 +758,8 @@ bool NoteTrack::HandleXMLTag(const wxChar *tag, const wxChar **attrs)
double dblValue;
if (!wxStrcmp(attr, wxT("name")) && XMLValueChecker::IsGoodString(strValue))
mName = strValue;
else if (this->NoteTrackBase::HandleXMLAttribute(attr, value))
{}
else if (!wxStrcmp(attr, wxT("offset")) &&
XMLValueChecker::IsGoodString(strValue) &&
Internat::CompatibleToDouble(strValue, &dblValue))
@@ -831,10 +833,7 @@ void NoteTrack::WriteXML(XMLWriter &xmlFile) const
saveme->mSeq->write(data, true);
xmlFile.StartTag(wxT("notetrack"));
xmlFile.WriteAttr(wxT("name"), saveme->mName);
#ifdef EXPERIMENTAL_MIDI_OUT
xmlFile.WriteAttr(wxT("mute"), mMute);
xmlFile.WriteAttr(wxT("solo"), mSolo);
#endif
this->NoteTrackBase::WriteXMLAttributes(xmlFile);
xmlFile.WriteAttr(wxT("offset"), saveme->GetOffset());
xmlFile.WriteAttr(wxT("visiblechannels"), saveme->mVisibleChannels);
xmlFile.WriteAttr(wxT("height"), saveme->GetActualHeight());