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

Function DoSelectSomething

src/SelectUtilities.cpp:152–162  ·  view source on GitHub ↗

This function selects all tracks if no tracks selected, and all time if no time selected. There is an argument for making it just count wave tracks, However you could then not select a label and cut it, without this function selecting all tracks.

Source from the content-addressed store, hash-verified

150// However you could then not select a label and cut it,
151// without this function selecting all tracks.
152void DoSelectSomething(AudacityProject &project)
153{
154 auto &tracks = TrackList::Get( project );
155 auto &selectedRegion = ViewInfo::Get( project ).selectedRegion;
156
157 bool bTime = selectedRegion.isPoint();
158 bool bTracks = tracks.Selected().empty();
159
160 if (bTime || bTracks)
161 DoSelectTimeAndTracks(project, bTime, bTracks);
162}
163
164void ActivatePlayRegion(AudacityProject &project)
165{

Callers

nothing calls this directly

Calls 3

GetFunction · 0.85
DoSelectTimeAndTracksFunction · 0.85
emptyMethod · 0.45

Tested by

no test coverage detected