From 24ed3c5a9e64d2b921bf6df53e7d1ffd69fa9ed5 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Thu, 23 Apr 2020 09:05:18 -0600 Subject: minor code reworking for 46fca9062d28682 (no semantic changes) --- gtk2_ardour/ardour_ui.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'gtk2_ardour') diff --git a/gtk2_ardour/ardour_ui.cc b/gtk2_ardour/ardour_ui.cc index fdc69c263c..da64ea2c14 100644 --- a/gtk2_ardour/ardour_ui.cc +++ b/gtk2_ardour/ardour_ui.cc @@ -1996,8 +1996,12 @@ ARDOUR_UI::transport_ffwd_rewind (int option, int dir) break; } - bool speed_up = (dir > 0 && current_transport_speed >= target_speed); - speed_up = speed_up || (dir < 0 && current_transport_speed <= target_speed); + /* if wanting to move forward/backward and current speed is at or above current + speed (i.e. same direction, and moving), then speed up. + */ + + const bool speed_up = (dir > 0 && current_transport_speed >= target_speed) || (dir < 0 && current_transport_speed <= target_speed); + if (speed_up) { target_speed = current_transport_speed * 1.5f; } -- cgit v1.2.3