fixes #4049: Off-grid nodes not draggable (#6852)

The quantPos arg of AutomationClip::setDragValue causes the node time
to be quantized before its looked up in the timeMap iterator.
This results in the node not being found and a new one being created
inside the setDragValue function even though we had found one.
Simply setting it to true causes this bug, simply setting it to false
causes a new node to be created off grid/not snapped. So the fix
is to quantize the position for the lookup only if we haven't found an
existing node under the cursor.
This commit is contained in:
consolegrl
2023-09-07 22:19:56 -04:00
committed by GitHub
parent b7196337a4
commit 10f1b21fb7

View File

@@ -531,7 +531,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent )
: POS(clickedNode)
),
level,
true,
clickedNode == tm.end(),
mouseEvent->modifiers() & Qt::ControlModifier
);