diff options
author | Colin Fletcher <colin.m.fletcher@googlemail.com> | 2015-06-14 18:09:30 +0100 |
---|---|---|
committer | Colin Fletcher <colin.m.fletcher@googlemail.com> | 2015-06-17 17:15:21 +0100 |
commit | 292f704b3051a29d5f7a6a1b8852296d2aaadfa0 (patch) | |
tree | b24fa1168084919a8f7de5c300a5c465565cdb2d | |
parent | 34e1e00f8bd42ac531537de8c7a7a6dc9b23228c (diff) |
Insert time: don't unlock markers we're not going to move anyway
Move checking for locked markers in Editor::insert_time() so it doesn't
happen if we're going to skip the marker because it's glued to musical
time.
-rw-r--r-- | gtk2_ardour/editor_ops.cc | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc index c46b49505c..c325ab5980 100644 --- a/gtk2_ardour/editor_ops.cc +++ b/gtk2_ardour/editor_ops.cc @@ -7030,12 +7030,11 @@ Editor::insert_time ( Locations::LocationList::const_iterator tmp; - bool const was_locked = (*i)->locked (); - if (locked_markers_too) { - (*i)->unlock (); - } - if ((*i)->position_lock_style() == AudioTime || glued_markers_too) { + bool const was_locked = (*i)->locked (); + if (locked_markers_too) { + (*i)->unlock (); + } if ((*i)->start() >= pos) { // move end first, in case we're moving by more than the length of the range @@ -7046,10 +7045,9 @@ Editor::insert_time ( moved = true; } - } - - if (was_locked) { - (*i)->lock (); + if (was_locked) { + (*i)->lock (); + } } } |