summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_canvas.cc
diff options
context:
space:
mode:
authorBen Loftis <ben@harrisonconsoles.com>2018-11-15 09:30:22 -0600
committerBen Loftis <ben@harrisonconsoles.com>2019-08-01 12:11:31 -0500
commitb409c58ee67f2779a0ee8ef66f9ead093a911058 (patch)
treed9a89bb620b021ab5b418ab4d39f85cd5cc619f9 /gtk2_ardour/editor_canvas.cc
parentbe7ebbb7ba1dae3ef688f34c9c03ad6372509922 (diff)
(Source List) Fix drag-n-drop.
Diffstat (limited to 'gtk2_ardour/editor_canvas.cc')
-rw-r--r--gtk2_ardour/editor_canvas.cc12
1 files changed, 10 insertions, 2 deletions
diff --git a/gtk2_ardour/editor_canvas.cc b/gtk2_ardour/editor_canvas.cc
index f10ee20890..d45ab9a7ff 100644
--- a/gtk2_ardour/editor_canvas.cc
+++ b/gtk2_ardour/editor_canvas.cc
@@ -249,9 +249,15 @@ Editor::initialize_canvas ()
vector<TargetEntry> target_table;
+<<<<<<< HEAD
// Drag-N-Drop from the region list can generate this target
target_table.push_back (TargetEntry ("regions"));
+=======
+ target_table.push_back (TargetEntry ("regions")); // DnD from the region list will generate this target
+ target_table.push_back (TargetEntry ("sources")); // DnD from the source list will generate this target
+ target_table.push_back (TargetEntry ("text/plain"));
+>>>>>>> Source list: Fix drag-n-drop.
target_table.push_back (TargetEntry ("text/uri-list"));
target_table.push_back (TargetEntry ("text/plain"));
target_table.push_back (TargetEntry ("application/x-rootwin-drop"));
@@ -376,8 +382,10 @@ Editor::track_canvas_drag_data_received (const RefPtr<Gdk::DragContext>& context
if (!ARDOUR_UI_UTILS::engine_is_running ()) {
return;
}
- if (data.get_target() == "regions") {
- drop_regions (context, x, y, data, info, time);
+ if (data.get_target() == X_("regions")) {
+ drop_regions (context, x, y, data, info, time, true);
+ } else if (data.get_target() == X_("sources")) {
+ drop_regions (context, x, y, data, info, time, false);
} else {
drop_paths (context, x, y, data, info, time);
}