Audacity 3.2.0
WaveTrackUtils.cpp
Go to the documentation of this file.
1/*!********************************************************************
2*
3 Audacity: A Digital Audio Editor
4
5 @file WaveTrackUtils.cpp
6
7 Vitaly Sverchinsky
8
9 **********************************************************************/
10
11#include "WaveTrackUtils.h"
12#include "ViewInfo.h"
13#include "../../../WaveClip.h"
14
15
16bool WaveTrackUtils::IsClipSelected(const ViewInfo& viewInfo, const WaveClip& clip)
17{
18 return clip.GetPlayStartTime() == viewInfo.selectedRegion.t0() &&
19 clip.GetPlayEndTime() == viewInfo.selectedRegion.t1();
20}
Contains some useful wave track external routines grouped into a single namespace.
double t1() const
Definition: ViewInfo.h:35
double t0() const
Definition: ViewInfo.h:34
NotifyingSelectedRegion selectedRegion
Definition: ViewInfo.h:217
This allows multiple clips to be a part of one WaveTrack.
Definition: WaveClip.h:101
double GetPlayStartTime() const noexcept
Definition: WaveClip.cpp:866
double GetPlayEndTime() const
Definition: WaveClip.cpp:876
bool IsClipSelected(const ViewInfo &viewInfo, const WaveClip &waveClip)