mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
ZoneViewZone fix
This commit is contained in:
parent
60722e6e47
commit
4f4049fccf
6 changed files with 18 additions and 12 deletions
|
|
@ -1,7 +1,7 @@
|
|||
#include <QGraphicsSceneMouseEvent>
|
||||
#include "selectzone.h"
|
||||
#include "gamescene.h"
|
||||
|
||||
#include <QDebug>
|
||||
SelectZone::SelectZone(Player *_player, const QString &_name, bool _hasCardAttr, bool _isShufflable, bool _contentsKnown, QGraphicsItem *parent, bool isView)
|
||||
: CardZone(_player, _name, _hasCardAttr, _isShufflable, _contentsKnown, parent, isView)
|
||||
{
|
||||
|
|
@ -28,8 +28,7 @@ void SelectZone::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
|
|||
continue;
|
||||
cards[i]->setSelected(selectionRect.intersects(cards[i]->mapRectToParent(cards[i]->boundingRect())));
|
||||
}
|
||||
|
||||
static_cast<GameScene *>(scene())->resizeRubberBand(scenePos() + pos);
|
||||
static_cast<GameScene *>(scene())->resizeRubberBand(deviceTransform(static_cast<GameScene *>(scene())->getViewportTransform()).map(pos));
|
||||
event->accept();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue