diff options
Diffstat (limited to 'gtk2_ardour/editor_mouse.cc')
-rw-r--r-- | gtk2_ardour/editor_mouse.cc | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc index df93f7ae16..f52f05274a 100644 --- a/gtk2_ardour/editor_mouse.cc +++ b/gtk2_ardour/editor_mouse.cc @@ -825,9 +825,7 @@ Editor::button_press_handler_1 (ArdourCanvas::Item* item, GdkEvent* event, ItemT ArdourCanvas::CanvasNote* cn = dynamic_cast<ArdourCanvas::CanvasNote*> (item); if (cn && cn->big_enough_to_trim() && cn->mouse_near_ends()) { _drags->set (new NoteResizeDrag (this, item), event, current_canvas_cursor); - } else { - _drags->set (new NoteDrag (this, item), event); - } + } } return true; @@ -868,6 +866,25 @@ Editor::button_press_handler_1 (ArdourCanvas::Item* item, GdkEvent* event, ItemT return true; break; + case MouseDraw: + switch (item_type) { + case NoteItem: + if (internal_editing()) { + /* trim notes if we're in internal edit mode and near the ends of the note */ + ArdourCanvas::CanvasNote* cn = dynamic_cast<ArdourCanvas::CanvasNote*> (item); + if (cn && cn->big_enough_to_trim() && cn->mouse_near_ends()) { + _drags->set (new NoteResizeDrag (this, item), event, current_canvas_cursor); + } else { + _drags->set (new NoteDrag (this, item), event); + } + return true; + } + break; + + default: + break; + } + case MouseObject: switch (item_type) { case NoteItem: |