![]() |
Audacity 3.2.0
|
Holds multiple objects as a single attachment to Track. More...
#include <Track.h>
Public Types | |
using | Factory = std::function< std::shared_ptr< TrackAttachment >(Track &, size_t)> |
Public Member Functions | |
ChannelAttachmentsBase (Track &track, Factory factory) | |
~ChannelAttachmentsBase () override | |
void | CopyTo (Track &track) const override |
Copy state, for undo/redo purposes. More... | |
void | Reparent (const std::shared_ptr< Track > &parent) override |
Object may be shared among tracks but hold a special back-pointer to one of them; reassign it. More... | |
void | WriteXMLAttributes (XMLWriter &writer) const override |
Serialize persistent attributes. More... | |
bool | HandleXMLAttribute (const std::string_view &attr, const XMLAttributeValueView &valueView) override |
Deserialize an attribute, returning true if recognized. More... | |
![]() | |
virtual | ~TrackAttachment () |
virtual void | CopyTo (Track &track) const |
Copy state, for undo/redo purposes. More... | |
virtual void | Reparent (const std::shared_ptr< Track > &parent) |
Object may be shared among tracks but hold a special back-pointer to one of them; reassign it. More... | |
virtual void | WriteXMLAttributes (XMLWriter &) const |
Serialize persistent attributes. More... | |
virtual bool | HandleXMLAttribute (const std::string_view &attr, const XMLAttributeValueView &valueView) |
Deserialize an attribute, returning true if recognized. More... | |
![]() | |
virtual | ~Base () |
Static Protected Member Functions | |
static TrackAttachment & | Get (const AttachedTrackObjects::RegisteredFactory &key, Track &track, size_t iChannel) |
static TrackAttachment * | Find (const AttachedTrackObjects::RegisteredFactory &key, Track *pTrack, size_t iChannel) |
Private Attributes | |
const Factory | mFactory |
std::vector< std::shared_ptr< TrackAttachment > > | mAttachments |
using ChannelAttachmentsBase::Factory = std::function<std::shared_ptr<TrackAttachment>(Track &, size_t)> |
Definition at line 1320 of file Track.cpp.
References mAttachments, and mFactory.
|
overridedefault |
|
overridevirtual |
Copy state, for undo/redo purposes.
Reimplemented from TrackAttachment.
Definition at line 1331 of file Track.cpp.
References mAttachments.
|
staticprotected |
!pTrack || iChannel < pTrack->NChannels()
Definition at line 1305 of file Track.cpp.
References anonymous_namespace{StretchingSequenceIntegrationTest.cpp}::iChannel, key, and mAttachments.
Referenced by ChannelAttachments< Attachment >::Find().
|
staticprotected |
iChannel < track.NChannels()
Definition at line 1286 of file Track.cpp.
References anonymous_namespace{StretchingSequenceIntegrationTest.cpp}::iChannel, key, mAttachments, mFactory, and ChannelGroup::NChannels().
Referenced by ChannelAttachments< Attachment >::Get().
|
overridevirtual |
Deserialize an attribute, returning true if recognized.
default recognizes no attributes, and returns false
Reimplemented from TrackAttachment.
Definition at line 1352 of file Track.cpp.
References mAttachments.
|
overridevirtual |
Object may be shared among tracks but hold a special back-pointer to one of them; reassign it.
default does nothing
Reimplemented from TrackAttachment.
Definition at line 1338 of file Track.cpp.
References mAttachments.
|
overridevirtual |
Serialize persistent attributes.
default does nothing
Reimplemented from TrackAttachment.
Definition at line 1345 of file Track.cpp.
References mAttachments.
|
private |
Definition at line 544 of file Track.h.
Referenced by ChannelAttachmentsBase(), CopyTo(), Find(), Get(), HandleXMLAttribute(), Reparent(), and WriteXMLAttributes().
|
private |
Definition at line 543 of file Track.h.
Referenced by ChannelAttachmentsBase(), and Get().