summaryrefslogtreecommitdiff
path: root/libs/ardour/session_transport.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2015-05-12 23:17:14 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2015-06-29 14:18:13 -0400
commit016beaab9bf24740d796bdc43af152d1e3186d02 (patch)
tree5526e2b6d6ffd6d3c3adc96a3e81a1df2e444bbb /libs/ardour/session_transport.cc
parent30a698f42e3ee6be5a63ea1143413cf8329f444e (diff)
give different Tracks + Ardour/Mixbus playhead priority functionality, and add missing set_track_loop() call for playhead priority
Diffstat (limited to 'libs/ardour/session_transport.cc')
-rw-r--r--libs/ardour/session_transport.cc41
1 files changed, 41 insertions, 0 deletions
diff --git a/libs/ardour/session_transport.cc b/libs/ardour/session_transport.cc
index 994a4b89a1..f17e3b9c8a 100644
--- a/libs/ardour/session_transport.cc
+++ b/libs/ardour/session_transport.cc
@@ -505,17 +505,47 @@ Session::select_playhead_priority_target (framepos_t& jump_to)
return false;
}
+ if (Profile->get_trx() && transport_rolling() ) {
+ // We're playing, so do nothing.
+ // Next stop will put us where we need to be.
+ return false;
+ }
+
/* Note that the order of checking each AutoReturnTarget flag defines
the priority each flag.
+
+ Ardour/Mixbus: Last Locate
+ Range Selection
+ Loop Range
+ Region Selection
+
+ Tracks: Range Selection
+ Loop Range
+ Region Selection
+ Last Locate
*/
+#ifndef USE_TRACKS_CODE_FEATURES
if (autoreturn & LastLocate) {
jump_to = _last_roll_location;
}
if (jump_to < 0 && (autoreturn & RangeSelectionStart)) {
+#else
+ if (autoreturn & RangeSelectionStart) {
+#endif
if (!_range_selection.empty()) {
jump_to = _range_selection.from;
+ } else {
+ if (Profile->get_trx()) {
+ if (transport_rolling ()) {
+ /* Range selection no longer exists, but we're playing,
+ so do nothing. Next stop will put us where
+ we need to be.
+ */
+ return false;
+ }
+ }
}
}
@@ -527,6 +557,11 @@ Session::select_playhead_priority_target (framepos_t& jump_to)
if (location) {
jump_to = location->start();
+
+ if (Config->get_seamless_loop()) {
+ /* need to get track buffers reloaded */
+ set_track_loop (true);
+ }
}
}
}
@@ -537,6 +572,12 @@ Session::select_playhead_priority_target (framepos_t& jump_to)
}
}
+#ifdef USE_TRACKS_CODE_FEATURES
+ if (jump_to < 0 && (autoreturn & LastLocate)) {
+ jump_to = _last_roll_location;
+ }
+#endif
+
return jump_to >= 0;
}