don't copy items when splitting or duplicating blocks

This commit is contained in:
itsmattkc
2021-03-01 13:27:13 +11:00
parent 605a593f90
commit a57bf35e93
6 changed files with 88 additions and 80 deletions
+1 -18
View File
@@ -622,25 +622,8 @@ void PointerTool::FinishDrag(TimelineViewMouseEvent *event)
if (duplicate_clips) {
// Duplicate rather than move
Node* copy;
if (Config::Current()[QStringLiteral("SplitClipsCopyNodes")].toBool()) {
QVector<Node*> nodes_to_clone;
nodes_to_clone.append(block);
nodes_to_clone.append(block->GetDependencies());
QVector<Node*> duplicated = Node::CopyDependencyGraph(nodes_to_clone, command);
copy = duplicated.first();
} else {
copy = block->copy();
command->add_child(new NodeAddCommand(static_cast<NodeGraph*>(block->parent()),
copy));
command->add_child(new NodeCopyInputsCommand(block, copy, true));
}
// Place the copy instead of the original block
block = static_cast<Block*>(copy);
block = static_cast<Block*>(Node::CopyNodeInGraph(block, command));
}
const Track::Reference& track_ref = p.ghost->GetAdjustedTrack();