diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2017-01-10 09:53:10 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2017-01-10 09:53:28 +0000 |
commit | 1587364f8daaafa5d1a83ce88aa9a5ef5424f30e (patch) | |
tree | f859a0266faf7214e46bfdaf83179ed18a03ad6c /gtk2_ardour/editor_mouse.cc | |
parent | 82bea45b2b85e4c8075ba495af7da0a7d8b0ea74 (diff) |
avoid locate when clicking in region fade handles in smart mode+follow edits
Diffstat (limited to 'gtk2_ardour/editor_mouse.cc')
-rw-r--r-- | gtk2_ardour/editor_mouse.cc | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc index e34c38c43c..8e1ef327ab 100644 --- a/gtk2_ardour/editor_mouse.cc +++ b/gtk2_ardour/editor_mouse.cc @@ -1255,8 +1255,20 @@ Editor::button_press_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemTyp return true; } - //not rolling, range mode click + join_play_range : locate the PH here - if ( !_drags->active () && _session && !_session->transport_rolling() && ( effective_mouse_mode() == MouseRange ) && UIConfiguration::instance().get_follow_edits() && !_session->config.get_external_sync() ) { + /* not rolling, effectively in range mode, follow edits enabled (likely + * to start range drag), not in a fade handle (since that means we are + * not starting a range drag): locate the PH here + */ + + if ((item_type != FadeInHandleItem) && + (item_type != FadeOutHandleItem) && + !_drags->active () && + _session && + !_session->transport_rolling() && + (effective_mouse_mode() == MouseRange) && + UIConfiguration::instance().get_follow_edits() && + !_session->config.get_external_sync()) { + framepos_t where = canvas_event_sample (event); snap_to(where); _session->request_locate (where, false); |