|
|
@ -416,12 +416,15 @@ UBBoardView::mousePressEvent (QMouseEvent *event) |
|
|
|
} |
|
|
|
} |
|
|
|
else if (currentTool == UBStylusTool::Selector) |
|
|
|
else if (currentTool == UBStylusTool::Selector) |
|
|
|
{ |
|
|
|
{ |
|
|
|
|
|
|
|
QSet<QGraphicsItem*> existingTools = scene()->tools(); |
|
|
|
|
|
|
|
|
|
|
|
movingItem = scene()->itemAt(this->mapToScene(event->posF().toPoint())); |
|
|
|
movingItem = scene()->itemAt(this->mapToScene(event->posF().toPoint())); |
|
|
|
|
|
|
|
|
|
|
|
if (!movingItem ||
|
|
|
|
if (!movingItem
|
|
|
|
movingItem->isSelected() ||
|
|
|
|
|| movingItem->isSelected() |
|
|
|
(movingItem->type() == UBGraphicsDelegateFrame::Type ||
|
|
|
|
|| (movingItem->type() == UBGraphicsDelegateFrame::Type |
|
|
|
movingItem->type() == DelegateButton::Type)) |
|
|
|
|| movingItem->type() == DelegateButton::Type)
|
|
|
|
|
|
|
|
|| existingTools.contains(movingItem)) |
|
|
|
{ |
|
|
|
{ |
|
|
|
movingItem = NULL; |
|
|
|
movingItem = NULL; |
|
|
|
QGraphicsView::mousePressEvent (event); |
|
|
|
QGraphicsView::mousePressEvent (event); |
|
|
|