Fix bug with tool seam allowance cursor.
--HG-- branch : feature
This commit is contained in:
parent
233efde704
commit
05cad85ab3
|
@ -1063,7 +1063,7 @@ void VToolSeamAllowance::mousePressEvent(QGraphicsSceneMouseEvent *event)
|
|||
//---------------------------------------------------------------------------------------------------------------------
|
||||
void VToolSeamAllowance::mouseReleaseEvent(QGraphicsSceneMouseEvent *event)
|
||||
{
|
||||
if (event->button() == Qt::LeftButton)
|
||||
if (event->button() == Qt::LeftButton && (flags() & QGraphicsItem::ItemIsMovable))
|
||||
{
|
||||
SetItemOverrideCursor(this, cursorArrowOpenHand, 1, 1);
|
||||
}
|
||||
|
@ -1077,6 +1077,16 @@ void VToolSeamAllowance::hoverEnterEvent(QGraphicsSceneHoverEvent *event)
|
|||
{
|
||||
SetItemOverrideCursor(this, cursorArrowOpenHand, 1, 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (QGraphicsScene *scene = this->scene())
|
||||
{
|
||||
if (QGraphicsView *view = scene->views().at(0))
|
||||
{
|
||||
setCursor(view->viewport()->cursor());
|
||||
}
|
||||
}
|
||||
}
|
||||
QGraphicsPathItem::hoverEnterEvent(event);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user