13
0

fix deadlock during tempo marker dragging, and don't start a tempo map update if a tempo point is inactive

This commit is contained in:
Paul Davis 2021-03-22 16:01:57 -06:00
parent ce3fb0507c
commit 88bed837c0

View File

@ -3562,11 +3562,11 @@ TempoMarkerDrag::start_grab (GdkEvent* event, Gdk::Cursor* cursor)
show_verbose_cursor_text (_("inactive"));
} else {
show_verbose_cursor_time (adjusted_current_time (event));
/* setup thread-local tempo map ptr as a writable copy */
TempoMap::fetch_writable ();
}
/* setup thread-local tempo map ptr as a writable copy */
TempoMap::fetch_writable ();
}
void
@ -3686,22 +3686,21 @@ TempoMarkerDrag::motion (GdkEvent* event, bool first_move)
void
TempoMarkerDrag::finished (GdkEvent* event, bool movement_occurred)
{
// _point->end_float ();
if (!_marker->tempo().active()) {
return;
}
if (!movement_occurred) {
if (was_double_click()) {
_editor->edit_tempo_marker (*_marker);
}
/* reset the per-thread tempo map ptr back to the current
* official version
*/
TempoMap::abort_update ();
if (was_double_click()) {
_editor->edit_tempo_marker (*_marker);
}
return;
}