mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-19 17:02:15 -07:00
only clear selection if ctrl isn't held
This commit is contained in:
parent
8e9b111ae3
commit
5182a26144
1 changed files with 3 additions and 1 deletions
|
|
@ -83,7 +83,9 @@ void SelectZone::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
|
||||||
void SelectZone::mousePressEvent(QGraphicsSceneMouseEvent *event)
|
void SelectZone::mousePressEvent(QGraphicsSceneMouseEvent *event)
|
||||||
{
|
{
|
||||||
if (event->button() == Qt::LeftButton) {
|
if (event->button() == Qt::LeftButton) {
|
||||||
scene()->clearSelection();
|
if (!event->modifiers().testFlag(Qt::ControlModifier)) {
|
||||||
|
scene()->clearSelection();
|
||||||
|
}
|
||||||
|
|
||||||
selectionOrigin = event->pos();
|
selectionOrigin = event->pos();
|
||||||
static_cast<GameScene *>(scene())->startRubberBand(event->scenePos());
|
static_cast<GameScene *>(scene())->startRubberBand(event->scenePos());
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue