From ce4d125d1fd91bb3cdf82319dcce53abb35afcca Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Fri, 21 Feb 2014 15:30:33 -0500 Subject: reverse default behaviour for adding control points to automation with mouse clicks. unmodified click adds new control point without guard points; ctrl-click adds new point with a guard point (old behaviour) --- gtk2_ardour/automation_region_view.cc | 4 ++-- gtk2_ardour/editor_mouse.cc | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/gtk2_ardour/automation_region_view.cc b/gtk2_ardour/automation_region_view.cc index 2e22556f27..409890e7b2 100644 --- a/gtk2_ardour/automation_region_view.cc +++ b/gtk2_ardour/automation_region_view.cc @@ -122,9 +122,9 @@ AutomationRegionView::canvas_event (GdkEvent* ev) y = std::max (y, 0.0); y = std::min (y, _height - NAME_HIGHLIGHT_SIZE); - /* no guard points if primary modifier is used */ + /* guard points only if primary modifier is used */ - bool with_guard_points = !Gtkmm2ext::Keyboard::modifier_state_equals (ev->button.state, Gtkmm2ext::Keyboard::PrimaryModifier); + bool with_guard_points = Gtkmm2ext::Keyboard::modifier_state_equals (ev->button.state, Gtkmm2ext::Keyboard::PrimaryModifier); add_automation_event (ev, trackview.editor().pixel_to_frame (x) - _region->position() + _region->start(), y, with_guard_points); } diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc index 8c515636fb..e20bd86384 100644 --- a/gtk2_ardour/editor_mouse.cc +++ b/gtk2_ardour/editor_mouse.cc @@ -1682,7 +1682,7 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT case AutomationTrackItem: atv = dynamic_cast(clicked_axisview); if (atv) { - bool with_guard_points = !Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier); + bool with_guard_points = Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier); atv->add_automation_event (event, where, event->button.y, with_guard_points); } return true; @@ -1702,7 +1702,7 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT */ AudioRegionView* arv = dynamic_cast (clicked_regionview); if (!were_dragging && arv) { - bool with_guard_points = !Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier); + bool with_guard_points = Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier); arv->add_gain_point_event (item, event, with_guard_points); } return true; @@ -1710,7 +1710,7 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT } case AutomationTrackItem: { - bool with_guard_points = !Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier); + bool with_guard_points = Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier); dynamic_cast(clicked_axisview)-> add_automation_event (event, where, event->button.y, with_guard_points); return true; -- cgit v1.2.3