Work-around/Fix DnD from sidebar to editor-canvas
Editor::drop_regions() creates a new RegionInsertDrag() with the region to drop to the timeline. RegionInsertDrag is-a RegionMotionDrag is-a RegionDrag is-a Drag. However the region does not yet exist on the timeline and RegionView is NULL. This will likely need an API change. e.g. Directly pass the TimeDomain as argument. The information can be provided by the region, or from the TimeAxisView or RouteUI when dropping a new source/region.
This commit is contained in:
parent
056189c76c
commit
fa7e7a462c
@ -601,7 +601,7 @@ struct TimeAxisViewStripableSorter {
|
|||||||
};
|
};
|
||||||
|
|
||||||
RegionDrag::RegionDrag (Editor* e, ArdourCanvas::Item* i, RegionView* p, list<RegionView*> const & v)
|
RegionDrag::RegionDrag (Editor* e, ArdourCanvas::Item* i, RegionView* p, list<RegionView*> const & v)
|
||||||
: Drag (e, i, p->region()->position().time_domain())
|
: Drag (e, i, p && p->region () ? p->region()->position().time_domain() : Temporal::AudioTime)
|
||||||
, _primary (p)
|
, _primary (p)
|
||||||
, _ntracks (0)
|
, _ntracks (0)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user