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

Function HasVisibleSpectralView

src/SpectralDataDialog.cpp:411–421  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

409}
410
411static bool HasVisibleSpectralView(WaveTrack *wt)
412{
413 auto &view = ChannelView::Get(*wt->GetChannel(0));
414 if (auto waveChannelViewPtr = dynamic_cast<WaveChannelView*>(&view)) {
415 const auto range = waveChannelViewPtr->GetSubViews();
416 return std::any_of( range.begin(), range.end(),
417 [](const auto &pair){
418 return dynamic_cast<SpectrumView*>(pair.second.get()); } );
419 }
420 return false;
421}
422
423static unsigned CountVisibleSpectralViews( AudacityProject &project )
424{

Callers

nothing calls this directly

Calls 6

GetFunction · 0.85
GetChannelMethod · 0.80
GetSubViewsMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected