diff --git a/gtk2_ardour/cue_editor.cc b/gtk2_ardour/cue_editor.cc index d41b568c65..17bedca994 100644 --- a/gtk2_ardour/cue_editor.cc +++ b/gtk2_ardour/cue_editor.cc @@ -1082,6 +1082,7 @@ CueEditor::mouse_mode_chosen (Editing::MouseMode m) * left. we'll get called again with the new mode active in a * jiffy. */ + old_mouse_mode = m; return; } diff --git a/gtk2_ardour/editing_context.cc b/gtk2_ardour/editing_context.cc index 2907e11537..e7f1f42d29 100644 --- a/gtk2_ardour/editing_context.cc +++ b/gtk2_ardour/editing_context.cc @@ -111,6 +111,7 @@ static const gchar *_zoom_focus_strings[] = { EditingContext::EditingContext (std::string const & name) : rubberband_rect (0) + , old_mouse_mode (Editing::MouseObject) , _name (name) , within_track_canvas (false) , pre_internal_grid_type (GridTypeBeat) diff --git a/gtk2_ardour/editing_context.h b/gtk2_ardour/editing_context.h index fc64ed2813..efe330ecf9 100644 --- a/gtk2_ardour/editing_context.h +++ b/gtk2_ardour/editing_context.h @@ -432,6 +432,7 @@ class EditingContext : public ARDOUR::SessionHandlePtr, public AxisViewProvider, virtual ArdourCanvas::GtkCanvas* get_canvas() const = 0; virtual void mouse_mode_chosen (Editing::MouseMode) = 0; + Editing::MouseMode old_mouse_mode; bool on_velocity_scroll_event (GdkEventScroll*); void pre_render (); diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc index 7c2304a4f1..20f18edf99 100644 --- a/gtk2_ardour/editor_mouse.cc +++ b/gtk2_ardour/editor_mouse.cc @@ -132,10 +132,11 @@ Editor::mouse_mode_chosen (MouseMode m) * left. we'll get called again with the new mode active in a * jiffy. */ + old_mouse_mode = m; return; } - const bool was_internal = internal_editing(); + const bool was_internal = (old_mouse_mode == Editing::MouseDraw || old_mouse_mode == Editing::MouseContent); /* Ben ToDo: once we have a dedicated 'region edit panel', we can store * one snap mode in the editor canvas and another one in the editor,