mirror of
https://github.com/tumic0/GPXSee.git
synced 2024-11-24 03:35:53 +01:00
Fixed Z-order issue
This commit is contained in:
parent
3e421c6aba
commit
e9b32fb582
@ -144,7 +144,7 @@ void RouteItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event)
|
||||
Q_UNUSED(event);
|
||||
|
||||
_pen.setWidthF(HOVER_WIDTH * 1.0/scale());
|
||||
setZValue(3.0);
|
||||
setZValue(zValue() + 1.0);
|
||||
update();
|
||||
}
|
||||
|
||||
@ -153,6 +153,6 @@ void RouteItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event)
|
||||
Q_UNUSED(event);
|
||||
|
||||
_pen.setWidthF(ROUTE_WIDTH * 1.0/scale());
|
||||
setZValue(0);
|
||||
setZValue(zValue() - 1.0);
|
||||
update();
|
||||
}
|
||||
|
@ -122,7 +122,7 @@ void TrackItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event)
|
||||
Q_UNUSED(event);
|
||||
|
||||
_pen.setWidthF(HOVER_WIDTH * 1.0/scale());
|
||||
setZValue(3.0);
|
||||
setZValue(zValue() + 1.0);
|
||||
update();
|
||||
}
|
||||
|
||||
@ -131,6 +131,6 @@ void TrackItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event)
|
||||
Q_UNUSED(event);
|
||||
|
||||
_pen.setWidthF(TRACK_WIDTH * 1.0/scale());
|
||||
setZValue(0);
|
||||
setZValue(zValue() - 1.0);
|
||||
update();
|
||||
}
|
||||
|
@ -131,7 +131,7 @@ void WaypointItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event)
|
||||
prepareGeometryChange();
|
||||
_hover = true;
|
||||
updateShape();
|
||||
setZValue(3.0);
|
||||
setZValue(zValue() + 1.0);
|
||||
}
|
||||
|
||||
void WaypointItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event)
|
||||
@ -141,5 +141,5 @@ void WaypointItem::hoverLeaveEvent(QGraphicsSceneHoverEvent *event)
|
||||
prepareGeometryChange();
|
||||
_hover = false;
|
||||
updateShape();
|
||||
setZValue(0);
|
||||
setZValue(zValue() - 1.0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user