Commit 23b84ae3 authored by Tomaz  Canabrava's avatar Tomaz Canabrava Committed by Tomaz Canabrava
Browse files

Fix a bug where moving a split with only two splits could kill the View

our childEvent checks if we have zero or one entities
and then cleans the view of uneeded elements. But when we are
moving a TerminalDisplay around it will temporarely have only
one element, and starts to clean / delete things around.
We do not want this during the split move
parent 4f6c8a7b
Pipeline #115726 passed with stage
in 1 minute and 52 seconds
......@@ -377,6 +377,8 @@ void Konsole::ViewSplitter::dropEvent(QDropEvent *ev)
return;
}
if (currentDragTarget != nullptr) {
m_blockPropagatedDeletion = true;
currentDragTarget->hideDragTarget();
auto source = qobject_cast<TerminalDisplay *>(ev->source());
source->setVisible(false);
......@@ -397,6 +399,8 @@ void Konsole::ViewSplitter::dropEvent(QDropEvent *ev)
Q_EMIT getToplevelSplitter()->terminalDisplayDropped(source);
source->setVisible(true);
currentDragTarget = nullptr;
m_blockPropagatedDeletion = false;
}
}
}
......
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