Commit cbf2af35 authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Another fix for mix resize corruption

parent 46440d9e
......@@ -6007,7 +6007,14 @@ void TimelineModel::requestResizeMix(int cid, int duration, MixAlignment align,
}
int maxLengthRight = m_allClips.at(cid)->getMaxDuration();
// maximum space to resize clip on the left
int availableRight = m_allClips.at(cid)->getPosition() - m_allClips.at(clipToResize)->getPosition();
int rightMax = maxLengthRight > -1 ? (m_allClips.at(cid)->getIn()) : -1;
if (rightMax == -1) {
rightMax = availableRight;
} else {
rightMax = qMin(rightMax, availableRight);
}
Fun adjust_mix_undo = [this, tid, cid, prevCut = m_allClips.at(cid)->getMixCutPosition(), prevDuration = m_allClips.at(cid)->getMixDuration()]() {
getTrackById_const(tid)->setMixDuration(cid, prevDuration, prevCut);
QModelIndex ix = makeClipIndexFromID(cid);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment