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

Fix crash on multiple items deletion

parent 8421430b
......@@ -2508,9 +2508,6 @@ bool TimelineModel::requestGroupDeletion(int clipId, Fun &undo, Fun &redo)
while (!group_queue.empty()) {
int current_group = group_queue.front();
bool isSelection = m_currentSelection == current_group;
if (isSelection) {
requestClearSelection(true);
}
group_queue.pop();
Q_ASSERT(isGroup(current_group));
auto children = m_groups->getDirectChildren(current_group);
......@@ -2546,6 +2543,9 @@ bool TimelineModel::requestGroupDeletion(int clipId, Fun &undo, Fun &redo)
}
}
}
if (isSelection) {
requestClearSelection(true);
}
}
for (int clip : all_items) {
bool res = requestClipDeletion(clip, undo, redo);
......
Markdown is supported
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