mirror of
https://github.com/cookiengineer/audacity
synced 2025-11-23 17:30:17 +01:00
Keyboard scrubbing: faster change of direction
If one of the keyboard scrubbing keys is being held down, and the other keyboard scrubbing key is pressed: 1. With current behaviour, scrubbing in the other direction only starts when the original key is released - scrubbing stops and then starts in the other direction. 2. With the new behaviour, scrubbing immediately changes direction, and does not stop when the original key is released - scrubbing does not stop and then start again. New behaviour: If one of the keyboard scrubbing keys is being held down,
This commit is contained in:
@@ -2827,14 +2827,13 @@ void AudioIO::FillBuffers()
|
||||
if (!mSilentScrub)
|
||||
{
|
||||
for (i = 0; i < mPlaybackTracks.size(); i++) {
|
||||
if (mPlaybackSchedule.mPlayMode == PlaybackSchedule::PLAY_AT_SPEED ||
|
||||
mPlaybackSchedule.mPlayMode == PlaybackSchedule::PLAY_KEYBOARD_SCRUB) {
|
||||
mPlaybackMixers[i]->SetSpeed(mScrubSpeed);
|
||||
}
|
||||
else {
|
||||
if (mPlaybackSchedule.mPlayMode == PlaybackSchedule::PLAY_AT_SPEED)
|
||||
mPlaybackMixers[i]->SetSpeedForPlayAtSpeed(mScrubSpeed);
|
||||
else if (mPlaybackSchedule.mPlayMode == PlaybackSchedule::PLAY_KEYBOARD_SCRUB)
|
||||
mPlaybackMixers[i]->SetSpeedForKeyboardScrubbing(mScrubSpeed, startTime);
|
||||
else
|
||||
mPlaybackMixers[i]->SetTimesAndSpeed(
|
||||
startTime, endTime, fabs( mScrubSpeed ));
|
||||
}
|
||||
}
|
||||
}
|
||||
mTimeQueue.mLastTime = startTime;
|
||||
|
||||
Reference in New Issue
Block a user