diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index d259b8ad21..2143c20ba7 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -5868,6 +5868,15 @@ Editor::consider_auditioning (boost::shared_ptr region) last_audition_region = r; } +boost::shared_ptr +Editor::get_dragged_region_from_sidebar () +{ + boost::shared_ptr rv = _regions->get_dragged_region (); + if (!rv) { + rv = _sources->get_dragged_region (); + } + return rv; +} void Editor::hide_a_region (boost::shared_ptr r) diff --git a/gtk2_ardour/editor.h b/gtk2_ardour/editor.h index 442757334a..48027c70dd 100644 --- a/gtk2_ardour/editor.h +++ b/gtk2_ardour/editor.h @@ -226,6 +226,8 @@ public: void hide_a_region (boost::shared_ptr); void show_a_region (boost::shared_ptr); + boost::shared_ptr get_dragged_region_from_sidebar (); + #ifdef USE_RUBBERBAND std::vector rb_opt_strings; int rb_current_opt; diff --git a/gtk2_ardour/public_editor.h b/gtk2_ardour/public_editor.h index f2da2ea4ab..3dc4347e62 100644 --- a/gtk2_ardour/public_editor.h +++ b/gtk2_ardour/public_editor.h @@ -203,6 +203,9 @@ public: */ virtual void consider_auditioning (boost::shared_ptr r) = 0; + /* Editor::_regions DnD */ + virtual boost::shared_ptr get_dragged_region_from_sidebar () = 0; + /* import dialogs -> ardour-ui ?! */ virtual void external_audio_dialog () = 0; virtual void session_import_dialog () = 0;