34 void SetMute(
bool value);
36 void SetSolo(
bool value);
40 std::atomic<bool> mMute{
false };
42 std::atomic<bool> mSolo{
false };
49MuteAndSolo::MuteAndSolo(
const MuteAndSolo &other) {
50 SetMute(other.GetMute());
51 SetSolo(other.GetSolo());
54MuteAndSolo::~MuteAndSolo() =
default;
57 return std::make_unique<MuteAndSolo>(*
this);
69bool MuteAndSolo::GetMute()
const
71 return mMute.load(std::memory_order_relaxed);
74void MuteAndSolo::SetMute(
bool value)
76 mMute.store(value, std::memory_order_relaxed);
79bool MuteAndSolo::GetSolo()
const
81 return mSolo.load(std::memory_order_relaxed);
84void MuteAndSolo::SetSolo(
bool value)
86 mSolo.store(value, std::memory_order_relaxed);
159 if (attr ==
"mute" && value.
TryGet(nValue)) {
163 else if (attr ==
"solo" && value.
TryGet(nValue)) {
174 {
"audio",
"audio",
XO(
"Audio Track") },
182 {
"playable",
"playable",
XO(
"Playable Track") },
191 {
XO(
"Multi-track"),
XO(
"Simple")},
192 {
wxT(
"Multi"),
wxT(
"Simple")}
EnumSetting< SoloBehavior > TracksBehaviorsSolo
Extends Track with notions of mute and solo setting.
Track subclass holding data representing sound (as notes, or samples, or ...)
bool HandleXMLAttribute(const std::string_view &, const XMLAttributeValueView &)
static const TypeInfo & ClassTypeInfo()
void WriteXMLAttributes(XMLWriter &WXUNUSED(xmlFile)) const
Client code makes static instance from a factory of attachments; passes it to Get or Find as a retrie...
Adapts EnumSettingBase to a particular enumeration type.
AudioTrack subclass that can also be audibly replayed by the program.
bool HandleXMLAttribute(const std::string_view &attr, const XMLAttributeValueView &value)
void DoSetSolo(bool value)
void DoSetMute(bool value)
static const TypeInfo & ClassTypeInfo()
void WriteXMLAttributes(XMLWriter &xmlFile) const
Abstract base class for an object holding data associated with points on a time axis.
void Notify(bool allChannels, int code=-1)
static const TypeInfo & ClassTypeInfo()
A view into an attribute value. The class does not take the ownership of the data.
bool TryGet(bool &value) const noexcept
Try to get a boolean value from the view.
Base class for XMLFileWriter and XMLStringWriter that provides the general functionality for creating...
void WriteAttr(const wxString &name, const Identifier &value)
Services * Get()
Fetch the global instance, or nullptr if none is yet installed.
template struct REGISTRIES_API Cloneable<>
static const ChannelGroup::Attachments::RegisteredFactory muteAndSoloFactory
A convenient base class defining abstract virtual Clone() for a given kind of pointer.
Empty argument passed to some public constructors.
MuteAndSolo & operator=(const MuteAndSolo &)=delete
MuteAndSolo(const MuteAndSolo &)