13
0

reinstate (de)selection operations that should happen on mouse button release

git-svn-id: svn://localhost/ardour2/branches/3.0@9104 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Paul Davis 2011-03-08 12:45:23 +00:00
parent d2bcfc0747
commit 07e607ebad
2 changed files with 7 additions and 6 deletions

View File

@ -505,8 +505,6 @@ Editor::button_selection (ArdourCanvas::Item* /*item*/, GdkEvent* event, ItemTyp
Selection::Operation op = ArdourKeyboard::selection_type (event->button.state);
bool press = (event->type == GDK_BUTTON_PRESS);
// begin_reversible_command (_("select on click"));
switch (item_type) {
case RegionItem:
if (mouse_mode != MouseRange || _join_object_range_state == JOIN_OBJECT_RANGE_OBJECT) {
@ -1501,9 +1499,11 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
default:
break;
}
/* do any (de)selection operations that should occur on button release */
button_selection (item, event, item_type);
return true;
break;
@ -1548,6 +1548,9 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
default:
break;
}
cerr << "button release hits bottom\n";
return false;
}

View File

@ -522,7 +522,6 @@ Editor::set_selected_regionview_from_click (bool press, Selection::Operation op,
switch (op) {
case Selection::Toggle:
if (selection->selected (clicked_regionview)) {
if (press) {
@ -533,11 +532,10 @@ Editor::set_selected_regionview_from_click (bool press, Selection::Operation op,
button_release_can_deselect = true;
} else {
if (button_release_can_deselect) {
/* just remove this one region, but only on a permitted button release */
selection->remove (clicked_regionview);
commit = true;