diff options
author | Ben Loftis <ben@harrisonconsoles.com> | 2015-06-01 13:12:39 -0500 |
---|---|---|
committer | Ben Loftis <ben@harrisonconsoles.com> | 2015-06-01 13:12:39 -0500 |
commit | cc396baf0d47079d37ffc84a483475f80c4792fc (patch) | |
tree | 387593b5c1c3776ee12c4d4699ab93671c9aaee7 /gtk2_ardour/audio_region_view.cc | |
parent | ce69096faecd999c60f51b35e1ea9a4abc1d818c (diff) |
Fix some visual loopholes when switching tools inside a region:
switching to Grab should show the fade handles...
...switching away from grab should hide them.
Also, change "always show gain" preference to show lines, but not control points.
Diffstat (limited to 'gtk2_ardour/audio_region_view.cc')
-rw-r--r-- | gtk2_ardour/audio_region_view.cc | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/gtk2_ardour/audio_region_view.cc b/gtk2_ardour/audio_region_view.cc index 6934bdb2ad..2ea91ff62f 100644 --- a/gtk2_ardour/audio_region_view.cc +++ b/gtk2_ardour/audio_region_view.cc @@ -1049,10 +1049,10 @@ AudioRegionView::update_envelope_visibility () return; } - if (ARDOUR_UI::config()->get_show_region_gain() || trackview.editor().current_mouse_mode() == Editing::MouseDraw || trackview.editor().current_mouse_mode() == Editing::MouseContent ) { + if (trackview.editor().current_mouse_mode() == Editing::MouseDraw || trackview.editor().current_mouse_mode() == Editing::MouseContent ) { gain_line->set_visibility (AutomationLine::VisibleAspects(AutomationLine::ControlPoints|AutomationLine::Line)); gain_line->canvas_group().raise_to_top (); - } else if (trackview.editor().current_mouse_mode() == Editing::MouseRange ) { + } else if (ARDOUR_UI::config()->get_show_region_gain() || trackview.editor().current_mouse_mode() == Editing::MouseRange ) { gain_line->set_visibility (AutomationLine::VisibleAspects(AutomationLine::Line)); gain_line->canvas_group().raise_to_top (); } else { @@ -1342,6 +1342,13 @@ AudioRegionView::entered () fade_out_trim_handle->hide (); } } + } else { //this happens when we switch tools; if we switch away from Grab mode, hide all the fade handles + if (fade_in_handle) { fade_in_handle->hide(); } + if (fade_out_handle) { fade_out_handle->hide(); } + if (fade_in_trim_handle) { fade_in_trim_handle->hide(); } + if (fade_out_trim_handle) { fade_out_trim_handle->hide(); } + if (start_xfade_rect) { start_xfade_rect->set_outline (false); } + if (end_xfade_rect) { end_xfade_rect->set_outline (false); } } } |