From 2d7bdda0be0fca64a51c2e26c992a25a517541eb Mon Sep 17 00:00:00 2001 From: nick_m Date: Sat, 20 Aug 2016 01:34:53 +1000 Subject: [PATCH] Extending an empty selection selects the clicked region. - fixes a crash where the first operation on loading a session is a constrained drag --- gtk2_ardour/editor_selection.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gtk2_ardour/editor_selection.cc b/gtk2_ardour/editor_selection.cc index c5ba764af8..f2681b58e2 100644 --- a/gtk2_ardour/editor_selection.cc +++ b/gtk2_ardour/editor_selection.cc @@ -879,7 +879,12 @@ Editor::set_selected_regionview_from_click (bool press, Selection::Operation op) if (!regions.empty()) { selection->add (regions); commit = true; + } else if (selection->regions.empty() && !selection->selected (clicked_regionview)) { + /* ensure that at least the clicked regionview is selected. */ + selection->set (clicked_regionview); + commit = true; } + } out: