only clear selection if ctrl isn't held

This commit is contained in:
RickyRister 2024-12-26 02:24:20 -08:00
parent 8e9b111ae3
commit 5182a26144

View file

@ -83,7 +83,9 @@ void SelectZone::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
void SelectZone::mousePressEvent(QGraphicsSceneMouseEvent *event)
{
if (event->button() == Qt::LeftButton) {
scene()->clearSelection();
if (!event->modifiers().testFlag(Qt::ControlModifier)) {
scene()->clearSelection();
}
selectionOrigin = event->pos();
static_cast<GameScene *>(scene())->startRubberBand(event->scenePos());