MCPcopy Create free account
hub / github.com/audacity/audacity / DoAddToHead

Method DoAddToHead

libraries/lib-track/Track.cpp:531–541  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

529}
530
531Track *TrackList::DoAddToHead(const std::shared_ptr<Track> &t)
532{
533 Track *pTrack = t.get();
534 push_front(ListOfTracks::value_type(t));
535 auto n = getBegin();
536 pTrack->SetOwner(shared_from_this(), n);
537 pTrack->SetId( TrackId{ ++sCounter } );
538 RecalcPositions(n);
539 AdditionEvent(n);
540 return front().get();
541}
542
543Track *TrackList::DoAdd(const std::shared_ptr<Track> &t, bool assignIds)
544{

Callers

nothing calls this directly

Calls 4

getBeginFunction · 0.85
SetOwnerMethod · 0.80
SetIdMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected