1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-08-16 08:34:10 +02:00

Keyboard commands for moving clips: minor fix

Problem: the commands did not take into account that for a stereo track, the clip boundaries in the two channels can be different.

Fixed.
This commit is contained in:
David Bailes 2017-07-13 16:31:06 +01:00
parent f24a704a5b
commit 5f49892d61

View File

@ -3390,6 +3390,12 @@ double AudacityProject::OnClipMove
auto t0 = viewInfo.selectedRegion.t0();
state.capturedClip = wt->GetClipAtTime( t0 );
if (state.capturedClip == nullptr && track->GetLinked() && track->GetLink()) {
// the clips in the right channel may be different from the left
track = track->GetLink();
wt = static_cast<WaveTrack*>(track);
state.capturedClip = wt->GetClipAtTime(t0);
}
if (state.capturedClip == nullptr)
return 0.0;